diff --git a/dev/.buildinfo b/dev/.buildinfo index 794c225f1..2b3b2d030 100644 --- a/dev/.buildinfo +++ b/dev/.buildinfo @@ -1,4 +1,4 @@ # Sphinx build info version 1 # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. -config: d555acfc62b7bbb17c4e4e99f82a529f +config: 99f5e9400b87a154c2e9660b9dbba890 tags: 645f666f9bcd5a90fca523b33c5a78b7 diff --git a/dev/.doctrees/auto_examples/01_introductory/index.doctree b/dev/.doctrees/auto_examples/01_introductory/index.doctree index 564d5170f..1a7c78acf 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/index.doctree and b/dev/.doctrees/auto_examples/01_introductory/index.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_arrow.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_arrow.doctree index 39a9f7ca2..843018ec9 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_arrow.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_arrow.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_cone.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_cone.doctree index 1aae8c053..7f5761cfe 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_cone.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_cone.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_earth_animation.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_earth_animation.doctree index cb7fe6b94..2799067c9 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_earth_animation.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_earth_animation.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_earth_coordinates.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_earth_coordinates.doctree index 78799d7cb..7212aea79 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_earth_coordinates.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_earth_coordinates.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_gltf.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_gltf.doctree index 1e5edfa01..c08a1b4a4 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_gltf.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_gltf.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_gltf_animated.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_gltf_animated.doctree index 120dabde7..3af4df395 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_gltf_animated.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_gltf_animated.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_gltf_export.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_gltf_export.doctree index 7e25fa1d6..ecc1fe5c6 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_gltf_export.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_gltf_export.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_morphing.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_morphing.doctree index 4755d805a..448c450f1 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_morphing.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_morphing.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_multithread.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_multithread.doctree index 6195cc90f..40bcfa43c 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_multithread.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_multithread.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_picking.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_picking.doctree index 7868aab51..ba12f616b 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_picking.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_picking.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_selection.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_selection.doctree index 13f4105eb..769bd5a36 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_selection.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_selection.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_skinning.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_skinning.doctree index 19cd08de0..4a65f83b4 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_skinning.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_skinning.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_slice.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_slice.doctree index 82595c514..8dbdcce36 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_slice.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_slice.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_solar_system.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_solar_system.doctree index 6507b084c..3092a649d 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_solar_system.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_solar_system.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_sphere.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_sphere.doctree index 0e2392633..dc9b6b1ae 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_sphere.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_sphere.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_spiky.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_spiky.doctree index a484a83fa..d13487cf1 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_spiky.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_spiky.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_surfaces.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_surfaces.doctree index a9ba59b71..e2ba8a6c6 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_surfaces.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_surfaces.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_texture.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_texture.doctree index 967e6adcb..476c895e5 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_texture.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_texture.doctree differ diff --git a/dev/.doctrees/auto_examples/01_introductory/viz_timers.doctree b/dev/.doctrees/auto_examples/01_introductory/viz_timers.doctree index cd60c00b6..b0d118ebf 100644 Binary files a/dev/.doctrees/auto_examples/01_introductory/viz_timers.doctree and b/dev/.doctrees/auto_examples/01_introductory/viz_timers.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/collision-particles.doctree b/dev/.doctrees/auto_examples/04_demos/collision-particles.doctree index d42bb77fc..0b8bc587a 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/collision-particles.doctree and b/dev/.doctrees/auto_examples/04_demos/collision-particles.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/index.doctree b/dev/.doctrees/auto_examples/04_demos/index.doctree index 78c43ec4c..93246d384 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/index.doctree and b/dev/.doctrees/auto_examples/04_demos/index.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_advanced.doctree b/dev/.doctrees/auto_examples/04_demos/viz_advanced.doctree index 521707200..33bfc3a1f 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_advanced.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_advanced.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_animated_surfaces.doctree b/dev/.doctrees/auto_examples/04_demos/viz_animated_surfaces.doctree index 459a44054..b9824245e 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_animated_surfaces.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_animated_surfaces.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_brownian_motion.doctree b/dev/.doctrees/auto_examples/04_demos/viz_brownian_motion.doctree index 719d477e5..242119cbf 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_brownian_motion.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_brownian_motion.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_bundles.doctree b/dev/.doctrees/auto_examples/04_demos/viz_bundles.doctree index fa075324d..2e4d976d9 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_bundles.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_bundles.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_dt_ellipsoids.doctree b/dev/.doctrees/auto_examples/04_demos/viz_dt_ellipsoids.doctree index 653fbc836..abaab67fd 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_dt_ellipsoids.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_dt_ellipsoids.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_emwave_animation.doctree b/dev/.doctrees/auto_examples/04_demos/viz_emwave_animation.doctree index 539d1e6d7..34c8c7834 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_emwave_animation.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_emwave_animation.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_fiber_odf.doctree b/dev/.doctrees/auto_examples/04_demos/viz_fiber_odf.doctree index 74351fe53..e1da09128 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_fiber_odf.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_fiber_odf.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_fine_tuning_gl_context.doctree b/dev/.doctrees/auto_examples/04_demos/viz_fine_tuning_gl_context.doctree index 29b5b3af8..5e7a26286 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_fine_tuning_gl_context.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_fine_tuning_gl_context.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_fractals.doctree b/dev/.doctrees/auto_examples/04_demos/viz_fractals.doctree index 54954ae0f..7facb2aad 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_fractals.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_fractals.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_helical_motion.doctree b/dev/.doctrees/auto_examples/04_demos/viz_helical_motion.doctree index d474d6de9..12b098c44 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_helical_motion.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_helical_motion.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_markers.doctree b/dev/.doctrees/auto_examples/04_demos/viz_markers.doctree index 00efda472..1cce5e44d 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_markers.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_markers.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_network.doctree b/dev/.doctrees/auto_examples/04_demos/viz_network.doctree index b56121bf6..c17b4c88e 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_network.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_network.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_network_animated.doctree b/dev/.doctrees/auto_examples/04_demos/viz_network_animated.doctree index ed0d251fb..36d6d39b2 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_network_animated.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_network_animated.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_pbr_interactive.doctree b/dev/.doctrees/auto_examples/04_demos/viz_pbr_interactive.doctree index 07538d409..eefa7cb39 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_pbr_interactive.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_pbr_interactive.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_play_video.doctree b/dev/.doctrees/auto_examples/04_demos/viz_play_video.doctree index 6ee1b30dd..79fc57b70 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_play_video.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_play_video.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_roi_contour.doctree b/dev/.doctrees/auto_examples/04_demos/viz_roi_contour.doctree index 0f8d6b08e..2b6408553 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_roi_contour.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_roi_contour.doctree differ diff --git a/dev/.doctrees/auto_examples/04_demos/viz_tesseract.doctree b/dev/.doctrees/auto_examples/04_demos/viz_tesseract.doctree index c084428ef..7ec6c29ff 100644 Binary files a/dev/.doctrees/auto_examples/04_demos/viz_tesseract.doctree and b/dev/.doctrees/auto_examples/04_demos/viz_tesseract.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/index.doctree b/dev/.doctrees/auto_examples/07_ui/index.doctree index e31ef1699..98555854e 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/index.doctree and b/dev/.doctrees/auto_examples/07_ui/index.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_buttons.doctree b/dev/.doctrees/auto_examples/07_ui/viz_buttons.doctree index d4b2b57ae..37f5db395 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_buttons.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_buttons.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_card.doctree b/dev/.doctrees/auto_examples/07_ui/viz_card.doctree index a2c8aa37c..be5574269 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_card.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_card.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_card_sprite_sheet.doctree b/dev/.doctrees/auto_examples/07_ui/viz_card_sprite_sheet.doctree index c7f720e02..68e5966d7 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_card_sprite_sheet.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_card_sprite_sheet.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_check_boxes.doctree b/dev/.doctrees/auto_examples/07_ui/viz_check_boxes.doctree index d4153b0ea..97e3ebc6e 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_check_boxes.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_check_boxes.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_combobox.doctree b/dev/.doctrees/auto_examples/07_ui/viz_combobox.doctree index 85e4986f7..8ce8f02ba 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_combobox.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_combobox.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_drawpanel.doctree b/dev/.doctrees/auto_examples/07_ui/viz_drawpanel.doctree index 56d67b73d..69c32ec0b 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_drawpanel.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_drawpanel.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_layout.doctree b/dev/.doctrees/auto_examples/07_ui/viz_layout.doctree index 76d41960c..959791705 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_layout.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_layout.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_radio_buttons.doctree b/dev/.doctrees/auto_examples/07_ui/viz_radio_buttons.doctree index 5b5812331..e8a05dd7f 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_radio_buttons.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_radio_buttons.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_shapes.doctree b/dev/.doctrees/auto_examples/07_ui/viz_shapes.doctree index 57e52dc15..da53ab6f4 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_shapes.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_shapes.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_spinbox.doctree b/dev/.doctrees/auto_examples/07_ui/viz_spinbox.doctree index 140e8780f..16a049894 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_spinbox.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_spinbox.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_tab.doctree b/dev/.doctrees/auto_examples/07_ui/viz_tab.doctree index f595d914e..61bb6924b 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_tab.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_tab.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_ui.doctree b/dev/.doctrees/auto_examples/07_ui/viz_ui.doctree index 5c3c440e0..cf9e17489 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_ui.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_ui.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_ui_listbox.doctree b/dev/.doctrees/auto_examples/07_ui/viz_ui_listbox.doctree index 8a33cf451..5d165e4f6 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_ui_listbox.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_ui_listbox.doctree differ diff --git a/dev/.doctrees/auto_examples/07_ui/viz_ui_slider.doctree b/dev/.doctrees/auto_examples/07_ui/viz_ui_slider.doctree index 34436b77a..e69b86491 100644 Binary files a/dev/.doctrees/auto_examples/07_ui/viz_ui_slider.doctree and b/dev/.doctrees/auto_examples/07_ui/viz_ui_slider.doctree differ diff --git a/dev/.doctrees/auto_examples/10_animation/index.doctree b/dev/.doctrees/auto_examples/10_animation/index.doctree index f88c88ea2..727f4fdf3 100644 Binary files a/dev/.doctrees/auto_examples/10_animation/index.doctree and b/dev/.doctrees/auto_examples/10_animation/index.doctree differ diff --git a/dev/.doctrees/auto_examples/10_animation/viz_bezier_interpolator.doctree b/dev/.doctrees/auto_examples/10_animation/viz_bezier_interpolator.doctree index 87a31782c..11dbdf9c8 100644 Binary files a/dev/.doctrees/auto_examples/10_animation/viz_bezier_interpolator.doctree and b/dev/.doctrees/auto_examples/10_animation/viz_bezier_interpolator.doctree differ diff --git a/dev/.doctrees/auto_examples/10_animation/viz_camera.doctree b/dev/.doctrees/auto_examples/10_animation/viz_camera.doctree index ce1b212c3..386df27a6 100644 Binary files a/dev/.doctrees/auto_examples/10_animation/viz_camera.doctree and b/dev/.doctrees/auto_examples/10_animation/viz_camera.doctree differ diff --git a/dev/.doctrees/auto_examples/10_animation/viz_color_interpolators.doctree b/dev/.doctrees/auto_examples/10_animation/viz_color_interpolators.doctree index 97625fc4c..8dd7849e5 100644 Binary files a/dev/.doctrees/auto_examples/10_animation/viz_color_interpolators.doctree and b/dev/.doctrees/auto_examples/10_animation/viz_color_interpolators.doctree differ diff --git a/dev/.doctrees/auto_examples/10_animation/viz_custom_interpolator.doctree b/dev/.doctrees/auto_examples/10_animation/viz_custom_interpolator.doctree index 277d7e32a..3427a18fa 100644 Binary files a/dev/.doctrees/auto_examples/10_animation/viz_custom_interpolator.doctree and b/dev/.doctrees/auto_examples/10_animation/viz_custom_interpolator.doctree differ diff --git a/dev/.doctrees/auto_examples/10_animation/viz_hierarchical_animation.doctree b/dev/.doctrees/auto_examples/10_animation/viz_hierarchical_animation.doctree index 0789c8e43..31ceaa4fb 100644 Binary files a/dev/.doctrees/auto_examples/10_animation/viz_hierarchical_animation.doctree and b/dev/.doctrees/auto_examples/10_animation/viz_hierarchical_animation.doctree differ diff --git a/dev/.doctrees/auto_examples/10_animation/viz_introduction.doctree b/dev/.doctrees/auto_examples/10_animation/viz_introduction.doctree index ed09cf9cd..91265b834 100644 Binary files a/dev/.doctrees/auto_examples/10_animation/viz_introduction.doctree and b/dev/.doctrees/auto_examples/10_animation/viz_introduction.doctree differ diff --git a/dev/.doctrees/auto_examples/10_animation/viz_robot_arm_animation.doctree b/dev/.doctrees/auto_examples/10_animation/viz_robot_arm_animation.doctree index 7bbbd1795..29d1bd1a1 100644 Binary files a/dev/.doctrees/auto_examples/10_animation/viz_robot_arm_animation.doctree and b/dev/.doctrees/auto_examples/10_animation/viz_robot_arm_animation.doctree differ diff --git a/dev/.doctrees/auto_examples/10_animation/viz_spline_interpolator.doctree b/dev/.doctrees/auto_examples/10_animation/viz_spline_interpolator.doctree index de0a94914..801e16bb6 100644 Binary files a/dev/.doctrees/auto_examples/10_animation/viz_spline_interpolator.doctree and b/dev/.doctrees/auto_examples/10_animation/viz_spline_interpolator.doctree differ diff --git a/dev/.doctrees/auto_examples/10_animation/viz_timeline.doctree b/dev/.doctrees/auto_examples/10_animation/viz_timeline.doctree index 3e12ef5bb..b9ebb7037 100644 Binary files a/dev/.doctrees/auto_examples/10_animation/viz_timeline.doctree and b/dev/.doctrees/auto_examples/10_animation/viz_timeline.doctree differ diff --git a/dev/.doctrees/auto_examples/10_animation/viz_using_time_equations.doctree b/dev/.doctrees/auto_examples/10_animation/viz_using_time_equations.doctree index 5e5577f09..78081d9bf 100644 Binary files a/dev/.doctrees/auto_examples/10_animation/viz_using_time_equations.doctree and b/dev/.doctrees/auto_examples/10_animation/viz_using_time_equations.doctree differ diff --git a/dev/.doctrees/auto_examples/13_shaders/index.doctree b/dev/.doctrees/auto_examples/13_shaders/index.doctree index 38069ff70..a175a7927 100644 Binary files a/dev/.doctrees/auto_examples/13_shaders/index.doctree and b/dev/.doctrees/auto_examples/13_shaders/index.doctree differ diff --git a/dev/.doctrees/auto_examples/13_shaders/viz_billboard_sdf_spheres.doctree b/dev/.doctrees/auto_examples/13_shaders/viz_billboard_sdf_spheres.doctree index 31b84dab2..db816599f 100644 Binary files a/dev/.doctrees/auto_examples/13_shaders/viz_billboard_sdf_spheres.doctree and b/dev/.doctrees/auto_examples/13_shaders/viz_billboard_sdf_spheres.doctree differ diff --git a/dev/.doctrees/auto_examples/13_shaders/viz_pbr_spheres.doctree b/dev/.doctrees/auto_examples/13_shaders/viz_pbr_spheres.doctree index 2cbc832dc..21d15c4c0 100644 Binary files a/dev/.doctrees/auto_examples/13_shaders/viz_pbr_spheres.doctree and b/dev/.doctrees/auto_examples/13_shaders/viz_pbr_spheres.doctree differ diff --git a/dev/.doctrees/auto_examples/13_shaders/viz_principled_spheres.doctree b/dev/.doctrees/auto_examples/13_shaders/viz_principled_spheres.doctree index 742bb2531..fbd0d9f05 100644 Binary files a/dev/.doctrees/auto_examples/13_shaders/viz_principled_spheres.doctree and b/dev/.doctrees/auto_examples/13_shaders/viz_principled_spheres.doctree differ diff --git a/dev/.doctrees/auto_examples/13_shaders/viz_sdf_cylinder.doctree b/dev/.doctrees/auto_examples/13_shaders/viz_sdf_cylinder.doctree index 564cdb8d3..3b2773d7b 100644 Binary files a/dev/.doctrees/auto_examples/13_shaders/viz_sdf_cylinder.doctree and b/dev/.doctrees/auto_examples/13_shaders/viz_sdf_cylinder.doctree differ diff --git a/dev/.doctrees/auto_examples/13_shaders/viz_sdfactor.doctree b/dev/.doctrees/auto_examples/13_shaders/viz_sdfactor.doctree index fc2519b4f..c4d7e8059 100644 Binary files a/dev/.doctrees/auto_examples/13_shaders/viz_sdfactor.doctree and b/dev/.doctrees/auto_examples/13_shaders/viz_sdfactor.doctree differ diff --git a/dev/.doctrees/auto_examples/13_shaders/viz_shader.doctree b/dev/.doctrees/auto_examples/13_shaders/viz_shader.doctree index c0ed8fbd9..602f4e904 100644 Binary files a/dev/.doctrees/auto_examples/13_shaders/viz_shader.doctree and b/dev/.doctrees/auto_examples/13_shaders/viz_shader.doctree differ diff --git a/dev/.doctrees/auto_examples/17_pybullet/index.doctree b/dev/.doctrees/auto_examples/17_pybullet/index.doctree index 1c2c01698..1969b316e 100644 Binary files a/dev/.doctrees/auto_examples/17_pybullet/index.doctree and b/dev/.doctrees/auto_examples/17_pybullet/index.doctree differ diff --git a/dev/.doctrees/auto_examples/17_pybullet/viz_ball_collide.doctree b/dev/.doctrees/auto_examples/17_pybullet/viz_ball_collide.doctree index 9ec81b84b..f010dcbc7 100644 Binary files a/dev/.doctrees/auto_examples/17_pybullet/viz_ball_collide.doctree and b/dev/.doctrees/auto_examples/17_pybullet/viz_ball_collide.doctree differ diff --git a/dev/.doctrees/auto_examples/17_pybullet/viz_brick_wall.doctree b/dev/.doctrees/auto_examples/17_pybullet/viz_brick_wall.doctree index aea2d873a..c69ae9221 100644 Binary files a/dev/.doctrees/auto_examples/17_pybullet/viz_brick_wall.doctree and b/dev/.doctrees/auto_examples/17_pybullet/viz_brick_wall.doctree differ diff --git a/dev/.doctrees/auto_examples/17_pybullet/viz_chain.doctree b/dev/.doctrees/auto_examples/17_pybullet/viz_chain.doctree index 093028c6d..4bfac35cd 100644 Binary files a/dev/.doctrees/auto_examples/17_pybullet/viz_chain.doctree and b/dev/.doctrees/auto_examples/17_pybullet/viz_chain.doctree differ diff --git a/dev/.doctrees/auto_examples/17_pybullet/viz_domino.doctree b/dev/.doctrees/auto_examples/17_pybullet/viz_domino.doctree index 8b8653f17..5fd00c682 100644 Binary files a/dev/.doctrees/auto_examples/17_pybullet/viz_domino.doctree and b/dev/.doctrees/auto_examples/17_pybullet/viz_domino.doctree differ diff --git a/dev/.doctrees/auto_examples/17_pybullet/viz_wrecking_ball.doctree b/dev/.doctrees/auto_examples/17_pybullet/viz_wrecking_ball.doctree index c0cb771f0..4fe9288dd 100644 Binary files a/dev/.doctrees/auto_examples/17_pybullet/viz_wrecking_ball.doctree and b/dev/.doctrees/auto_examples/17_pybullet/viz_wrecking_ball.doctree differ diff --git a/dev/.doctrees/auto_examples/20_stream/index.doctree b/dev/.doctrees/auto_examples/20_stream/index.doctree index 7447ddff2..e32c43d9c 100644 Binary files a/dev/.doctrees/auto_examples/20_stream/index.doctree and b/dev/.doctrees/auto_examples/20_stream/index.doctree differ diff --git a/dev/.doctrees/auto_examples/20_stream/viz_interaction.doctree b/dev/.doctrees/auto_examples/20_stream/viz_interaction.doctree index bda15f028..a12cfa661 100644 Binary files a/dev/.doctrees/auto_examples/20_stream/viz_interaction.doctree and b/dev/.doctrees/auto_examples/20_stream/viz_interaction.doctree differ diff --git a/dev/.doctrees/auto_examples/20_stream/viz_no_interaction.doctree b/dev/.doctrees/auto_examples/20_stream/viz_no_interaction.doctree index e985dbbbc..664f125d5 100644 Binary files a/dev/.doctrees/auto_examples/20_stream/viz_no_interaction.doctree and b/dev/.doctrees/auto_examples/20_stream/viz_no_interaction.doctree differ diff --git a/dev/.doctrees/auto_examples/20_stream/viz_widget.doctree b/dev/.doctrees/auto_examples/20_stream/viz_widget.doctree index 975d95e56..4c5269856 100644 Binary files a/dev/.doctrees/auto_examples/20_stream/viz_widget.doctree and b/dev/.doctrees/auto_examples/20_stream/viz_widget.doctree differ diff --git a/dev/.doctrees/auto_examples/index.doctree b/dev/.doctrees/auto_examples/index.doctree index ff6fbd7e3..34b9d3227 100644 Binary files a/dev/.doctrees/auto_examples/index.doctree and b/dev/.doctrees/auto_examples/index.doctree differ diff --git a/dev/.doctrees/community.doctree b/dev/.doctrees/community.doctree index 544ab349c..e77c4c42c 100644 Binary files a/dev/.doctrees/community.doctree and b/dev/.doctrees/community.doctree differ diff --git a/dev/.doctrees/environment.pickle b/dev/.doctrees/environment.pickle index 5ff578bff..bd000ee2d 100644 Binary files a/dev/.doctrees/environment.pickle and b/dev/.doctrees/environment.pickle differ diff --git a/dev/.doctrees/reference/fury.actor.doctree b/dev/.doctrees/reference/fury.actor.doctree index ce058efb4..d941ee504 100644 Binary files a/dev/.doctrees/reference/fury.actor.doctree and b/dev/.doctrees/reference/fury.actor.doctree differ diff --git a/dev/.doctrees/reference/fury.deprecator.doctree b/dev/.doctrees/reference/fury.deprecator.doctree index b9cdaaacb..0b7f69d7a 100644 Binary files a/dev/.doctrees/reference/fury.deprecator.doctree and b/dev/.doctrees/reference/fury.deprecator.doctree differ diff --git a/dev/_downloads/07fcc19ba03226cd3d83d4e40ec44385/auto_examples_python.zip b/dev/_downloads/07fcc19ba03226cd3d83d4e40ec44385/auto_examples_python.zip index a0c42d420..778b4cddb 100644 Binary files a/dev/_downloads/07fcc19ba03226cd3d83d4e40ec44385/auto_examples_python.zip and b/dev/_downloads/07fcc19ba03226cd3d83d4e40ec44385/auto_examples_python.zip differ diff --git a/dev/_downloads/6f1e7a639e0699d6164445b55e6c116d/auto_examples_jupyter.zip b/dev/_downloads/6f1e7a639e0699d6164445b55e6c116d/auto_examples_jupyter.zip index 422110386..25a020039 100644 Binary files a/dev/_downloads/6f1e7a639e0699d6164445b55e6c116d/auto_examples_jupyter.zip and b/dev/_downloads/6f1e7a639e0699d6164445b55e6c116d/auto_examples_jupyter.zip differ diff --git a/dev/_modules/fury.html b/dev/_modules/fury.html index afc1aa56a..42d6aceb8 100644 --- a/dev/_modules/fury.html +++ b/dev/_modules/fury.html @@ -7,7 +7,7 @@
-
from fury import layout
from fury.actors.odf_slicer import OdfSlicerActor
from fury.actors.peak import PeakActor
-from fury.actors.tensor import double_cone, main_dir_uncertainty, tensor_ellipsoid
+from fury.actors.tensor import (
+ double_cone,
+ main_dir_uncertainty,
+ tensor_ellipsoid,
+ )
from fury.colormap import colormap_lookup_table
from fury.deprecator import deprecate_with_version, deprecated_params
from fury.io import load_image
@@ -598,7 +602,9 @@ Source code for fury.actor
ex1, ex2, ey1, ey2, ez1, ez2 = vtk_resliced_data.GetExtent()
- resliced = numpy_support.vtk_to_numpy(vtk_resliced_data.GetPointData().GetScalars())
+ resliced = numpy_support.vtk_to_numpy(
+ vtk_resliced_data.GetPointData().GetScalars()
+ )
# swap axes here
if data.ndim == 4:
@@ -764,7 +770,9 @@ Source code for fury.actor
triangle_poly_data.SetPoints(points)
if colors is not None:
- triangle_poly_data.GetPointData().SetScalars(numpy_to_vtk_colors(255 * colors))
+ triangle_poly_data.GetPointData().SetScalars(
+ numpy_to_vtk_colors(255 * colors)
+ )
if faces is None:
tri = Delaunay(vertices[:, [0, 1]])
@@ -1109,7 +1117,10 @@ Source code for fury.actor
poly_mapper = set_input(PolyDataMapper(), next_input)
if replace_strips:
triangle_filter = set_input(TriangleFilter(), next_input)
- poly_mapper = set_input(PolyDataMapper(), triangle_filter.GetOutputPort())
+ poly_mapper = set_input(
+ PolyDataMapper(),
+ triangle_filter.GetOutputPort()
+ )
else:
poly_mapper = set_input(PolyDataMapper(), next_input)
@@ -1273,7 +1284,11 @@ Source code for fury.actor
if program is not None:
program.SetUniformf('linewidth', linewidth)
- replace_shader_in_actor(actor, 'geometry', import_fury_shader('line.geom'))
+ replace_shader_in_actor(
+ actor,
+ 'geometry',
+ import_fury_shader('line.geom')
+ )
add_shader_callback(actor, callback)
if fake_tube:
@@ -1320,7 +1335,11 @@ Source code for fury.actor
[docs]
def axes(
- scale=(1, 1, 1), colorx=(1, 0, 0), colory=(0, 1, 0), colorz=(0, 0, 1), opacity=1
+ scale=(1, 1, 1),
+ colorx=(1, 0, 0),
+ colory=(0, 1, 0),
+ colorz=(0, 0, 1),
+ opacity=1
):
"""Create an actor with the coordinate's system axes where
red = x, green = y, blue = z.
@@ -1345,7 +1364,11 @@ Source code for fury.actor
"""
centers = np.zeros((3, 3))
dirs = np.array([[1, 0, 0], [0, 1, 0], [0, 0, 1]])
- colors = np.array([colorx + (opacity,), colory + (opacity,), colorz + (opacity,)])
+ colors = np.array(
+ [colorx + (opacity,),
+ colory + (opacity,),
+ colorz + (opacity,)]
+ )
scales = np.asarray(scale)
arrow_actor = arrow(centers, dirs, colors, scales, repeat_primitive=False)
@@ -1442,7 +1465,10 @@ Source code for fury.actor
if len(vertices) != B_matrix.shape[1]:
raise ValueError(
'Invalid number of SH coefficients. '
- 'Expected {0}, got {1}.'.format(len(vertices), B_matrix.shape[1])
+ 'Expected {0}, got {1}.'.format(
+ len(vertices),
+ B_matrix.shape[1]
+ )
)
# create and return an instance of OdfSlicerActor
@@ -1637,7 +1663,7 @@ Source code for fury.actor
def display_extent(self, x1, x2, y1, y2, z1, z2):
tmp_mask = np.zeros(evals.shape[:3], dtype=bool)
- tmp_mask[x1 : x2 + 1, y1 : y2 + 1, z1 : z2 + 1] = True
+ tmp_mask[x1: x2 + 1, y1: y2 + 1, z1: z2 + 1] = True
tmp_mask = np.bitwise_and(tmp_mask, mask)
self.mapper = _tensor_slicer_mapper(
@@ -1766,7 +1792,10 @@ Source code for fury.actor
all_faces = np.concatenate(all_faces)
cols = np.ascontiguousarray(
- np.reshape(cols, (cols.shape[0] * cols.shape[1], cols.shape[2])), dtype='f4'
+ np.reshape(
+ cols,
+ (cols.shape[0] * cols.shape[1],
+ cols.shape[2])), dtype='f4'
)
vtk_colors = numpy_support.numpy_to_vtk(
@@ -1864,7 +1893,7 @@ Source code for fury.actor
def display_extent(self, x1, x2, y1, y2, z1, z2):
tmp_mask = np.zeros(grid_shape, dtype=bool)
- tmp_mask[x1 : x2 + 1, y1 : y2 + 1, z1 : z2 + 1] = True
+ tmp_mask[x1: x2 + 1, y1: y2 + 1, z1: z2 + 1] = True
tmp_mask = np.bitwise_and(tmp_mask, mask)
ijk = np.ascontiguousarray(np.array(np.nonzero(tmp_mask)).T)
@@ -1895,7 +1924,10 @@ Source code for fury.actor
)
)
else:
- dirs = np.vstack((xyz, peaks_dirs[tuple(center)][i] * pv + xyz))
+ dirs = np.vstack((
+ xyz,
+ peaks_dirs[tuple(center)][i] * pv + xyz)
+ )
list_dirs.append(dirs)
self.line = line(
@@ -2091,7 +2123,9 @@ Source code for fury.actor
if points.shape[1] != 3:
raise ValueError(
'Invalid points. The shape of the last dimension '
- 'must be 3. Your data has a last dimension of {}.'.format(points.shape[1])
+ 'must be 3. Your data has a last dimension of {}.'.format(
+ points.shape[1]
+ )
)
vtk_vertices = Points()
@@ -2316,11 +2350,13 @@ Source code for fury.actor
vertices : ndarray, shape (N, 3)
The point cloud defining the sphere.
faces : ndarray, shape (M, 3)
- If faces is None then a sphere is created based on theta and phi angles.
+ If faces is None then a sphere is created based on theta
+ and phi angles.
If not then a sphere is created with the provided vertices and faces.
repeat_primitive: bool
If True, cylinder will be generated with primitives
- If False, repeat_sources will be invoked to use VTK filters for cylinder.
+ If False,
+ repeat_sources will be invoked to use VTK filters for cylinder.
Returns
-------
@@ -2370,7 +2406,13 @@ Source code for fury.actor
src.SetCapping(capped)
src.SetResolution(resolution)
src.SetRadius(radius)
- rotate = np.array([[0, 1, 0, 0], [-1, 0, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]])
+ rotate = np.array(
+ [[0, 1, 0, 0],
+ [-1, 0, 0, 0],
+ [0, 0, 1, 0],
+ [0, 0, 0, 1]
+ ]
+ )
else:
src = None
rotate = None
@@ -2451,7 +2493,13 @@ Source code for fury.actor
src.SetRadialResolution(rresolution)
src.SetInnerRadius(rinner)
src.SetOuterRadius(router)
- rotate = np.array([[0, 0, -1, 0], [0, 1, 0, 0], [1, 0, 0, 0], [0, 0, 0, 1]])
+ rotate = np.array(
+ [[0, 0, -1, 0],
+ [0, 1, 0, 0],
+ [1, 0, 0, 0],
+ [0, 0, 0, 1]
+ ]
+ )
else:
src = None
rotate = None
@@ -2523,7 +2571,11 @@ Source code for fury.actor
[docs]
-def rectangle(centers, directions=(1, 0, 0), colors=(1, 0, 0), scales=(1, 2, 0)):
+def rectangle(
+ centers,
+ directions=(1, 0, 0),
+ colors=(1, 0, 0),
+ scales=(1, 2, 0)):
"""Visualize one or many rectangles with different features.
Parameters
@@ -2556,13 +2608,21 @@ Source code for fury.actor
>>> # window.show(scene)
"""
- return square(centers=centers, directions=directions, colors=colors, scales=scales)
+ return square(
+ centers=centers,
+ directions=directions,
+ colors=colors,
+ scales=scales)
[docs]
-@deprecated_params(['size', 'heights'], ['scales', 'scales'], since='0.6', until='0.8')
+@deprecated_params(
+ ['size', 'heights'],
+ ['scales', 'scales'],
+ since='0.6',
+ until='0.8')
def box(centers, directions=(1, 0, 0), colors=(1, 0, 0), scales=(1, 2, 3)):
"""Visualize one or many boxes with different features.
@@ -2643,7 +2703,10 @@ Source code for fury.actor
>>> # window.show(scene)
"""
- return box(centers=centers, directions=directions, colors=colors, scales=scales)
+ return box(centers=centers,
+ directions=directions,
+ colors=colors,
+ scales=scales)
@@ -2817,7 +2880,12 @@ Source code for fury.actor
vertices, faces = fp.prim_cone(sectors=resolution)
res = fp.repeat_primitive(
- vertices, faces, centers, directions=directions, colors=colors, scales=heights
+ vertices,
+ faces,
+ centers,
+ directions=directions,
+ colors=colors,
+ scales=heights
)
big_verts, big_faces, big_colors, _ = res
@@ -2883,7 +2951,10 @@ Source code for fury.actor
[docs]
-def rhombicuboctahedron(centers, directions=(1, 0, 0), colors=(1, 0, 0), scales=1):
+def rhombicuboctahedron(centers,
+ directions=(1, 0, 0),
+ colors=(1, 0, 0),
+ scales=1):
"""Visualize one or many rhombicuboctahedron with different features.
Parameters
@@ -3504,7 +3575,9 @@ Source code for fury.actor
elif justification == 'right':
tprop.SetJustificationToRight()
else:
- raise ValueError("Unknown justification: '{}'".format(justification))
+ raise ValueError(
+ "Unknown justification: '{}'".format(justification)
+ )
def vertical_justification(self, justification):
tprop = self.GetTextProperty()
@@ -3516,7 +3589,9 @@ Source code for fury.actor
tprop.SetVerticalJustificationToBottom()
else:
raise ValueError(
- "Unknown vertical justification: '{}'".format(justification)
+ "Unknown vertical justification: '{}'".format(
+ justification
+ )
)
def font_style(self, bold=False, italic=False, shadow=False):
@@ -3832,7 +3907,9 @@ Source code for fury.actor
# We change the anchor of the container so
# the actor will be centered in the
# grid cell.
- actor_with_caption.anchor = actor_center - actor_with_caption.GetCenter()
+ actor_with_caption.anchor = (
+ actor_center - actor_with_caption.GetCenter()
+ )
actors_with_caption.append(actor_with_caption)
actors = actors_with_caption
@@ -3869,7 +3946,12 @@ Source code for fury.actor
# width, height
vtk_image_data.SetDimensions(pic.shape[1], pic.shape[0], 1)
- vtk_image_data.SetExtent(0, pic.shape[1] - 1, 0, pic.shape[0] - 1, 0, 0)
+ vtk_image_data.SetExtent(0,
+ pic.shape[1] - 1,
+ 0,
+ pic.shape[0] - 1,
+ 0,
+ 0)
pic_tmp = np.swapaxes(pic, 0, 1)
pic_tmp = pic.reshape(pic.shape[1] * pic.shape[0], 4)
pic_tmp = np.ascontiguousarray(pic_tmp)
@@ -3972,7 +4054,8 @@ Source code for fury.actor
"""
grid = texture_actor.GetTexture().GetInput()
dim = arr.shape[-1]
- img_data = np.flip(arr.swapaxes(0, 1), axis=1).reshape((-1, dim), order='F')
+ img_data = np.flip(arr.swapaxes(0, 1),
+ axis=1).reshape((-1, dim), order='F')
vtkarr = numpy_support.numpy_to_vtk(img_data, deep=False)
grid.GetPointData().SetScalars(vtkarr)
@@ -4110,7 +4193,11 @@ Source code for fury.actor
[docs]
-def sdf(centers, directions=(1, 0, 0), colors=(1, 0, 0), primitives='torus', scales=1):
+def sdf(centers,
+ directions=(1, 0, 0),
+ colors=(1, 0, 0),
+ primitives='torus',
+ scales=1):
"""Create a SDF primitive based actor.
Parameters
@@ -4169,7 +4256,8 @@ Source code for fury.actor
else:
rep_scales = np.repeat(scales, rep_centers.shape[0], axis=0)
- if isinstance(directions, (list, tuple, np.ndarray)) and len(directions) == 3:
+ if isinstance(directions,
+ (list, tuple, np.ndarray)) and len(directions) == 3:
rep_directions = np.repeat(directions, rep_centers.shape[0], axis=0)
else:
rep_directions = np.repeat(directions, verts.shape[0], axis=0)
@@ -4184,9 +4272,15 @@ Source code for fury.actor
fs_dec_code = import_fury_shader('sdf_dec.frag')
fs_impl_code = import_fury_shader('sdf_impl.frag')
- shader_to_actor(box_actor, 'vertex', impl_code=vs_impl_code, decl_code=vs_dec_code)
+ shader_to_actor(box_actor,
+ 'vertex',
+ impl_code=vs_impl_code,
+ decl_code=vs_dec_code)
shader_to_actor(box_actor, 'fragment', decl_code=fs_dec_code)
- shader_to_actor(box_actor, 'fragment', impl_code=fs_impl_code, block='light')
+ shader_to_actor(box_actor,
+ 'fragment',
+ impl_code=fs_impl_code,
+ block='light')
return box_actor
@@ -4338,15 +4432,25 @@ Source code for fury.actor
attribute_to_actor(sq_actor, list_of_markers, 'marker')
def callback(
- _caller, _event, calldata=None, uniform_type='f', uniform_name=None, value=None
+ _caller,
+ _event,
+ calldata=None,
+ uniform_type='f',
+ uniform_name=None,
+ value=None
):
program = calldata
if program is not None:
- program.__getattribute__(f'SetUniform{uniform_type}')(uniform_name, value)
+ program.__getattribute__(
+ f'SetUniform{uniform_type}'
+ )(uniform_name, value)
add_shader_callback(
sq_actor,
- partial(callback, uniform_type='f', uniform_name='edgeWidth', value=edge_width),
+ partial(callback,
+ uniform_type='f',
+ uniform_name='edgeWidth',
+ value=edge_width),
)
add_shader_callback(
sq_actor,
@@ -4360,19 +4464,31 @@ Source code for fury.actor
add_shader_callback(
sq_actor,
partial(
- callback, uniform_type='f', uniform_name='edgeOpacity', value=edge_opacity
+ callback,
+ uniform_type='f',
+ uniform_name='edgeOpacity',
+ value=edge_opacity
),
)
add_shader_callback(
sq_actor,
partial(
- callback, uniform_type='3f', uniform_name='edgeColor', value=edge_color
+ callback,
+ uniform_type='3f',
+ uniform_name='edgeColor',
+ value=edge_color
),
)
- shader_to_actor(sq_actor, 'vertex', impl_code=vs_impl_code, decl_code=vs_dec_code)
+ shader_to_actor(sq_actor,
+ 'vertex',
+ impl_code=vs_impl_code,
+ decl_code=vs_dec_code)
shader_to_actor(sq_actor, 'fragment', decl_code=fs_dec_code)
- shader_to_actor(sq_actor, 'fragment', impl_code=fs_impl_code, block='light')
+ shader_to_actor(sq_actor,
+ 'fragment',
+ impl_code=fs_impl_code,
+ block='light')
return sq_actor
diff --git a/dev/_modules/fury/actors/odf_slicer.html b/dev/_modules/fury/actors/odf_slicer.html
index 621019c9a..87c70f472 100644
--- a/dev/_modules/fury/actors/odf_slicer.html
+++ b/dev/_modules/fury/actors/odf_slicer.html
@@ -7,7 +7,7 @@
- fury.actors.odf_slicer — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.actors.odf_slicer — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
diff --git a/dev/_modules/fury/actors/peak.html b/dev/_modules/fury/actors/peak.html
index ed3db6629..63d33bdbd 100644
--- a/dev/_modules/fury/actors/peak.html
+++ b/dev/_modules/fury/actors/peak.html
@@ -7,7 +7,7 @@
- fury.actors.peak — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.actors.peak — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
diff --git a/dev/_modules/fury/actors/tensor.html b/dev/_modules/fury/actors/tensor.html
index 25029e828..10d341d13 100644
--- a/dev/_modules/fury/actors/tensor.html
+++ b/dev/_modules/fury/actors/tensor.html
@@ -7,7 +7,7 @@
- fury.actors.tensor — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.actors.tensor — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
diff --git a/dev/_modules/fury/animation/animation.html b/dev/_modules/fury/animation/animation.html
index 267aa10c0..15b60b58e 100644
--- a/dev/_modules/fury/animation/animation.html
+++ b/dev/_modules/fury/animation/animation.html
@@ -7,7 +7,7 @@
- fury.animation.animation — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.animation.animation — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -421,7 +421,10 @@ Source code for fury.animation.animation
[docs]
- def __init__(self, actors=None, length=None, loop=True, motion_path_res=None):
+ def __init__(self, actors=None,
+ length=None,
+ loop=True,
+ motion_path_res=None):
super().__init__()
self._data = defaultdict(dict)
@@ -463,7 +466,8 @@ Source code for fury.animation.animation
else:
self._duration = max(
self._max_timestamp,
- max([0] + [anim.update_duration() for anim in self.child_animations]),
+ max([0] + [anim.update_duration()
+ for anim in self.child_animations]),
)
return self.duration
@@ -570,7 +574,8 @@ Source code for fury.animation.animation
data[attrib] = {
'keyframes': defaultdict(dict),
'interpolator': {
- 'base': linear_interpolator if attrib != 'rotation' else slerp,
+ 'base': (linear_interpolator
+ if attrib != 'rotation' else slerp),
'func': None,
'args': defaultdict(),
},
@@ -594,7 +599,8 @@ Source code for fury.animation.animation
if attrib is None:
attribs = data.keys()
return {
- attrib: data.get(attrib, {}).get('keyframes', {}) for attrib in attribs
+ attrib: data.get(attrib,
+ {}).get('keyframes', {}) for attrib in attribs
}
return data.get(attrib, {}).get('keyframes', {})
@@ -712,7 +718,8 @@ Source code for fury.animation.animation
parent_in_scene = parent._added_to_scene
if self.is_interpolatable('in_scene'):
- in_scene = parent_in_scene and self.get_value('in_scene', timestamp)
+ in_scene = parent_in_scene and self.get_value('in_scene',
+ timestamp)
else:
in_scene = parent_in_scene
return in_scene
@@ -766,7 +773,8 @@ Source code for fury.animation.animation
[docs]
- def set_interpolator(self, attrib, interpolator, is_evaluator=False, **kwargs):
+ def set_interpolator(self, attrib, interpolator,
+ is_evaluator=False, **kwargs):
"""Set keyframes interpolator for a certain property
Parameters
@@ -850,7 +858,8 @@ Source code for fury.animation.animation
[docs]
- def set_position_interpolator(self, interpolator, is_evaluator=False, **kwargs):
+ def set_position_interpolator(self, interpolator,
+ is_evaluator=False, **kwargs):
"""Set the position interpolator.
Parameters
@@ -919,7 +928,8 @@ Source code for fury.animation.animation
>>> Animation.set_rotation_interpolator(slerp)
"""
- self.set_interpolator('rotation', interpolator, is_evaluator=is_evaluator)
+ self.set_interpolator('rotation', interpolator,
+ is_evaluator=is_evaluator)
@@ -963,7 +973,9 @@ Source code for fury.animation.animation
>>> Animation.set_opacity_interpolator(step_interpolator)
"""
- self.set_interpolator('opacity', interpolator, is_evaluator=is_evaluator)
+ self.set_interpolator('opacity',
+ interpolator,
+ is_evaluator=is_evaluator)
@@ -980,7 +992,8 @@ Source code for fury.animation.animation
"""
value = (
- self._data.get(attrib, {}).get('interpolator', {}).get('func')(timestamp)
+ self._data.get(attrib,
+ {}).get('interpolator', {}).get('func')(timestamp)
)
return value
@@ -1731,7 +1744,11 @@ Source code for fury.animation.animation
[docs]
- def __init__(self, camera=None, length=None, loop=True, motion_path_res=None):
+ def __init__(self,
+ camera=None,
+ length=None,
+ loop=True,
+ motion_path_res=None):
super(CameraAnimation, self).__init__(
length=length, loop=loop, motion_path_res=motion_path_res
)
@@ -1919,7 +1936,8 @@ Source code for fury.animation.animation
function that does not depend on keyframes.
"""
- self.set_interpolator('view_up', interpolator, is_evaluator=is_evaluator)
+ self.set_interpolator('view_up', interpolator,
+ is_evaluator=is_evaluator)
@@ -1947,7 +1965,10 @@ Source code for fury.animation.animation
# camera axis is reverted
rot = -self.get_rotation(time, as_quat=True)
rot = transform.Rotation.from_quat(rot).as_matrix()
- rot = np.array([[*rot[0], 0], [*rot[1], 0], [*rot[2], 0], [0, 0, 0, 1]])
+ rot = np.array([[*rot[0], 0],
+ [*rot[1], 0],
+ [*rot[2], 0],
+ [0, 0, 0, 1]])
rot = translation @ rot @ np.linalg.inv(translation)
self._camera.SetModelTransformMatrix(rot.flatten())
diff --git a/dev/_modules/fury/animation/helpers.html b/dev/_modules/fury/animation/helpers.html
index 9bacc60b8..45da283e9 100644
--- a/dev/_modules/fury/animation/helpers.html
+++ b/dev/_modules/fury/animation/helpers.html
@@ -7,7 +7,7 @@
- fury.animation.helpers — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.animation.helpers — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -469,7 +469,8 @@ Source code for fury.animation.helpers
"""
return np.asarray(
- [keyframes.get(t, {}).get('value', None) for t in sorted(keyframes.keys())]
+ [keyframes.get(t, {}).get('value', None)
+ for t in sorted(keyframes.keys())]
)
diff --git a/dev/_modules/fury/animation/interpolator.html b/dev/_modules/fury/animation/interpolator.html
index 3c61f7b7b..faa09de2c 100644
--- a/dev/_modules/fury/animation/interpolator.html
+++ b/dev/_modules/fury/animation/interpolator.html
@@ -7,7 +7,7 @@
- fury.animation.interpolator — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.animation.interpolator — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
diff --git a/dev/_modules/fury/animation/timeline.html b/dev/_modules/fury/animation/timeline.html
index 73e2729d4..9dc0e776c 100644
--- a/dev/_modules/fury/animation/timeline.html
+++ b/dev/_modules/fury/animation/timeline.html
@@ -7,7 +7,7 @@
- fury.animation.timeline — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.animation.timeline — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -412,7 +412,9 @@ Source code for fury.animation.timeline
[docs]
- def __init__(self, animations=None, playback_panel=False, loop=True, length=None):
+ def __init__(self, animations=None,
+ playback_panel=False,
+ loop=True, length=None):
self._scene = None
self.playback_panel = None
@@ -768,7 +770,11 @@ Source code for fury.animation.timeline
render_window.SetSize(*size)
if order_transparent:
- window.antialiasing(scene, render_window, multi_samples, max_peels, 0)
+ window.antialiasing(scene,
+ render_window,
+ multi_samples,
+ max_peels,
+ 0)
window_to_image_filter = WindowToImageFilter()
diff --git a/dev/_modules/fury/colormap.html b/dev/_modules/fury/colormap.html
index 0b4d451a5..26d5e930e 100644
--- a/dev/_modules/fury/colormap.html
+++ b/dev/_modules/fury/colormap.html
@@ -7,7 +7,7 @@
- fury.colormap — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.colormap — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -627,7 +627,8 @@ Source code for fury.colormap
orient = np.abs(np.divide(v, orientn, where=orientn != 0))
else:
raise IOError(
- 'Wrong vector dimension, It should be an array' ' with a shape (N, 3)'
+ 'Wrong vector dimension, It should be an array'
+ ' with a shape (N, 3)'
)
return orient
@@ -651,12 +652,14 @@ Source code for fury.colormap
"""
if cmap == 'rgb_standard':
col_list = [
- orient2rgb(streamline[-1] - streamline[0]) for streamline in streamlines
+ orient2rgb(streamline[-1] - streamline[0])
+ for streamline in streamlines
]
if cmap == 'boys_standard':
col_list = [
- boys2rgb(streamline[-1] - streamline[0]) for streamline in streamlines
+ boys2rgb(streamline[-1] - streamline[0])
+ for streamline in streamlines
]
return np.vstack(col_list)
diff --git a/dev/_modules/fury/convert.html b/dev/_modules/fury/convert.html
index 3aad1576b..4279087c2 100644
--- a/dev/_modules/fury/convert.html
+++ b/dev/_modules/fury/convert.html
@@ -7,7 +7,7 @@
- fury.convert — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.convert — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -431,7 +431,11 @@ Source code for fury.convert
arr = load_image(fname)
else:
fig.savefig(
- fname, dpi=dpi, transparent=transparent, bbox_inches='tight', pad_inches=0
+ fname,
+ dpi=dpi,
+ transparent=transparent,
+ bbox_inches='tight',
+ pad_inches=0
)
arr = load_image(fname)
diff --git a/dev/_modules/fury/data/fetcher.html b/dev/_modules/fury/data/fetcher.html
index 58770a1a3..0694c1d59 100644
--- a/dev/_modules/fury/data/fetcher.html
+++ b/dev/_modules/fury/data/fetcher.html
@@ -7,7 +7,7 @@
- fury.data.fetcher — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.data.fetcher — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
diff --git a/dev/_modules/fury/decorators.html b/dev/_modules/fury/decorators.html
index 430f40545..c46e83728 100644
--- a/dev/_modules/fury/decorators.html
+++ b/dev/_modules/fury/decorators.html
@@ -7,7 +7,7 @@
- fury.decorators — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.decorators — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
diff --git a/dev/_modules/fury/deprecator.html b/dev/_modules/fury/deprecator.html
index 3035b7574..dfd96b99c 100644
--- a/dev/_modules/fury/deprecator.html
+++ b/dev/_modules/fury/deprecator.html
@@ -7,7 +7,7 @@
- fury.deprecator — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.deprecator — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -499,7 +499,8 @@ Source code for fury.deprecator
"""
version_cmp = packaging.version.parse if have_pkg else None
- if any([re.match(r'^[a-z, A-Z]', v) for v in [version_str, pkg_version_str]]):
+ if any([re.match(r'^[a-z, A-Z]', v)
+ for v in [version_str, pkg_version_str]]):
msg = 'Invalid version {0} or {1}'.format(version_str, pkg_version_str)
raise ValueError(msg)
elif version_cmp(version_str) > version_cmp(pkg_version_str):
@@ -575,7 +576,8 @@ Source code for fury.deprecator
if until:
messages.append(
'* {0} {1} as of version: {2}'.format(
- 'Raises' if is_bad_version(until) else 'Will raise', error_class, until
+ 'Raises' if is_bad_version(until)
+ else 'Will raise', error_class, until
)
)
message = '\n'.join(messages)
@@ -588,7 +590,8 @@ Source code for fury.deprecator
warnings.warn(message, warn_class, stacklevel=2)
return func(*args, **kwargs)
- deprecated_func.__doc__ = _add_dep_doc(deprecated_func.__doc__, message)
+ deprecated_func.__doc__ = _add_dep_doc(deprecated_func.__doc__,
+ message)
return deprecated_func
return deprecator
@@ -773,11 +776,13 @@ Source code for fury.deprecator
if (since[i], until[i]) != ('', ''):
messages.append('')
if since[i]:
- messages.append('* deprecated from version: ' + str(since[i]))
+ messages.append('* deprecated from version: ' +
+ str(since[i]))
if until[i]:
messages.append(
'* {0} {1} as of version: {2}'.format(
- 'Raises' if is_bad_version(until[i]) else 'Will raise',
+ 'Raises' if is_bad_version(until[i])
+ else 'Will raise',
error_class,
until[i],
)
@@ -808,11 +813,14 @@ Source code for fury.deprecator
kwargs[key] = value
if n_name is not None:
- message += '* Use argument "{}" instead.'.format(n_name)
+ message += '* Use argument "{}" instead.'.format(
+ n_name
+ )
elif alternative:
message += '* Use {} instead.'.format(alternative)
- if until[i] and is_bad_version(until[i], version_comparator):
+ if until[i] and is_bad_version(until[i],
+ version_comparator):
raise error_class(message)
warnings.warn(message, warn_class, stacklevel=2)
@@ -821,7 +829,8 @@ Source code for fury.deprecator
elif not n_name and positions[i] and len(args) > positions[i]:
if alternative:
message += '* Use {} instead.'.format(alternative)
- if until[i] and is_bad_version(until[i], version_comparator):
+ if until[i] and is_bad_version(until[i],
+ version_comparator):
raise error_class(message)
warnings.warn(message, warn_class, stacklevel=2)
diff --git a/dev/_modules/fury/gltf.html b/dev/_modules/fury/gltf.html
index e34506e37..7c67e73b2 100644
--- a/dev/_modules/fury/gltf.html
+++ b/dev/_modules/fury/gltf.html
@@ -7,7 +7,7 @@
- fury.gltf — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.gltf — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -526,7 +526,12 @@ Source code for fury.gltf
[docs]
- def transverse_node(self, nextnode_id, matrix, parent=None, is_joint=False):
+ def transverse_node(self,
+ nextnode_id,
+ matrix,
+ parent=None,
+ is_joint=False
+ ):
"""Load mesh and generates transformation matrix.
Parameters
@@ -592,7 +597,11 @@ Source code for fury.gltf
for bone, ibm in zip(joints, ibms):
self.bones.append(bone)
self.ibms[bone] = ibm
- self.transverse_node(joints[0], np.identity(4), parent, is_joint=True)
+ self.transverse_node(
+ joints[0],
+ np.identity(4),
+ parent, is_joint=True
+ )
if node.camera is not None:
camera_id = node.camera
@@ -630,7 +639,8 @@ Source code for fury.gltf
if attributes.NORMAL is not None and self.apply_normals:
normals = self.get_acc_data(attributes.NORMAL)
- normals = transform.apply_transformation(normals, transform_mat)
+ normals = transform.apply_transformation(normals,
+ transform_mat)
utils.set_polydata_normals(polydata, normals)
if attributes.TEXCOORD_0 is not None:
@@ -705,14 +715,22 @@ Source code for fury.gltf
total_byte_offset = byte_offset + acc_byte_offset
buff_array = self.get_buff_array(
- buff_id, d_type['dtype'], byte_length, total_byte_offset, byte_stride
+ buff_id, d_type['dtype'],
+ byte_length,
+ total_byte_offset,
+ byte_stride
)
return buff_array[:, :a_type]
[docs]
- def get_buff_array(self, buff_id, d_type, byte_length, byte_offset, byte_stride):
+ def get_buff_array(self,
+ buff_id,
+ d_type,
+ byte_length,
+ byte_offset,
+ byte_stride):
"""Extract the mesh data from buffer.
Parameters
@@ -746,9 +764,8 @@ Source code for fury.gltf
byte_stride = int(byte_stride / 4)
try:
- if uri.startswith('data:application/octet-stream;base64') or uri.startswith(
- 'data:application/gltf-buffer;base64'
- ):
+ if (uri.startswith('data:application/octet-stream;base64') or
+ uri.startswith('data:application/gltf-buffer;base64')):
buff_data = uri.split(',')[1]
buff_data = base64.b64decode(buff_data)
@@ -888,7 +905,9 @@ Source code for fury.gltf
zfar = perspective.zfar if perspective.zfar else 1000.0
znear = perspective.znear
vtk_cam.SetClippingRange(znear, zfar)
- angle = perspective.yfov * 180 / np.pi if perspective.yfov else 30.0
+ angle = (perspective.yfov * 180 / np.pi
+ if perspective.yfov else 30.0
+ )
vtk_cam.SetViewAngle(angle)
if perspective.aspectRatio:
vtk_cam.SetExplicitAspectRatio(perspective.aspectRatio)
@@ -929,7 +948,11 @@ Source code for fury.gltf
[docs]
- def get_sampler_data(self, sampler: gltflib.Sampler, node_id: int, transform_type):
+ def get_sampler_data(self,
+ sampler: gltflib.Sampler,
+ node_id: int,
+ transform_type
+ ):
"""Get the animation and transformation data from sampler.
Parameters
@@ -1150,10 +1173,16 @@ Source code for fury.gltf
parent_transform = np.identity(4)
for child in _animation.child_animations:
self.transverse_animations(
- child, self.bones[0], timestamp, joint_matrices, parent_transform
+ child,
+ self.bones[0],
+ timestamp,
+ joint_matrices,
+ parent_transform
)
for i, vertex in enumerate(self._vertices):
- vertex[:] = self.apply_skin_matrix(self._vcopy[i], joint_matrices, i)
+ vertex[:] = self.apply_skin_matrix(self._vcopy[i],
+ joint_matrices,
+ i)
actor_transf = self.transformations[i]
vertex[:] = transform.apply_transformation(vertex, actor_transf)
utils.update_actor(self._actors[i])
@@ -1226,7 +1255,11 @@ Source code for fury.gltf
[docs]
- def transverse_bones(self, bone_id, channel_name, parent_animation: Animation):
+ def transverse_bones(self,
+ bone_id,
+ channel_name,
+ parent_animation: Animation
+ ):
"""Loop over the bones and add child bone animation to their parent
animation.
@@ -1274,7 +1307,8 @@ Source code for fury.gltf
"""
root_animations = {}
- self._vertices = [utils.vertices_from_actor(act) for act in self.actors()]
+ self._vertices = [utils.vertices_from_actor(act)
+ for act in self.actors()]
self._vcopy = [np.copy(vert) for vert in self._vertices]
for name in self.animation_channels.keys():
root_animation = Animation()
@@ -1330,9 +1364,12 @@ Source code for fury.gltf
animation.update_animation()
timestamp = animation.current_timestamp
for i, vertex in enumerate(self._vertices):
- weights = animation.child_animations[0].get_value('morph', timestamp)
+ weights = animation.child_animations[0].get_value('morph',
+ timestamp)
vertex[:] = self.apply_morph_vertices(self._vcopy[i], weights, i)
- vertex[:] = transform.apply_transformation(vertex, self.transformations[i])
+ vertex[:] = transform.apply_transformation(vertex,
+ self.transformations[i]
+ )
utils.update_actor(self._actors[i])
utils.compute_bounds(self._actors[i])
@@ -1376,7 +1413,8 @@ Source code for fury.gltf
"""
animations = {}
- self._vertices = [utils.vertices_from_actor(act) for act in self.actors()]
+ self._vertices = [utils.vertices_from_actor(act)
+ for act in self.actors()]
self._vcopy = [np.copy(vert) for vert in self._vertices]
for name, data in self.animation_channels.items():
@@ -1429,7 +1467,9 @@ Source code for fury.gltf
for i, nodes in enumerate(self.nodes):
animation = Animation()
transform_mat = self.transformations[i]
- position, rot, scale = transform.transform_from_matrix(transform_mat)
+ position, rot, scale = transform.transform_from_matrix(
+ transform_mat
+ )
animation.set_keyframe('position', 0.0, position)
if target_node in nodes:
@@ -1459,17 +1499,26 @@ Source code for fury.gltf
if prop == 'rotation':
animation.set_rotation(
- time[0], trs, in_tangent=in_tan, out_tangent=out_tan
+ time[0],
+ trs,
+ in_tangent=in_tan,
+ out_tangent=out_tan
)
animation.set_rotation_interpolator(rot_interp)
if prop == 'translation':
animation.set_position(
- time[0], trs, in_tangent=in_tan, out_tangent=out_tan
+ time[0],
+ trs,
+ in_tangent=in_tan,
+ out_tangent=out_tan
)
animation.set_position_interpolator(interpolator)
if prop == 'scale':
animation.set_scale(
- time[0], trs, in_tangent=in_tan, out_tangent=out_tan
+ time[0],
+ trs,
+ in_tangent=in_tan,
+ out_tangent=out_tan
)
animation.set_scale_interpolator(interpolator)
else:
@@ -1614,7 +1663,12 @@ Source code for fury.gltf
buff_file.write(indices.tobytes())
write_bufferview(gltf, 0, byteoffset, blength)
write_accessor(
- gltf, count, 0, gltflib.UNSIGNED_SHORT, len(indices), gltflib.SCALAR
+ gltf,
+ count,
+ 0,
+ gltflib.UNSIGNED_SHORT,
+ len(indices),
+ gltflib.SCALAR
)
byteoffset += blength
index = count
@@ -1893,7 +1947,14 @@ Source code for fury.gltf
[docs]
def write_accessor(
- gltf, bufferview, byte_offset, comp_type, count, accssor_type, max=None, min=None
+ gltf,
+ bufferview,
+ byte_offset,
+ comp_type,
+ count,
+ accssor_type,
+ max=None,
+ min=None
):
"""Write accessor in the gltf.
diff --git a/dev/_modules/fury/io.html b/dev/_modules/fury/io.html
index 31f43ca9e..e90aecc6b 100644
--- a/dev/_modules/fury/io.html
+++ b/dev/_modules/fury/io.html
@@ -7,7 +7,7 @@
- fury.io — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.io — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -472,9 +472,8 @@ Source code for fury.io
desired image array
"""
- is_url = filename.lower().startswith('http://') or filename.lower().startswith(
- 'https://'
- )
+ is_url = (filename.lower().startswith('http://') or
+ filename.lower().startswith('https://'))
if is_url:
image_name = os.path.basename(filename)
@@ -501,7 +500,8 @@ Source code for fury.io
try:
image = pil_image.convert('RGBA')
except ValueError:
- raise RuntimeError('Unknown image mode {}'.format(pil_image.mode))
+ raise RuntimeError('Unknown image mode {}'.format(
+ pil_image.mode))
image = np.asarray(pil_image)
if as_vtktype:
@@ -513,7 +513,12 @@ Source code for fury.io
# width, height
vtk_image.SetDimensions(image.shape[1], image.shape[0], depth)
- vtk_image.SetExtent(0, image.shape[1] - 1, 0, image.shape[0] - 1, 0, 0)
+ vtk_image.SetExtent(0,
+ image.shape[1] - 1,
+ 0,
+ image.shape[0] - 1,
+ 0,
+ 0)
vtk_image.SetSpacing(1.0, 1.0, 1.0)
vtk_image.SetOrigin(0.0, 0.0, 0.0)
@@ -654,7 +659,9 @@ Source code for fury.io
im = Image.fromarray(arr)
im.save(filename, quality=compression_quality, dpi=dpi)
else:
- warnings.warn(UserWarning('DPI value is ignored while saving images via vtk.'))
+ warnings.warn(
+ UserWarning('DPI value is ignored while saving images via vtk.')
+ )
if arr.ndim == 2:
arr = arr[..., None]
@@ -688,7 +695,11 @@ Source code for fury.io
writer.SetQuality(compression_quality)
if extension.lower() in ['.tif', '.tiff']:
compression_type = compression_type or 'nocompression'
- l_compression = ['nocompression', 'packbits', 'jpeg', 'deflate', 'lzw']
+ l_compression = ['nocompression',
+ 'packbits',
+ 'jpeg',
+ 'deflate',
+ 'lzw']
if compression_type.lower() in l_compression:
comp_id = l_compression.index(compression_type.lower())
@@ -840,13 +851,14 @@ Source code for fury.io
nxt_col * sprite_size_y,
)
- sprite_arr = sprite_sheet[box[0] : box[2], box[1] : box[3]]
+ sprite_arr = sprite_sheet[box[0]: box[2], box[1]: box[3]]
if as_vtktype:
with InTemporaryDirectory() as tdir:
tmp_img_path = os.path.join(tdir, f'{row}{col}.png')
save_image(sprite_arr, tmp_img_path, compression_quality=100)
- sprite_dicts[(row, col)] = load_image(tmp_img_path, as_vtktype=True)
+ sprite_dicts[(row, col)] = load_image(tmp_img_path,
+ as_vtktype=True)
else:
sprite_dicts[(row, col)] = sprite_arr
diff --git a/dev/_modules/fury/layout.html b/dev/_modules/fury/layout.html
index 5b179c600..c6dba5064 100644
--- a/dev/_modules/fury/layout.html
+++ b/dev/_modules/fury/layout.html
@@ -7,7 +7,7 @@
- fury.layout — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.layout — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -480,11 +480,13 @@ Source code for fury.layout
"""
if self.cell_shape == 'rect':
- bounding_box_sizes = np.asarray(list(map(self.compute_sizes, actors)))
+ bounding_box_sizes = np.asarray(list(map(self.compute_sizes,
+ actors)))
cell_shape = np.max(bounding_box_sizes, axis=0)[:2]
shapes = [cell_shape] * len(actors)
elif self.cell_shape == 'square':
- bounding_box_sizes = np.asarray(list(map(self.compute_sizes, actors)))
+ bounding_box_sizes = np.asarray(list(map(self.compute_sizes,
+ actors)))
cell_shape = np.max(bounding_box_sizes, axis=0)[:2]
shapes = [(max(cell_shape),) * 2] * len(actors)
elif self.cell_shape == 'diagonal':
@@ -502,7 +504,9 @@ Source code for fury.layout
longest_diagonal = np.max(diagonals)
shapes = [(longest_diagonal, longest_diagonal)] * len(actors)
else:
- raise ValueError("Unknown cell shape: '{0}'".format(self.cell_shape))
+ raise ValueError("Unknown cell shape: '{0}'".format(
+ self.cell_shape
+ ))
return shapes
@@ -528,7 +532,9 @@ Source code for fury.layout
# Add padding, if any, around every cell.
shapes = [np.array(self.cell_padding) / 2.0 + s for s in shapes]
- positions = get_grid_cells_position(shapes, self.aspect_ratio, self.dim)
+ positions = get_grid_cells_position(shapes,
+ self.aspect_ratio,
+ self.dim)
positions += self.position_offset
return positions
@@ -719,7 +725,8 @@ Source code for fury.layout
if self.direction not in ['x+', 'x-']:
raise ValueError(f'{direction} is not a valid direction')
- super(XLayout, self).__init__(cell_padding=cell_padding, cell_shape=cell_shape)
+ super(XLayout, self).__init__(cell_padding=cell_padding,
+ cell_shape=cell_shape)
@@ -816,7 +823,8 @@ Source code for fury.layout
if self.direction not in ['y+', 'y-']:
raise ValueError(f'{direction} is not a valid direction')
- super(YLayout, self).__init__(cell_padding=cell_padding, cell_shape=cell_shape)
+ super(YLayout, self).__init__(cell_padding=cell_padding,
+ cell_shape=cell_shape)
@@ -913,7 +921,8 @@ Source code for fury.layout
if self.direction not in ['z+', 'z-']:
raise ValueError(f'{direction} is not a valid direction')
- super(ZLayout, self).__init__(cell_padding=cell_padding, cell_shape=cell_shape)
+ super(ZLayout, self).__init__(cell_padding=cell_padding,
+ cell_shape=cell_shape)
@@ -937,7 +946,8 @@ Source code for fury.layout
actors = actors[::-1]
if self.cell_shape == 'rect' or self.cell_shape == 'square':
- bounding_box_sizes = np.asarray(list(map(get_bounding_box_sizes, actors)))
+ bounding_box_sizes = np.asarray(list(map(get_bounding_box_sizes,
+ actors)))
cell_shape = np.max(bounding_box_sizes, axis=0)[2]
shapes = [cell_shape] * len(actors)
elif self.cell_shape == 'diagonal':
@@ -946,7 +956,9 @@ Source code for fury.layout
longest_diagonal = np.max([a.GetLength() for a in actors])
shapes = [longest_diagonal] * len(actors)
else:
- raise ValueError("Unknown cell shape: '{0}'".format(self.cell_shape))
+ raise ValueError("Unknown cell shape: '{0}'".format(
+ self.cell_shape
+ ))
return shapes
diff --git a/dev/_modules/fury/material.html b/dev/_modules/fury/material.html
index 4eb030ad9..c16cd1d4b 100644
--- a/dev/_modules/fury/material.html
+++ b/dev/_modules/fury/material.html
@@ -7,7 +7,7 @@
- fury.material — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.material — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
diff --git a/dev/_modules/fury/molecular.html b/dev/_modules/fury/molecular.html
index 0dd8752b6..dceb29e69 100644
--- a/dev/_modules/fury/molecular.html
+++ b/dev/_modules/fury/molecular.html
@@ -7,7 +7,7 @@
- fury.molecular — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.molecular — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -486,7 +486,8 @@ Source code for fury.molecular
self.helix = helix
self.is_hetatm = is_hetatm
coords = numpy_to_vtk_points(coords)
- atom_nums = nps.numpy_to_vtk(atomic_numbers, array_type=VTK_UNSIGNED_SHORT)
+ atom_nums = nps.numpy_to_vtk(atomic_numbers,
+ array_type=VTK_UNSIGNED_SHORT)
atom_nums.SetName('Atomic Numbers')
fieldData = DataSetAttributes()
fieldData.AddArray(atom_nums)
@@ -1069,7 +1070,8 @@ Source code for fury.molecular
"""
if molecule.total_num_bonds == 0:
raise ValueError(
- 'No bonding data available for the molecule! Stick ' 'model cannot be made!'
+ 'No bonding data available for the molecule! Stick '
+ 'model cannot be made!'
)
colormode = colormode.lower()
mst_mapper = OpenGLMoleculeMapper()
@@ -1126,13 +1128,15 @@ Source code for fury.molecular
resi = molecule.residue_seq[i]
for j, _ in enumerate(molecule.sheet):
sheet = molecule.sheet[j]
- if molecule.chain[i] != sheet[0] or resi < sheet[1] or resi > sheet[3]:
+ if (molecule.chain[i] != sheet[0] or
+ resi < sheet[1] or resi > sheet[3]):
continue
secondary_structures[i] = ord('s')
for j, _ in enumerate(molecule.helix):
helix = molecule.helix[j]
- if molecule.chain[i] != helix[0] or resi < helix[1] or resi > helix[3]:
+ if (molecule.chain[i] != helix[0] or
+ resi < helix[1] or resi > helix[3]):
continue
secondary_structures[i] = ord('h')
@@ -1184,13 +1188,17 @@ Source code for fury.molecular
# for secondary structures begin
newarr = np.ones(num_total_atoms)
- s_sb = nps.numpy_to_vtk(num_array=newarr, deep=True, array_type=VTK_UNSIGNED_CHAR)
+ s_sb = nps.numpy_to_vtk(num_array=newarr,
+ deep=True,
+ array_type=VTK_UNSIGNED_CHAR)
s_sb.SetName('secondary_structures_begin')
output.GetPointData().AddArray(s_sb)
# for secondary structures end
newarr = np.ones(num_total_atoms)
- s_se = nps.numpy_to_vtk(num_array=newarr, deep=True, array_type=VTK_UNSIGNED_CHAR)
+ s_se = nps.numpy_to_vtk(num_array=newarr,
+ deep=True,
+ array_type=VTK_UNSIGNED_CHAR)
s_se.SetName('secondary_structures_end')
output.GetPointData().AddArray(s_se)
@@ -1215,10 +1223,14 @@ Source code for fury.molecular
rgb = np.ones((num_total_atoms, 3))
for i in range(num_total_atoms):
- radii[i] = np.repeat(table.atomic_radius(all_atomic_numbers[i], 'VDW'), 3)
+ radii[i] = np.repeat(table.atomic_radius(
+ all_atomic_numbers[i],
+ 'VDW'), 3)
rgb[i] = table.atom_color(all_atomic_numbers[i])
- Rgb = nps.numpy_to_vtk(num_array=rgb, deep=True, array_type=VTK_UNSIGNED_CHAR)
+ Rgb = nps.numpy_to_vtk(num_array=rgb,
+ deep=True,
+ array_type=VTK_UNSIGNED_CHAR)
Rgb.SetName('rgb_colors')
output.GetPointData().SetScalars(Rgb)
diff --git a/dev/_modules/fury/pick.html b/dev/_modules/fury/pick.html
index 0a3f9ec6a..3ba65205b 100644
--- a/dev/_modules/fury/pick.html
+++ b/dev/_modules/fury/pick.html
@@ -7,7 +7,7 @@
- fury.pick — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.pick — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -395,7 +395,12 @@ Source code for fury.pick
[docs]
- def __init__(self, vertices=True, faces=True, actors=True, world_coords=True):
+ def __init__(
+ self,
+ vertices=True,
+ faces=True,
+ actors=True,
+ world_coords=True):
"""Initialize Picking Manager.
Parameters
@@ -608,28 +613,48 @@ Source code for fury.pick
res = self.hsel.Select()
except OverflowError:
- return {0: {'node': None, 'vertex': None, 'face': None, 'actor': None}}
+ return {0: {
+ 'node': None,
+ 'vertex': None,
+ 'face': None,
+ 'actor': None
+ }}
num_nodes = res.GetNumberOfNodes()
if num_nodes < 1:
sel_node = None
- return {0: {'node': None, 'vertex': None, 'face': None, 'actor': None}}
+ return {0: {
+ 'node': None,
+ 'vertex': None,
+ 'face': None,
+ 'actor': None
+ }
+ }
else:
for i in range(num_nodes):
sel_node = res.GetNode(i)
- info = {'node': None, 'vertex': None, 'face': None, 'actor': None}
+ info = {
+ 'node': None,
+ 'vertex': None,
+ 'face': None,
+ 'actor': None
+ }
if sel_node is not None:
selected_nodes = set(
np.floor(
- numpy_support.vtk_to_numpy(sel_node.GetSelectionList())
+ numpy_support.vtk_to_numpy(
+ sel_node.GetSelectionList()
+ )
).astype(int)
)
info['node'] = sel_node
- info['actor'] = sel_node.GetProperties().Get(sel_node.PROP())
+ info['actor'] = sel_node.GetProperties().Get(
+ sel_node.PROP()
+ )
if self.selected_type == 'faces':
info['face'] = list(selected_nodes)
if self.selected_type == 'vertex':
diff --git a/dev/_modules/fury/pkg_info.html b/dev/_modules/fury/pkg_info.html
index 82a6d9773..c2f44ee19 100644
--- a/dev/_modules/fury/pkg_info.html
+++ b/dev/_modules/fury/pkg_info.html
@@ -7,7 +7,7 @@
- fury.pkg_info — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.pkg_info — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
diff --git a/dev/_modules/fury/primitive.html b/dev/_modules/fury/primitive.html
index 1598c2d78..6cc43e244 100644
--- a/dev/_modules/fury/primitive.html
+++ b/dev/_modules/fury/primitive.html
@@ -7,7 +7,7 @@
- fury.primitive — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.primitive — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -426,7 +426,12 @@ Source code for fury.primitive
[docs]
def repeat_primitive_function(
- func, centers, func_args=[], directions=(1, 0, 0), colors=(1, 0, 0), scales=1
+ func,
+ centers,
+ func_args=[],
+ directions=(1, 0, 0),
+ colors=(1, 0, 0),
+ scales=1
):
"""Repeat Vertices and triangles of a specific primitive function.
@@ -545,7 +550,8 @@ Source code for fury.primitive
big_vertices *= scales
# update triangles
- big_triangles = np.array(np.tile(faces, (centers.shape[0], 1)), dtype=np.int32)
+ big_triangles = np.array(
+ np.tile(faces, (centers.shape[0], 1)), dtype=np.int32)
big_triangles += np.repeat(
np.arange(0, centers.shape[0] * unit_verts_size, step=unit_verts_size),
unit_triangles_size,
@@ -600,10 +606,12 @@ Source code for fury.primitive
else:
rotation_matrix = np.identity(3)
- big_vertices[pts * unit_verts_size : (pts + 1) * unit_verts_size] = np.dot(
- rotation_matrix[:3, :3],
- big_vertices[pts * unit_verts_size : (pts + 1) * unit_verts_size].T,
- ).T
+ big_vertices[pts * unit_verts_size: (pts + 1) * unit_verts_size] = (
+ np.dot(rotation_matrix[:3, :3],
+ big_vertices[pts * unit_verts_size: (
+ pts + 1) * unit_verts_size].T,
+ ).T
+ )
# apply centers position
big_centers = np.repeat(centers, unit_verts_size, axis=0)
@@ -627,7 +635,12 @@ Source code for fury.primitive
"""
vertices = np.array(
- [[-0.5, -0.5, 0.0], [-0.5, 0.5, 0.0], [0.5, 0.5, 0.0], [0.5, -0.5, 0.0]]
+ [
+ [-0.5, -0.5, 0.0],
+ [-0.5, 0.5, 0.0],
+ [0.5, 0.5, 0.0],
+ [0.5, -0.5, 0.0]
+ ]
)
triangles = np.array([[0, 1, 2], [2, 3, 0]], dtype='i8')
return vertices, triangles
@@ -728,7 +741,8 @@ Source code for fury.primitive
res = np.load(fname)
verts = res['vertices'].copy()
- faces = faces_from_sphere_vertices(verts) if gen_faces else res['faces']
+ faces = (faces_from_sphere_vertices(verts)
+ if gen_faces else res['faces'])
faces = fix_winding_order(res['vertices'], faces, clockwise=True)
return verts, faces
else:
@@ -834,10 +848,17 @@ Source code for fury.primitive
"""
pyramid_vert = np.array(
- [[0.5, 0.5, 0.5], [0.5, -0.5, -0.5], [-0.5, 0.5, -0.5], [-0.5, -0.5, 0.5]]
+ [
+ [0.5, 0.5, 0.5],
+ [0.5, -0.5, -0.5],
+ [-0.5, 0.5, -0.5],
+ [-0.5, -0.5, 0.5]
+ ]
)
- pyramid_triag = np.array([[2, 0, 1], [0, 2, 3], [0, 3, 1], [1, 3, 2]], dtype='i8')
+ pyramid_triag = np.array(
+ [[2, 0, 1], [0, 2, 3], [0, 3, 1], [1, 3, 2]],
+ dtype='i8')
return pyramid_vert, pyramid_triag
@@ -1409,7 +1430,9 @@ Source code for fury.primitive
k += 3
if capped:
- vertices = np.array(vertices).reshape(2 * (sectors + 1) + 2 * sectors + 2, 3)
+ vertices = np.array(vertices).reshape(
+ 2 * (sectors + 1) + 2 * sectors + 2, 3
+ )
else:
vertices = np.array(vertices).reshape(2 * (sectors + 1), 3)
@@ -1466,7 +1489,11 @@ Source code for fury.primitive
[docs]
def prim_arrow(
- height=1.0, resolution=10, tip_length=0.35, tip_radius=0.1, shaft_radius=0.03
+ height=1.0,
+ resolution=10,
+ tip_length=0.35,
+ tip_radius=0.1,
+ shaft_radius=0.03
):
"""Return vertices and triangle for arrow geometry.
diff --git a/dev/_modules/fury/shaders/base.html b/dev/_modules/fury/shaders/base.html
index 257febda5..419c329e5 100644
--- a/dev/_modules/fury/shaders/base.html
+++ b/dev/_modules/fury/shaders/base.html
@@ -7,7 +7,7 @@
- fury.shaders.base — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.shaders.base — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
diff --git a/dev/_modules/fury/stream/client.html b/dev/_modules/fury/stream/client.html
index 8d155baa9..ff199b05b 100644
--- a/dev/_modules/fury/stream/client.html
+++ b/dev/_modules/fury/stream/client.html
@@ -7,7 +7,7 @@
- fury.stream.client — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.stream.client — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -476,7 +476,9 @@ Source code for fury.stream.client
self.max_size = max_window_size[0] * max_window_size[1]
self.max_window_size = max_window_size
if self.max_size < self.showm.size[0] * self.showm.size[1]:
- raise ValueError('max_window_size must be greater than window_size')
+ raise ValueError(
+ 'max_window_size must be greater than window_size'
+ )
if not PY_VERSION_8 and not use_raw_array:
raise ValueError(
@@ -520,7 +522,9 @@ Source code for fury.stream.client
"""
def callback_for_vtk(caller, event, *args, **kwargs):
- callback_stream_client(**{'stream_client': kwargs['stream_client']})
+ callback_stream_client(
+ **{'stream_client': kwargs['stream_client']}
+ )
use_asyncio = platform.system() == 'Windows' or use_asyncio
if self._started:
@@ -528,18 +532,25 @@ Source code for fury.stream.client
if ms > 0:
if self._whithout_iren_start:
- Interval = IntervalTimer if use_asyncio else IntervalTimerThreading
+ Interval = (IntervalTimer if use_asyncio else
+ IntervalTimerThreading)
self._interval_timer = Interval(
- ms / 1000, callback_stream_client, **{'stream_client': self}
+ ms / 1000, callback_stream_client,
+ **{'stream_client': self}
)
else:
self._id_observer = self.showm.iren.AddObserver(
- 'TimerEvent', partial(callback_for_vtk, **{'stream_client': self})
+ 'TimerEvent', partial(
+ callback_for_vtk,
+ **{'stream_client': self})
)
self._id_timer = self.showm.iren.CreateRepeatingTimer(ms)
else:
self._id_observer = self.showm.iren.AddObserver(
- 'RenderEvent', partial(callback_for_vtk, **{'stream_client': self})
+ 'RenderEvent', partial(
+ callback_for_vtk,
+ **{'stream_client': self}
+ )
)
self.showm.window.Render()
self.showm.iren.Render()
@@ -641,12 +652,23 @@ Source code for fury.stream.client
camera.SetFocalPoint([pos2[i] + delta[i] for i in range(3)])
camera.Zoom(zoomFactor)
elif user_event_id == event_ids.mouse_move:
- iren.SetEventInformation(newX, newY, ctrl_key, shift_key, chr(0), 0, None)
+ iren.SetEventInformation(newX,
+ newY,
+ ctrl_key,
+ shift_key,
+ chr(0), 0, None)
iren.MouseMoveEvent()
elif event_ids.mouse_ids:
- iren.SetEventInformation(newX, newY, ctrl_key, shift_key, chr(0), 0, None)
+ iren.SetEventInformation(
+ newX,
+ newY,
+ ctrl_key,
+ shift_key,
+ chr(0),
+ 0,
+ None)
mouse_actions = {
event_ids.left_btn_press: iren.LeftButtonPressEvent,
event_ids.left_btn_release: iren.LeftButtonReleaseEvent,
@@ -656,7 +678,9 @@ Source code for fury.stream.client
event_ids.right_btn_release: iren.RightButtonReleaseEvent,
}
mouse_actions[user_event_id]()
- logging.info('Interaction: time to perform event ' + f'{ts-user_timestamp:.2f} ms')
+ logging.info(
+ 'Interaction: time to perform event ' + f'{ts-user_timestamp:.2f} ms'
+ )
if render_after:
showm.window.Render()
showm.iren.Render()
@@ -671,7 +695,11 @@ Source code for fury.stream.client
[docs]
def __init__(
- self, showm, max_queue_size=50, use_raw_array=True, whithout_iren_start=False
+ self,
+ showm,
+ max_queue_size=50,
+ use_raw_array=True,
+ whithout_iren_start=False
):
"""Initialize the StreamInteraction obj.
@@ -737,9 +765,14 @@ Source code for fury.stream.client
else:
def callback(caller, event, *args, **kwargs):
- interaction_callback(self.circular_queue, self.showm, self.iren, True)
+ interaction_callback(
+ self.circular_queue,
+ self.showm, self.iren,
+ True)
- self._id_observer = self.showm.iren.AddObserver('TimerEvent', callback)
+ self._id_observer = self.showm.iren.AddObserver(
+ 'TimerEvent',
+ callback)
self._id_timer = self.showm.iren.CreateRepeatingTimer(ms)
self._started = True
diff --git a/dev/_modules/fury/stream/server/async_app.html b/dev/_modules/fury/stream/server/async_app.html
index c595d9f3a..ac6f52560 100644
--- a/dev/_modules/fury/stream/server/async_app.html
+++ b/dev/_modules/fury/stream/server/async_app.html
@@ -7,7 +7,7 @@
- fury.stream.server.async_app — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.stream.server.async_app — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -432,7 +432,8 @@ Source code for fury.stream.server.async_app
status=200,
reason='OK',
headers={
- 'Content-Type': 'multipart/x-mixed-replace;boundary={}'.format(my_boundary)
+ 'Content-Type': 'multipart/x-mixed-replace;boundary={}'.format(
+ my_boundary)
},
)
await response.prepare(request)
@@ -518,7 +519,13 @@ Source code for fury.stream.server.async_app
circular_queue = circular_queue
ok = circular_queue.enqueue(
np.array(
- [EVENT_IDs.mouse_move, 0, x, y, ctrl_key, shift_key, user_envent_ms, 0],
+ [EVENT_IDs.mouse_move,
+ 0,
+ x,
+ y,
+ ctrl_key,
+ shift_key,
+ user_envent_ms, 0],
dtype='float64',
)
)
@@ -551,7 +558,8 @@ Source code for fury.stream.server.async_app
event_id = (mouse_button + 1) * 2 + on + 1
ok = circular_queue.enqueue(
- np.array([event_id, 0, x, y, ctrl, shift, user_envent_ms, 0], dtype='float64')
+ np.array([event_id, 0, x, y, ctrl, shift, user_envent_ms, 0],
+ dtype='float64')
)
return ok
@@ -584,7 +592,8 @@ Source code for fury.stream.server.async_app
if data['type'] == 'weel':
ts = time.time() * 1000
interval = ts - data['timestampInMs']
- logging.info('WEEL request time approx ' + f'{interval:.2f} ms')
+ logging.info('WEEL request time approx ' +
+ f'{interval:.2f} ms')
set_weel(data, circular_queue)
elif data['type'] == 'mouseMove':
set_mouse(data, circular_queue)
@@ -593,7 +602,9 @@ Source code for fury.stream.server.async_app
# await ws.send_str(msg.data + '/answer')
elif msg.type == aiohttp.WSMsgType.ERROR:
- print('ws connection closed with exception %s' % ws.exception())
+ print('ws connection closed with exception {}'.format(
+ ws.exception())
+ )
finally:
request.app['websockets'].discard(ws)
@@ -637,7 +648,9 @@ Source code for fury.stream.server.async_app
'interaction.js',
]
for js in js_files:
- app.router.add_get('/js/%s' % js, partial(javascript, folder=folder, js=js))
+ app.router.add_get('/js/%s' % js, partial(javascript,
+ folder=folder,
+ js=js))
app['image_buffer_manager'] = image_buffer_manager
if provides_mjpeg:
@@ -650,7 +663,8 @@ Source code for fury.stream.server.async_app
if circular_queue is not None:
app.add_routes(
- [web.get('/ws', partial(websocket_handler, circular_queue=circular_queue))]
+ [web.get('/ws', partial(websocket_handler,
+ circular_queue=circular_queue))]
)
return app
diff --git a/dev/_modules/fury/stream/server/main.html b/dev/_modules/fury/stream/server/main.html
index 5f7f386bc..92dd28d41 100644
--- a/dev/_modules/fury/stream/server/main.html
+++ b/dev/_modules/fury/stream/server/main.html
@@ -7,7 +7,7 @@
- fury.stream.server.main — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.stream.server.main — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -470,7 +470,7 @@ Source code for fury.stream.server.main
# if the buffer it's already flipped
# self.frame.planes[0].update(self.image)
self.image = np.frombuffer(self.image, 'uint8')[
- 0 : width * height * 3
+ 0: width * height * 3
].reshape((height, width, 3))
self.image = np.flipud(self.image)
self.frame = VideoFrame.from_ndarray(self.image)
@@ -653,7 +653,8 @@ Source code for fury.stream.server.main
remove_shm_from_resource_tracker()
image_buffer_manager = SharedMemImageBufferManager(
- image_buffer_names=image_buffer_names, info_buffer_name=info_buffer_name
+ image_buffer_names=image_buffer_names,
+ info_buffer_name=info_buffer_name
)
rtc_server = None
diff --git a/dev/_modules/fury/stream/tools.html b/dev/_modules/fury/stream/tools.html
index 832ad32bd..279bb32d6 100644
--- a/dev/_modules/fury/stream/tools.html
+++ b/dev/_modules/fury/stream/tools.html
@@ -7,7 +7,7 @@
- fury.stream.tools — FURY 0.11.0.dev27+g14851c6a documentation
+ fury.stream.tools — FURY 0.11.0.dev28+g342bf695 documentation
@@ -43,7 +43,7 @@
-
+
@@ -389,13 +389,13 @@ Source code for fury.stream.tools
if PY_VERSION_8:
from multiprocessing import resource_tracker, shared_memory
else:
- shared_memory = None # type: ignore
+ shared_memory = None # type: ignore
-_FLOAT_ShM_TYPE = 'd'
-_INT_ShM_TYPE = 'i'
-_UINT_ShM_TYPE = 'I'
-_BYTE_ShM_TYPE = 'B'
+_FLOAT_ShM_TYPE = "d"
+_INT_ShM_TYPE = "i"
+_UINT_ShM_TYPE = "I"
+_BYTE_ShM_TYPE = "B"
_FLOAT_SIZE = np.dtype(_FLOAT_ShM_TYPE).itemsize
_INT_SIZE = np.dtype(_INT_ShM_TYPE).itemsize
@@ -416,27 +416,31 @@ Source code for fury.stream.tools
"""
def fix_register(name, rtype):
- if rtype == 'shared_memory':
+ if rtype == "shared_memory":
return
try:
- return resource_tracker._resource_tracker.register(self, name, rtype)
+ return resource_tracker._resource_tracker.register(
+ self, name, rtype
+ )
except NameError:
return None
resource_tracker.register = fix_register
def fix_unregister(name, rtype):
- if rtype == 'shared_memory':
+ if rtype == "shared_memory":
return
try:
- return resource_tracker._resource_tracker.unregister(self, name, rtype)
+ return resource_tracker._resource_tracker.unregister(
+ self, name, rtype
+ )
except NameError:
return None
resource_tracker.unregister = fix_unregister
- if 'shared_memory' in resource_tracker._CLEANUP_FUNCS:
- del resource_tracker._CLEANUP_FUNCS['shared_memory']
+ if "shared_memory" in resource_tracker._CLEANUP_FUNCS:
+ del resource_tracker._CLEANUP_FUNCS["shared_memory"]
@@ -487,12 +491,12 @@ Source code for fury.stream.tools
def __getitem__(self, idx):
start, end = self.get_start_end(idx)
- logging.info(f'dequeue start {int(time.time()*1000)}')
+ logging.info(f"dequeue start {int(time.time()*1000)}")
ts = time.time() * 1000
items = self._buffer_repr[start:end]
te = time.time() * 1000
- logging.info(f'dequeue frombuffer cost {te-ts:.2f}')
+ logging.info(f"dequeue frombuffer cost {te-ts:.2f}")
return items
def __setitem__(self, idx, data):
@@ -505,22 +509,19 @@ Source code for fury.stream.tools
+ def load_mem_resource(self): ... # pragma: no cover
+ def create_mem_resource(self): ... # pragma: no cover
+ def cleanup(self): ... # pragma: no cover
@@ -628,16 +629,20 @@ Source code for fury.stream.tools
def create_mem_resource(self):
self._num_el = self.dimension * (self.max_size + 1)
buffer_arr = np.zeros(self._num_el + 2, dtype=_FLOAT_ShM_TYPE)
- self._buffer = shared_memory.SharedMemory(create=True, size=buffer_arr.nbytes)
+ self._buffer = shared_memory.SharedMemory(
+ create=True, size=buffer_arr.nbytes
+ )
sizes = np.ndarray(
- 2, dtype=_FLOAT_ShM_TYPE, buffer=self._buffer.buf[0 : _FLOAT_SIZE * 2]
+ 2,
+ dtype=_FLOAT_ShM_TYPE,
+ buffer=self._buffer.buf[0: _FLOAT_SIZE * 2]
)
sizes[0] = self.max_size
sizes[1] = self.dimension
self.buffer_name = self._buffer.name
logging.info(
[
- 'create repr multidimensional buffer ',
+ "create repr multidimensional buffer ",
]
)
@@ -646,14 +651,16 @@ Source code for fury.stream.tools
[docs]
def load_mem_resource(self):
self._buffer = shared_memory.SharedMemory(self.buffer_name)
- sizes = np.ndarray(2, dtype='d', buffer=self._buffer.buf[0 : _FLOAT_SIZE * 2])
+ sizes = np.ndarray(
+ 2, dtype="d", buffer=self._buffer.buf[0: _FLOAT_SIZE * 2]
+ )
self.max_size = int(sizes[0])
self.dimension = int(sizes[1])
num_el = int((sizes[0] + 1) * sizes[1])
self._num_el = num_el
logging.info(
[
- 'load repr multidimensional buffer',
+ "load repr multidimensional buffer",
]
)
@@ -662,15 +669,17 @@ Source code for fury.stream.tools
start = _FLOAT_SIZE * 2
end = (self._num_el + 2) * _FLOAT_SIZE
self._buffer_repr = np.ndarray(
- self._num_el, dtype=_FLOAT_ShM_TYPE, buffer=self._buffer.buf[start:end]
+ self._num_el,
+ dtype=_FLOAT_ShM_TYPE,
+ buffer=self._buffer.buf[start:end]
)
logging.info(
[
- 'create repr multidimensional buffer',
+ "create repr multidimensional buffer",
self._buffer_repr.shape,
- 'max size',
+ "max size",
self.max_size,
- 'dimension',
+ "dimension",
self.dimension,
]
)
@@ -688,8 +697,8 @@ Source code for fury.stream.tools
self._buffer.unlink()
except FileNotFoundError:
print(
- f'Shared Memory {self.buffer_name}(queue_event_buffer)\
- File not found'
+ f"Shared Memory {self.buffer_name}(queue_event_buffer)\
+ File not found"
)
@@ -749,7 +758,9 @@ Source code for fury.stream.tools
if self._use_shared_mem:
return self.head_tail_buffer_repr[0]
else:
- return np.frombuffer(self.head_tail_buffer.get_obj(), _INT_ShM_TYPE)[0]
+ return np.frombuffer(
+ self.head_tail_buffer.get_obj(), _INT_ShM_TYPE
+ )[0]
@head.setter
def head(self, value):
@@ -760,7 +771,9 @@ Source code for fury.stream.tools
if self._use_shared_mem:
return self.head_tail_buffer_repr[1]
else:
- return np.frombuffer(self.head_tail_buffer.get_obj(), _INT_ShM_TYPE)[1]
+ return np.frombuffer(
+ self.head_tail_buffer.get_obj(), _INT_ShM_TYPE
+ )[1]
@tail.setter
def tail(self, value):
@@ -846,7 +859,12 @@ Source code for fury.stream.tools
[docs]
- def __init__(self, max_size=10, dimension=6, head_tail_buffer=None, buffer=None):
+ def __init__(
+ self,
+ max_size=10,
+ dimension=6,
+ head_tail_buffer=None,
+ buffer=None):
"""Stream system uses that to implement user interactions
Parameters
@@ -867,7 +885,11 @@ Source code for fury.stream.tools
RawArray to store the data
"""
- super().__init__(max_size, dimension, use_shared_mem=False, buffer=buffer)
+ super().__init__(
+ max_size,
+ dimension,
+ use_shared_mem=False,
+ buffer=buffer)
if head_tail_buffer is None:
self.create_mem_resource()
@@ -935,7 +957,11 @@ Source code for fury.stream.tools