diff --git a/docs/datahandling.md b/docs/datahandling.md deleted file mode 100644 index 894f8feda03baf30304efbf1d52dcbd01bf2e8f6..0000000000000000000000000000000000000000 --- a/docs/datahandling.md +++ /dev/null @@ -1,28 +0,0 @@ -# Data handling -Dealing with volumetric data can be done by `qim3d` for the most common image formats available. This includes loading, saving and file conversions. - -Currently, it is possible to directly load `tiff`, `h5`, `nii`,`txm`, `vol` and common `PIL` formats using one single function. - -Additionally, synthtetic volumetric data can be generated using the `generate` module. - -::: qim3d.io - options: - members: - - load - - save - - Downloader - - export_ome_zarr - - import_ome_zarr - - save_mesh - - load_mesh - -::: qim3d.mesh - options: - members: - - from_volume - -::: qim3d.generate - options: - members: - - noise_object - - noise_object_collection diff --git a/docs/cli.md b/docs/doc/cli/cli.md similarity index 91% rename from docs/cli.md rename to docs/doc/cli/cli.md index c2f878cc1cb4058458f636be21f63d9ebe4510ab..58fae7e2253830a9ab3156712fe7fac14d2c3f24 100644 --- a/docs/cli.md +++ b/docs/doc/cli/cli.md @@ -1,3 +1,8 @@ +--- +hide: + - navigation +--- + # Command line interface The library also includes a command line interface for easy access to some functionalities, and the convenience of using qim3d directly from your terminal. @@ -7,7 +12,7 @@ This offers quick interactions, making it ideal for tasks that require efficienc ``` title="Command" qim3d gui --data-explorer ``` -  +  ## Graphical User Interfaces @@ -50,7 +55,7 @@ The command line interface allows you to run graphical user interfaces directly In this case, the GUI will be available at `http://127.0.0.1:7860` -  +  !!! Example @@ -82,7 +87,7 @@ The command line interface allows you to run graphical user interfaces directly In this case, the GUI will be available at `http://127.0.0.1:47326/gui/fima/47326/` -  +  @@ -127,7 +132,7 @@ You can launch volumetric visualizations directly from the command line. By defa A new tab in the default browser will be open with the visualization: -  +  !!! Example "Example using k3d" ``` title="Command" @@ -152,7 +157,7 @@ You can launch volumetric visualizations directly from the command line. By defa ``` And a new tab will be opened in the default browser with the interactive k3d plot: - { width="512" } + { width="512" } Or an specific path for destination can be used. We can also choose to not open the browser: @@ -196,32 +201,32 @@ File previewing can also be done directly from the command line interface to pre qim3d preview blobs_256x256x256.tif ``` - { width="512" } + { width="512" } !!! Example ``` title="Command" qim3d preview blobs_256x256x256.tif --resolution 30 ``` - { width="512" } + { width="512" } !!! Example ``` title="Command" qim3d preview blobs_256x256x256.tif --resolution 50 --axis 1 ``` - { width="512" } + { width="512" } !!! Example ``` title="Command" qim3d preview blobs_256x256x256.tif --resolution 50 --axis 2 --slice 0 ``` - { width="512" } + { width="512" } !!! Example ``` title="Command" qim3d preview qim_logo.png --resolution 40 ``` - { width="512" } + { width="512" } diff --git a/docs/doc/data_handling/generate.md b/docs/doc/data_handling/generate.md new file mode 100644 index 0000000000000000000000000000000000000000..6a414d1681c59031b643e84f36ab82baf5df567a --- /dev/null +++ b/docs/doc/data_handling/generate.md @@ -0,0 +1,7 @@ +# Synthetic data generation + +::: qim3d.generate + options: + members: + - noise_object + - noise_object_collection diff --git a/docs/doc/data_handling/io.md b/docs/doc/data_handling/io.md new file mode 100644 index 0000000000000000000000000000000000000000..82c984bbced233b2a35836bdd072e3c73aa8bf8b --- /dev/null +++ b/docs/doc/data_handling/io.md @@ -0,0 +1,12 @@ +# Input and output + +::: qim3d.io + options: + members: + - load + - save + - Downloader + - export_ome_zarr + - import_ome_zarr + - save_mesh + - load_mesh \ No newline at end of file diff --git a/docs/gui.md b/docs/doc/gui/gui.md similarity index 81% rename from docs/gui.md rename to docs/doc/gui/gui.md index ef996896db91d26a02037f28f288ece44d0892d3..681041fc4f2515ce6c89112b07c12d1d407f44f3 100644 --- a/docs/gui.md +++ b/docs/doc/gui/gui.md @@ -1,3 +1,8 @@ +--- +hide: + - navigation +--- + # Graphical User Interfaces The `qim3d` library provides a set of custom made GUIs that ease the interaction with the available tools. @@ -21,17 +26,17 @@ For details see [here](cli.md#qim3d-gui). ::: qim3d.gui.data_explorer options: members: False - + ::: qim3d.gui.local_thickness options: members: False - + ::: qim3d.gui.iso3d options: members: False - + ::: qim3d.gui.annotation_tool options: diff --git a/docs/detection.md b/docs/doc/image_analysis/detection.md similarity index 100% rename from docs/detection.md rename to docs/doc/image_analysis/detection.md diff --git a/docs/features.md b/docs/doc/image_analysis/features.md similarity index 100% rename from docs/features.md rename to docs/doc/image_analysis/features.md diff --git a/docs/filters.md b/docs/doc/image_analysis/filters.md similarity index 100% rename from docs/filters.md rename to docs/doc/image_analysis/filters.md diff --git a/docs/doc/image_analysis/mesh.md b/docs/doc/image_analysis/mesh.md new file mode 100644 index 0000000000000000000000000000000000000000..bcedeb5573d6eb28ecb8e1c98d83b6ca4f09c1b7 --- /dev/null +++ b/docs/doc/image_analysis/mesh.md @@ -0,0 +1,4 @@ +::: qim3d.mesh + options: + members: + - from_volume diff --git a/docs/operations.md b/docs/doc/image_analysis/operations.md similarity index 100% rename from docs/operations.md rename to docs/doc/image_analysis/operations.md diff --git a/docs/processing.md b/docs/doc/image_analysis/processing.md similarity index 100% rename from docs/processing.md rename to docs/doc/image_analysis/processing.md diff --git a/docs/segmentation.md b/docs/doc/image_analysis/segmentation.md similarity index 100% rename from docs/segmentation.md rename to docs/doc/image_analysis/segmentation.md diff --git a/docs/models.md b/docs/doc/ml/models.md similarity index 82% rename from docs/models.md rename to docs/doc/ml/models.md index a3e0f8409ecd3d32a03b799e4ad1fe21c90f2114..af961f700a70d2ea4861519fc1c931476b324c52 100644 --- a/docs/models.md +++ b/docs/doc/ml/models.md @@ -1,3 +1,9 @@ +--- +hide: + - navigation + - toc +--- + # Machine learning models The `qim3d` library aims to ease the creation of ML models for volumetric images diff --git a/docs/releases.md b/docs/doc/releases/releases.md similarity index 87% rename from docs/releases.md rename to docs/doc/releases/releases.md index abbd81777bb6de085c81fa7689bb3cc879cc50fc..dcc9c2e2f5c107377ab3d7a89c00d74112739c4a 100644 --- a/docs/releases.md +++ b/docs/doc/releases/releases.md @@ -1,3 +1,9 @@ +--- +hide: + - navigation + +--- + # Release History [](https://badge.fury.io/py/qim3d) [](https://pepy.tech/project/qim3d) @@ -19,18 +25,18 @@ And remember to keep your pip installation [up to date](index.md/#get-the-latest ### v0.4.4 (11/10/2024) -- Introduction of `itk-vtk-viewer` for OME-Zarr data visualization 🎉  +- Introduction of `itk-vtk-viewer` for OME-Zarr data visualization 🎉  ### v0.4.3 (02/10/2024) - Updated requirements -- Introduction of mesh generation, visualization, saving and loading 🎉  +- Introduction of mesh generation, visualization, saving and loading 🎉  ### v0.4.2 (30/09/2024) - Export and import is now possible in the OME-Zarr standard, including multi-scale datasets. -- Filters now have the option to use Dask when available  +- Filters now have the option to use Dask when available  ### v0.4.1 (30/07/2024) @@ -50,9 +56,9 @@ And remember to keep your pip installation [up to date](index.md/#get-the-latest - Loading and saving for Zarr files - File convertion using the CLI, including Zarr - Refactoring for the GUIs -- Color visualization for structure tensor  +- Color visualization for structure tensor  - Refactoring for synthetic data generation, from `utils` to `generate` -- Introduction of `qim3d.generate.collection` 🎉  +- Introduction of `qim3d.generate.collection` 🎉  ### v0.3.8 (20/06/2024) @@ -61,22 +67,22 @@ And remember to keep your pip installation [up to date](index.md/#get-the-latest ### v0.3.7 (17/06/2024) - Performance improvements when importing -- Refactoring for blob detection  +- Refactoring for blob detection  ### v0.3.6 (30/05/2024) - Refactoring for performance improvement - Welcome message for the CLI -- Introduction of `qim3d.processing.fade_mask` 🎉  +- Introduction of `qim3d.processing.fade_mask` 🎉  ### v0.3.5 (27/05/2024) - Added runtime and memory usage in the documentation -- Introduction of `qim3d.utils.generate_volume` 🎉  -- CLI refactoring, adding welcome message to the user  +- Introduction of `qim3d.utils.generate_volume` 🎉  +- CLI refactoring, adding welcome message to the user  - Introduction of `preview` CLI 🎉 diff --git a/docs/viz.md b/docs/doc/visualization/viz.md similarity index 95% rename from docs/viz.md rename to docs/doc/visualization/viz.md index c538608987668f683db7b0a2f10db41bdf937836..0f22a927ac31aaab6a0940fdbaa075caab389d0f 100644 --- a/docs/viz.md +++ b/docs/doc/visualization/viz.md @@ -1,3 +1,8 @@ +--- +hide: + - navigation +--- + # Data visualization The `qim3d` library aims to provide easy ways to explore and get insights from volumetric data. diff --git a/docs/index.md b/docs/index.md index eddb3a9b05946c1ca79cf8a294b77de142c0c7bd..2afac8087c0ac759d13747921ed587f8e428df5e 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,3 +1,8 @@ +--- +hide: + - navigation +--- + <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0-beta3/css/all.min.css"> <audio id="audio" src="assets/qim3d.mp3"></audio> @@ -215,14 +220,16 @@ Below is a list of contributors to the project, arranged in chronological order | Author | Commits | First commit | |:----------------------------|----------:|-------------:| -| Felipe Delestro | 231 | 2023-05-12 | +| Felipe Delestro | 254 | 2023-05-12 | | Stefan Engelmann Jensen | 29 | 2023-06-29 | | Oskar Kristoffersen | 15 | 2023-07-05 | -| Christian Kento Rasmussen | 22 | 2024-02-01 | -| Alessia Saccardo | 13 | 2024-02-19 | -| David Grundfest | 16 | 2024-04-12 | -| Anna Bøgevang Ekner | 6 | 2024-04-18 | -| David Diamond Wang Johansen | 1 | 2024-10-31 | +| Christian Kento Rasmussen | 23 | 2024-02-01 | +| Alessia Saccardo | 14 | 2024-02-19 | +| David Grundfest | 19 | 2024-04-12 | +| Anna Bøgevang Ekner | 7 | 2024-04-18 | +| David Diamond Wang Johansen | 2 | 2024-10-31 | +| Oscar Flensburg Clausen | 5 | 2024-11-20 | +| Hans Martin Kjer | 1 | 2024-12-02 | ## Support diff --git a/docs/utils.md b/docs/utils.md deleted file mode 100644 index 3becb903d07477d8b310bfb201aa842d47c17334..0000000000000000000000000000000000000000 --- a/docs/utils.md +++ /dev/null @@ -1,8 +0,0 @@ -# Utils - -A set of tools to ease managment of the system, with the common needs for large data in mind. - -::: qim3d.utils - options: - members: - - Memory \ No newline at end of file diff --git a/mkdocs.yml b/mkdocs.yml index 10c59f55d3dfb2a5ce75b8754e9fd98d48f7b347..cfcd31f08b8d744486e4516fd7e7a989a4e3f90f 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -7,20 +7,22 @@ repo_name: Gitlab nav: - - qim3d: index.md - - Data handling: datahandling.md - - Visualization: viz.md - - Features: features.md - - Filters: filters.md - - Detection: detection.md - - Segmentation: segmentation.md - - Operations: operations.md - - Processing: processing.md - - ML Models: models.md - - GUIs: gui.md - - CLI: cli.md - - - Release history: releases.md + - Data handling: + - Input and Output: doc/data_handling/io.md + - Synthetic data: doc/data_handling/generate.md + - Visualization: doc/visualization/viz.md + - Image analysis: + - Features: doc/image_analysis/features.md + - Filters: doc/image_analysis/filters.md + - Detection: doc/image_analysis/detection.md + - Segmentation: doc/image_analysis/segmentation.md + - Operations: doc/image_analysis/operations.md + - Processing: doc/image_analysis/processing.md + - Meshes: doc/image_analysis/mesh.md + - Machine Learning: doc/ml/models.md + - Graphical User Interfaces: doc/gui/gui.md + - Command Line Interface: doc/cli/cli.md + - Release history: doc/releases/releases.md theme: language: en @@ -35,7 +37,7 @@ theme: - navigation.expand - navigation.instant # - navigation.tracking - - toc.integrate + # - toc.integrate # - toc.follow - search.suggest # - content.tabs.link @@ -87,6 +89,6 @@ plugins: show_source: true show_root_full_path: true show_object_full_path: true - show_symbol_type_heading: true + show_symbol_type_heading: false show_symbol_type_toc: false separate_signature: true \ No newline at end of file diff --git a/qim3d/detection/_common_detection_methods.py b/qim3d/detection/_common_detection_methods.py index 71a4b348a417c4a13a74edd25615681c6c8a00ee..3049baef5dbfee1e9f053cd19e8e8c2f79a01a0a 100644 --- a/qim3d/detection/_common_detection_methods.py +++ b/qim3d/detection/_common_detection_methods.py @@ -56,13 +56,13 @@ def blobs( # Visualize detected blobs qim3d.viz.circles(blobs, vol, alpha=0.8, color='blue') ``` -  +  ```python # Visualize binary binary_volume qim3d.viz.slicer(binary_volume) ``` -  +  """ from skimage.feature import blob_dog diff --git a/qim3d/filters/_common_filter_methods.py b/qim3d/filters/_common_filter_methods.py index bc4b02f0de5e94eb3e41a17786a04b950a36696d..4faf7365216885eecce388e129fc8cb11ca0a6ab 100644 --- a/qim3d/filters/_common_filter_methods.py +++ b/qim3d/filters/_common_filter_methods.py @@ -141,8 +141,8 @@ class Pipeline: # Show filtered fig2 = qim3d.viz.slices_grid(vol_filtered, num_slices=5, display_figure=True) ``` -  -  +  +  """ diff --git a/qim3d/generate/_aggregators.py b/qim3d/generate/_aggregators.py index 0eb09086de627446ea00279df2064167b2695d29..c1d834c6d9317abd445900ac703a4cb5fb673de4 100644 --- a/qim3d/generate/_aggregators.py +++ b/qim3d/generate/_aggregators.py @@ -199,14 +199,14 @@ def noise_object_collection( ```python qim3d.viz.slicer(synthetic_collection) ``` -  +  ```python # Visualize labels cmap = qim3d.viz.colormaps.segmentation(num_labels=num_objects) qim3d.viz.slicer(labels, color_map=cmap, value_max=num_objects) ``` -  +  Example: ```python @@ -257,7 +257,7 @@ def noise_object_collection( # Visualize slices qim3d.viz.slices_grid(vol, num_slices=15) ``` -  +  Example: ```python @@ -287,7 +287,7 @@ def noise_object_collection( # Visualize slices qim3d.viz.slices_grid(vol, num_slices=15, slice_axis=1) ``` -  +  """ if verbose: original_log_level = log.getEffectiveLevel() diff --git a/qim3d/generate/_generators.py b/qim3d/generate/_generators.py index 15578a67e341790a4433a6b0069d1273c87f007b..ed54b8b4de9fef663caea00fd75429524c7c5f0e 100644 --- a/qim3d/generate/_generators.py +++ b/qim3d/generate/_generators.py @@ -54,7 +54,7 @@ def noise_object( # Visualize slices qim3d.viz.slices_grid(vol, value_min = 0, value_max = 255, num_slices = 15) ``` -  +  Example: ```python @@ -78,7 +78,7 @@ def noise_object( # Visualize slices qim3d.viz.slices_grid(vol, num_slices=15, slice_axis=1) ``` -  +  Example: ```python @@ -102,7 +102,7 @@ def noise_object( # Visualize qim3d.viz.slices_grid(vol, num_slices=15) ``` -  +  """ if not isinstance(final_shape, tuple) or len(final_shape) != 3: diff --git a/qim3d/gui/annotation_tool.py b/qim3d/gui/annotation_tool.py index a3cac14e168316c34408e9304f7e05266370c8b8..8f386da385ab9e26c089a99670fb972f2afc17bd 100644 --- a/qim3d/gui/annotation_tool.py +++ b/qim3d/gui/annotation_tool.py @@ -16,7 +16,7 @@ annotation_tool = qim3d.gui.annotation_tool.Interface() # We can directly pass the image we loaded to the interface app = annotation_tool.launch(vol[0]) ``` - + """ diff --git a/qim3d/gui/layers2d.py b/qim3d/gui/layers2d.py index 8b7ae4419f2fc388c8e020d2b39556c83d585ff4..5a25f6e975a084b263fc5a3657aa72eed01ed94a 100644 --- a/qim3d/gui/layers2d.py +++ b/qim3d/gui/layers2d.py @@ -13,7 +13,7 @@ import qim3d layers = qim3d.gui.layers2d.Interface() app = layers.launch() ``` - + """ diff --git a/qim3d/io/_downloader.py b/qim3d/io/_downloader.py index 3d7724bb1ed0b3cdcccc841fdcf535a1f199cb83..89e3759d9a2c30a9eb557ba45d8a5dc0152165f3 100644 --- a/qim3d/io/_downloader.py +++ b/qim3d/io/_downloader.py @@ -54,7 +54,7 @@ class Downloader: qim3d.viz.slicer_orthogonal(data, color_map="magma") ``` -  +  """ def __init__(self): diff --git a/qim3d/operations/_common_operations_methods.py b/qim3d/operations/_common_operations_methods.py index 42932d5c292686903ccc4a3a3d23858e4d25612d..a83b25d26f223c2ad20ad2b383044f4a45a0ad38 100644 --- a/qim3d/operations/_common_operations_methods.py +++ b/qim3d/operations/_common_operations_methods.py @@ -32,7 +32,7 @@ def remove_background( vol = qim3d.examples.cement_128x128x128 fig1 = qim3d.viz.slices_grid(vol, value_min=0, value_max=255, num_slices=5, display_figure=True) ``` -  +  ```python vol_filtered = qim3d.operations.remove_background(vol, @@ -40,7 +40,7 @@ def remove_background( background="bright") fig2 = qim3d.viz.slices_grid(vol_filtered, value_min=0, value_max=255, num_slices=5, display_figure=True) ``` -  +  """ # Create a pipeline with a median filter and a tophat filter @@ -85,7 +85,7 @@ def fade_mask( qim3d.viz.volumetric(vol) ``` Image before edge fading has visible artifacts from the support. Which obscures the object of interest. -  +  ```python import qim3d @@ -93,7 +93,7 @@ def fade_mask( qim3d.viz.volumetrics(vol_faded) ``` Afterwards the artifacts are faded out, making the object of interest more visible for visualization purposes. -  +  """ if 0 > axis or axis >= vol.ndim: diff --git a/qim3d/processing/_layers.py b/qim3d/processing/_layers.py index 7e7ef93058cd58b678965cedbdb43d9924c01b22..b77a4834120fedf31b757b23d9a631c709cfc1f6 100644 --- a/qim3d/processing/_layers.py +++ b/qim3d/processing/_layers.py @@ -47,8 +47,8 @@ def segment_layers(data: np.ndarray, for layer_line in layer_lines: plt.plot(layer_line, linewidth = 3) ``` -  -  +  +  """ if isinstance(data, np.ndarray): diff --git a/qim3d/processing/_local_thickness.py b/qim3d/processing/_local_thickness.py index a38e9423599d30370a4f02f1f3de97f8b222eb15..12d6f19b664d61bb6bd8e0bc8db1347e8cd1c9a0 100644 --- a/qim3d/processing/_local_thickness.py +++ b/qim3d/processing/_local_thickness.py @@ -43,7 +43,7 @@ def local_thickness( vol = qim3d.examples.fly_150x256x256 lt_vol = qim3d.processing.local_thickness(vol, visualize=True, axis=0) ``` -  +  ```python import qim3d @@ -56,10 +56,10 @@ def local_thickness( lt_blobs = qim3d.processing.local_thickness(slice, visualize=True) ``` -  +  !!! info "Runtime and memory usage of the local thickness method for different volume sizes" -  +  Performance computed on Intel(R) Xeon(R) Gold 6226 CPU @ 2.70GHz. diff --git a/qim3d/processing/_structure_tensor.py b/qim3d/processing/_structure_tensor.py index f4343c972118decd9aa37a2405f448f77233fc1f..de73521274a1879ae02edf4ab9f459409f370cd2 100644 --- a/qim3d/processing/_structure_tensor.py +++ b/qim3d/processing/_structure_tensor.py @@ -47,11 +47,11 @@ def structure_tensor( vol = qim3d.examples.NT_128x128x128 val, vec = qim3d.processing.structure_tensor(vol, visualize = True, axis = 2) ``` -  +  !!! info "Runtime and memory usage of the structure tensor method for different volume sizes" -  +  Performance computed on Intel(R) Xeon(R) Gold 6226 CPU @ 2.70GHz. diff --git a/qim3d/segmentation/_common_segmentation_methods.py b/qim3d/segmentation/_common_segmentation_methods.py index 6baff849b112504bef23936cf99111608b21ff3e..fc6474597a34246f31ddcbc9634f0be803b831ed 100644 --- a/qim3d/segmentation/_common_segmentation_methods.py +++ b/qim3d/segmentation/_common_segmentation_methods.py @@ -26,7 +26,7 @@ def watershed(bin_vol: np.ndarray, min_distance: int = 5) -> tuple[np.ndarray, i fig1 = qim3d.viz.slices_grid(bin_vol, slice_axis=1, display_figure=True) ``` -  +  ```python labeled_volume, num_labels = qim3d.segmentation.watershed(bin_vol) @@ -34,7 +34,7 @@ def watershed(bin_vol: np.ndarray, min_distance: int = 5) -> tuple[np.ndarray, i cmap = qim3d.viz.colormaps.segmentation(num_labels) fig2 = qim3d.viz.slices_grid(labeled_volume, slice_axis=1, color_map=cmap, display_figure=True) ``` -  +  """ import skimage diff --git a/qim3d/viz/_cc.py b/qim3d/viz/_cc.py index 24d047afbb9442f1a05d847dbe836ae84058f520..8ace8abf830f3cc3e0cc7eb5219f90c90f378242 100644 --- a/qim3d/viz/_cc.py +++ b/qim3d/viz/_cc.py @@ -43,8 +43,8 @@ def plot_cc( qim3d.viz.plot_cc(cc, crop=True, display_figure=True, overlay=None, num_slices=5, component_indexs=[4,6,7]) qim3d.viz.plot_cc(cc, crop=True, display_figure=True, overlay=vol, num_slices=5, component_indexs=[4,6,7]) ``` -  -  +  +  """ # if no components are given, plot the first max_cc_to_plot=32 components if component_indexs is None: diff --git a/qim3d/viz/_data_exploration.py b/qim3d/viz/_data_exploration.py index c754604d44df47437ee7ea3e33deee751ce3681d..3544af79a28cd96bbe2608f81ed55e2d715ecd94 100644 --- a/qim3d/viz/_data_exploration.py +++ b/qim3d/viz/_data_exploration.py @@ -81,7 +81,7 @@ def slices_grid( vol = qim3d.examples.shell_225x128x128 qim3d.viz.slices_grid(vol, num_slices=15) ``` -  +  """ if image_size: image_height = image_size @@ -354,7 +354,7 @@ def slicer( vol = qim3d.examples.bone_128x128x128 qim3d.viz.slicer(vol) ``` -  +  """ if image_size: @@ -427,7 +427,7 @@ def slicer_orthogonal( vol = qim3d.examples.fly_150x256x256 qim3d.viz.slicer_orthogonal(vol, color_map="magma") ``` -  +  """ if image_size: @@ -484,7 +484,7 @@ def fade_mask( vol = qim3d.examples.cement_128x128x128 qim3d.viz.fade_mask(vol) ``` -  +  """ @@ -623,7 +623,7 @@ def chunks(zarr_path: str, **kwargs)-> widgets.interactive: # Explore chunks qim3d.viz.chunks("Escargot.zarr") ``` -  +  """ # Load the Zarr dataset @@ -904,7 +904,7 @@ def histogram( vol = qim3d.examples.bone_128x128x128 qim3d.viz.histogram(vol) ``` -  +  ```python import qim3d @@ -912,7 +912,7 @@ def histogram( vol = qim3d.examples.bone_128x128x128 qim3d.viz.histogram(vol, bins=32, slice_idx="middle", axis=1, kde=False, log_scale=True) ``` -  +  """ if not (0 <= axis < volume.ndim): diff --git a/qim3d/viz/_detection.py b/qim3d/viz/_detection.py index 200904de308604cb30888057c49007f353595f37..5b0ad9fc7059636f5d49a5d6ef4aac02c12fac2b 100644 --- a/qim3d/viz/_detection.py +++ b/qim3d/viz/_detection.py @@ -46,7 +46,7 @@ def circles(blobs: tuple[float,float,float,float], vol: np.ndarray, alpha: float # Visualize detected blobs with circles method qim3d.viz.circles(blobs, vol, alpha=0.8, color='blue') ``` -  +  """ def _slicer(z_slice): diff --git a/qim3d/viz/_local_thickness.py b/qim3d/viz/_local_thickness.py index 0f63c64165c965c58db59df7aa0ff986c677f0e4..9336ee32acb23ac4b9e9a43df2c5a1e045b3ea23 100644 --- a/qim3d/viz/_local_thickness.py +++ b/qim3d/viz/_local_thickness.py @@ -46,7 +46,7 @@ def local_thickness( lt_fly = qim3d.processing.local_thickness(fly) qim3d.viz.local_thickness(fly, lt_fly, axis=0) ``` -  +  """ diff --git a/qim3d/viz/_structure_tensor.py b/qim3d/viz/_structure_tensor.py index 43fb8b58b90d43de0104491643a7c8cc65ca0581..13d45e1f252e139c5a9cd2518280136a821e9443 100644 --- a/qim3d/viz/_structure_tensor.py +++ b/qim3d/viz/_structure_tensor.py @@ -69,7 +69,7 @@ def vectors( # Visualize the structure tensor qim3d.viz.vectors(vol, vec, axis = 2, interactive = True) ``` -  +  """ diff --git a/qim3d/viz/colormaps/_qim_colors.py b/qim3d/viz/colormaps/_qim_colors.py index 429151e1664ac911a2d07d9a8c27059153e55fec..3ac7a4005ee2d92f12a00a3588acb482fe308dc5 100644 --- a/qim3d/viz/colormaps/_qim_colors.py +++ b/qim3d/viz/colormaps/_qim_colors.py @@ -19,6 +19,6 @@ Example: display(qim3d.viz.colormaps.qim) ``` -  +  """ colormaps.register(qim) diff --git a/qim3d/viz/colormaps/_segmentation.py b/qim3d/viz/colormaps/_segmentation.py index 523714f849cef17f39a2cb855df305334728d844..715eb6da5cbdac3c7a50487782e24a40c028b0bd 100644 --- a/qim3d/viz/colormaps/_segmentation.py +++ b/qim3d/viz/colormaps/_segmentation.py @@ -71,7 +71,7 @@ def segmentation( display(cmap_earth) display(cmap_ocean) ``` -  +  ```python import qim3d @@ -83,7 +83,7 @@ def segmentation( color_map = qim3d.viz.colormaps.segmentation(num_labels, style = 'bright') qim3d.viz.slicer(labeled_volume, slice_axis = 1, color_map=color_map) ``` -  +  Tip: It can be easily used when calling visualization functions as @@ -95,7 +95,7 @@ def segmentation( Tip: The `min_dist` parameter can be used to control the distance between neighboring colors. -  +  """ from skimage import color