From f106b7331feb94f9169a6f49a8bf9898b1598bd7 Mon Sep 17 00:00:00 2001 From: mrbean-bremen Date: Tue, 13 Jan 2026 08:38:46 +0100 Subject: [PATCH] Do not use deprecated canonifyURLs - this had some unwanted side effects - adapt all URLs to work without the setting (remove /) - do not use absolute links to the site URL --- README.md | 16 ++--- mevislab.github.io/content/about/about.md | 2 +- .../basic_mechanisms/contour_filter/index.md | 4 +- .../example1/index.md | 4 +- .../example2/index.md | 6 +- .../viewer_application/index.md | 4 +- .../data_objects/contours/example1/index.md | 6 +- .../data_objects/contours/example2/index.md | 4 +- .../data_objects/contours/example3/index.md | 4 +- .../data_objects/contours/example4/index.md | 4 +- .../data_objects/contours/example5/index.md | 4 +- .../data_objects/curves/example1/index.md | 4 +- .../data_objects/markers/example1/index.md | 4 +- .../surface_objects/example1/index.md | 4 +- .../surface_objects/example2/index.md | 4 +- .../surface_objects/example3/index.md | 8 +-- .../surface_objects/example4/index.md | 4 +- .../surface_objects/example5/index.md | 4 +- mevislab.github.io/content/examples/howto.md | 6 +- .../image_processing/example1/index.md | 4 +- .../image_processing/example2/index.md | 4 +- .../image_processing/example3/index.md | 4 +- .../image_processing/example4/index.md | 4 +- .../image_processing/example5/index.md | 4 +- .../examples/open_inventor/example1/index.md | 4 +- .../examples/open_inventor/example2/index.md | 4 +- .../examples/open_inventor/example3/index.md | 4 +- .../examples/open_inventor/example4/index.md | 4 +- .../examples/testing/Example1/index.md | 2 +- .../examples/thirdparty/example1/index.md | 2 +- .../examples/thirdparty/example2/index.md | 2 +- .../examples/thirdparty/pytorch1/index.md | 4 +- .../examples/visualization/example1/index.md | 4 +- .../examples/visualization/example2/index.md | 4 +- .../examples/visualization/example3/index.md | 4 +- .../examples/visualization/example4/index.md | 4 +- .../examples/visualization/example5/index.md | 4 +- .../examples/visualization/example6/index.md | 4 +- .../content/introduction/introduction.md | 66 +++++++++---------- .../content/tutorials/basicmechanisms.md | 46 ++++++------- .../coordinatesystems/coordinatesystems.md | 34 +++++----- .../coordinatesystems/coordinatesystems2.md | 10 +-- .../tutorials/basicmechanisms/dataimport.md | 26 ++++---- .../tutorials/basicmechanisms/macromodules.md | 18 ++--- .../macromodules/globalmacromodules.md | 14 ++-- .../basicmechanisms/macromodules/guidesign.md | 20 +++--- .../basicmechanisms/macromodules/helpfiles.md | 18 ++--- .../macromodules/itemmodelview.md | 16 ++--- .../basicmechanisms/macromodules/package.md | 4 +- .../macromodules/pythondebugger.md | 22 +++---- .../basicmechanisms/macromodules/pythonpip.md | 4 +- .../macromodules/pythonscripting.md | 10 +-- .../macromodules/scriptingexample1.md | 6 +- .../macromodules/scriptingexample2.md | 26 ++++---- .../macromodules/soviewportregion.md | 36 +++++----- .../content/tutorials/dataobjects.md | 6 +- .../tutorials/dataobjects/contourobjects.md | 10 +-- .../dataobjects/contours/contourexample1.md | 16 ++--- .../dataobjects/contours/contourexample2.md | 20 +++--- .../dataobjects/contours/contourexample3.md | 10 +-- .../dataobjects/contours/contourexample4.md | 10 +-- .../dataobjects/contours/contourexample5.md | 6 +- .../dataobjects/contours/contourexample6.md | 26 ++++---- .../dataobjects/contours/contourexample7.md | 12 ++-- .../content/tutorials/dataobjects/curves.md | 2 +- .../dataobjects/curves/curvesexample1.md | 20 +++--- .../tutorials/dataobjects/markerobjects.md | 8 +-- .../dataobjects/markers/markerexample1.md | 12 ++-- .../tutorials/dataobjects/surfaceobjects.md | 12 ++-- .../dataobjects/surfaces/surfaceexample1.md | 8 +-- .../dataobjects/surfaces/surfaceexample2.md | 18 ++--- .../dataobjects/surfaces/surfaceexample3.md | 28 ++++---- .../dataobjects/surfaces/surfaceexample4.md | 34 +++++----- .../dataobjects/surfaces/surfaceexample5.md | 22 +++---- .../image_processing/image_processing1.md | 6 +- .../image_processing/image_processing2.md | 14 ++-- .../image_processing/image_processing3.md | 18 ++--- .../image_processing/image_processing4.md | 16 ++--- .../image_processing/image_processing5.md | 24 +++---- .../image_processing/image_processing6.md | 28 ++++---- .../content/tutorials/openinventor.md | 4 +- .../openinventor/camerainteraction.md | 16 ++--- .../openinventor/mouseinteractions.md | 8 +-- .../openinventor/openinventorobjects.md | 20 +++--- .../openinventor/posteffectsinopeninventor.md | 20 +++--- .../content/tutorials/shorts.md | 28 ++++---- .../content/tutorials/summary.md | 6 +- .../content/tutorials/summary/summary1.md | 32 ++++----- .../content/tutorials/summary/summary2.md | 24 +++---- .../content/tutorials/summary/summary3.md | 16 ++--- .../content/tutorials/summary/summary4.md | 20 +++--- .../content/tutorials/summary/summary5.md | 34 +++++----- .../content/tutorials/summary/summary6.md | 2 +- .../content/tutorials/summary/summary7.md | 10 +-- .../content/tutorials/summary/summary8.md | 34 +++++----- .../content/tutorials/testing.md | 8 +-- .../tutorials/testing/testingexample1.md | 12 ++-- .../tutorials/testing/testingexample2.md | 10 +-- .../tutorials/testing/testingexample3.md | 12 ++-- .../thirdparty/MONAI/monaiexample1.md | 8 +-- .../thirdparty/MONAI/monaiexample2.md | 32 ++++----- .../content/tutorials/thirdparty/assimp.md | 2 +- .../thirdparty/assimp/assimpexample1.md | 14 ++-- .../tutorials/thirdparty/matplotlib.md | 8 +-- .../thirdparty/matplotlib/2Dplotting.md | 16 ++--- .../thirdparty/matplotlib/3Dplotting.md | 6 +- .../thirdparty/matplotlib/modulesetup.md | 10 +-- .../thirdparty/matplotlib/slicecomparison.md | 10 +-- .../content/tutorials/thirdparty/monai.md | 4 +- .../thirdparty/opencv/thirdpartyexample1.md | 4 +- .../thirdparty/opencv/thirdpartyexample2.md | 6 +- .../content/tutorials/thirdparty/pytorch.md | 2 +- .../thirdparty/pytorch/pytorchexample1.md | 16 ++--- .../thirdparty/pytorch/pytorchexample2.md | 24 +++---- .../thirdparty/pytorch/pytorchexample3.md | 22 +++---- .../content/tutorials/visualization.md | 6 +- .../pathtracer/pathtracerexample1.md | 38 +++++------ .../pathtracer/pathtracerexample2.md | 50 +++++++------- .../visualization/visualizationexample1.md | 4 +- .../visualization/visualizationexample2.md | 24 +++---- .../visualization/visualizationexample3.md | 6 +- .../visualization/visualizationexample4.md | 8 +-- .../visualization/visualizationexample5.md | 12 ++-- .../visualization/visualizationexample6.md | 4 +- .../visualization/visualizationexample7.md | 16 ++--- .../visualization/visualizationexample8.md | 50 +++++++------- .../visualization/visualizationexample9.md | 24 +++---- mevislab.github.io/hugo.toml | 1 - mevislab.github.io/layouts/index.html | 4 +- .../MeVisLab/layouts/partials/header.html | 6 +- .../layouts/shortcodes/mousebutton.html | 6 +- .../layouts/shortcodes/networkfile.html | 6 +- .../MeVisLab/layouts/shortcodes/youtube.html | 2 +- 133 files changed, 846 insertions(+), 849 deletions(-) diff --git a/README.md b/README.md index 15876295c..5c00cbf6c 100644 --- a/README.md +++ b/README.md @@ -1,16 +1,14 @@ -# MeVisLab Examples - -This is the repository for the MeVisLab Examples GitHub pages. - -Please follow [Examples Pages](https://mevislab.github.io/examples/) +# MeVisLab Tutorials and Examples +This is the repository for the [MeVisLab Tutorials and Examples GitHub pages](https://mevislab.github.io/examples/). ## Configuration ### Local Deployment -* Checkout code +* Checkout the code * Install _extended_ hugo from the [Hugo Website](https://gohugo.io/) * Install npm e.g. from [npmjs Website](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) -* Change to mevislab.github.io folder and run `npm install` -* Stay in this folder and run `hugo server -d public --baseURL //localhost/examples/` (The `/examples/` path is locally not absolute necessary but it helps to find problems that might appear on the production website.) -* Open in your favorite browser the given URL +* Change to the *mevislab.github.io* folder and run `npm install` +* Stay in this folder and run `hugo server -d public --baseURL //localhost/examples/` (the `/examples/` path is not needed, + but it helps to find problems that might appear on the published website) +* Open the given URL in your favorite browser diff --git a/mevislab.github.io/content/about/about.md b/mevislab.github.io/content/about/about.md index e6626aa4a..1ed31f16d 100644 --- a/mevislab.github.io/content/about/about.md +++ b/mevislab.github.io/content/about/about.md @@ -21,6 +21,6 @@ Hints common mistakes or steps you should consider beforehand. Keyboard shortcuts are incorporated like this: {{< keyboard "CTRL" "ALT" "2" >}}. ## Networks -The networks shown and used in the tutorials can be found in the [Examples](/examples) section of this page. +The networks shown and used in the tutorials can be found in the [Examples](examples) section of this page. They are usually embedded like this: {{< networkfile "examples/data_objects/contours/example1/ContourExample1.mlab" >}} diff --git a/mevislab.github.io/content/examples/basic_mechanisms/contour_filter/index.md b/mevislab.github.io/content/examples/basic_mechanisms/contour_filter/index.md index 75792f98e..d6cea488e 100644 --- a/mevislab.github.io/content/examples/basic_mechanisms/contour_filter/index.md +++ b/mevislab.github.io/content/examples/basic_mechanisms/contour_filter/index.md @@ -13,7 +13,7 @@ Additionally, the images are modified by a local macro module `Filter` and shown In order to display the same slice (unchanged and changed), the module `SyncFloat` is used to synchronize the field value *startSlice* in both viewers. The `SyncFloat` module duplicates the value *Float1* to the field *Float2*. -![Screenshot](/examples/basic_mechanisms/contour_filter/image.png) +![Screenshot](examples/basic_mechanisms/contour_filter/image.png) # Download -You can download the example network [here](/examples/basic_mechanisms/contour_filter/ContourFilter.zip) +You can download the example network [here](examples/basic_mechanisms/contour_filter/ContourFilter.zip) diff --git a/mevislab.github.io/content/examples/basic_mechanisms/macro_modules_and_module_interaction/example1/index.md b/mevislab.github.io/content/examples/basic_mechanisms/macro_modules_and_module_interaction/example1/index.md index 43ed34991..b94f94556 100644 --- a/mevislab.github.io/content/examples/basic_mechanisms/macro_modules_and_module_interaction/example1/index.md +++ b/mevislab.github.io/content/examples/basic_mechanisms/macro_modules_and_module_interaction/example1/index.md @@ -16,7 +16,7 @@ In this example we update the *.script* file of the `Filter` module to display t Changes applied to fields in the macro module's panel are applied to their internal network as well. {{}} -![Screenshot](/examples/basic_mechanisms/macro_modules_and_module_interaction/example1/image.png) +![Screenshot](examples/basic_mechanisms/macro_modules_and_module_interaction/example1/image.png) # Download -You can download the example network [here](/examples/basic_mechanisms/macro_modules_and_module_interaction/example1/FilterExample.zip) +You can download the example network [here](examples/basic_mechanisms/macro_modules_and_module_interaction/example1/FilterExample.zip) diff --git a/mevislab.github.io/content/examples/basic_mechanisms/macro_modules_and_module_interaction/example2/index.md b/mevislab.github.io/content/examples/basic_mechanisms/macro_modules_and_module_interaction/example2/index.md index d61178cc9..6c143a0cf 100644 --- a/mevislab.github.io/content/examples/basic_mechanisms/macro_modules_and_module_interaction/example2/index.md +++ b/mevislab.github.io/content/examples/basic_mechanisms/macro_modules_and_module_interaction/example2/index.md @@ -12,9 +12,9 @@ A new macro module `IsoCSOs` is created providing two viewers in its internal ne To showcase how Python functions can be implemented in MeVisLab and called from within a module, additional buttons to browse directories and create contours via the `CSOIsoGenerator` are added. Lastly, a field listener is implemented reacting to field changes by colorizing contours when the user hovers over them with the mouse. -![Screenshot](/examples/basic_mechanisms/macro_modules_and_module_interaction/example2/image2.png) +![Screenshot](examples/basic_mechanisms/macro_modules_and_module_interaction/example2/image2.png) -![Screenshot](/examples/basic_mechanisms/macro_modules_and_module_interaction/example2/image.png) +![Screenshot](examples/basic_mechanisms/macro_modules_and_module_interaction/example2/image.png) # Download -The files need to be added to a package. You can download the example network [here](/examples/basic_mechanisms/macro_modules_and_module_interaction/example2/ScriptingExample2.zip) +The files need to be added to a package. You can download the example network [here](examples/basic_mechanisms/macro_modules_and_module_interaction/example2/ScriptingExample2.zip) diff --git a/mevislab.github.io/content/examples/basic_mechanisms/viewer_application/index.md b/mevislab.github.io/content/examples/basic_mechanisms/viewer_application/index.md index d102d7123..fab2f837d 100644 --- a/mevislab.github.io/content/examples/basic_mechanisms/viewer_application/index.md +++ b/mevislab.github.io/content/examples/basic_mechanisms/viewer_application/index.md @@ -7,7 +7,7 @@ category: "basic_mechanisms" # Example 3: Creating a Simple Application In this example, you will learn how to create a simple prototype application in MeVisLab including a user interface (UI) with 2D and 3D viewers. -![Screenshot](/examples/basic_mechanisms/viewer_application/image.png) +![Screenshot](examples/basic_mechanisms/viewer_application/image.png) # Download -You can download the example network [here](/examples/basic_mechanisms/viewer_application/viewerexample.mlab) +You can download the example network [here](examples/basic_mechanisms/viewer_application/viewerexample.mlab) diff --git a/mevislab.github.io/content/examples/data_objects/contours/example1/index.md b/mevislab.github.io/content/examples/data_objects/contours/example1/index.md index dc61f3461..b10a3d2e1 100644 --- a/mevislab.github.io/content/examples/data_objects/contours/example1/index.md +++ b/mevislab.github.io/content/examples/data_objects/contours/example1/index.md @@ -9,7 +9,7 @@ Contours are stored as Contour Segmentation Objects (CSOs) in MeVisLab. This example highlights ways of creating CSOs using modules of the `SoCSOEditor` group. {{}} -You may want to look at the glossary entry on [*CSOs*](/glossary/#contour-segmented-objects). +You may want to look at the glossary entry on [*CSOs*](glossary/#contour-segmented-objects). {{}} The `SoCSOEditor` module group contains several modules, some of which are listed right below: @@ -32,7 +32,7 @@ Whenever Contour Segmentation Objects are created, they are temporarily stored b In this example, contours are created and colors and styles of these CSOs are customized by using the `SoCSOVisualizationSettings` module. -![Screenshot](/examples/data_objects/contours/example1/image.png) +![Screenshot](examples/data_objects/contours/example1/image.png) ## Summary + Contours are stored as their own abstract data type called Contour Segmentation Objects (often abbreviated to *CSO*). @@ -40,4 +40,4 @@ In this example, contours are created and colors and styles of these CSOs are cu + Created CSOs are temporarily stored and can be managed using the `CSOManager`. # Download -The example network can be downloaded [here](/examples/data_objects/contours/example1/ContourExample1.mlab) +The example network can be downloaded [here](examples/data_objects/contours/example1/ContourExample1.mlab) diff --git a/mevislab.github.io/content/examples/data_objects/contours/example2/index.md b/mevislab.github.io/content/examples/data_objects/contours/example2/index.md index 35138b56c..4203a33ac 100644 --- a/mevislab.github.io/content/examples/data_objects/contours/example2/index.md +++ b/mevislab.github.io/content/examples/data_objects/contours/example2/index.md @@ -12,7 +12,7 @@ In this example, semi-automatic countours are created using the `SoCSOLiveWireEd Additional contours between the manually created ones are generated by the `CSOSliceInterpolator` and added to the `CSOManager`. Different groups of contours are created for the left and right lobe of the lung and colored respectively. -![Screenshot](/examples/data_objects/contours/example2/image.png) +![Screenshot](examples/data_objects/contours/example2/image.png) # Download -You can download the example network [here](/examples/data_objects/contours/example2/ContourExample2.mlab) +You can download the example network [here](examples/data_objects/contours/example2/ContourExample2.mlab) diff --git a/mevislab.github.io/content/examples/data_objects/contours/example3/index.md b/mevislab.github.io/content/examples/data_objects/contours/example3/index.md index 7cbf2282a..29f253617 100644 --- a/mevislab.github.io/content/examples/data_objects/contours/example3/index.md +++ b/mevislab.github.io/content/examples/data_objects/contours/example3/index.md @@ -14,7 +14,7 @@ The module `VoxelizeCSO` is used to create a three-dimensional voxel mask of the Lastly, the panel of the `View3D` module is used to visualize the voxel mask in 3D. -![Screenshot](/examples/data_objects/contours/example3/image.png) +![Screenshot](examples/data_objects/contours/example3/image.png) # Download -You can download the example network [here](/examples/data_objects/contours/example3/ContourExample3.mlab) +You can download the example network [here](examples/data_objects/contours/example3/ContourExample3.mlab) diff --git a/mevislab.github.io/content/examples/data_objects/contours/example4/index.md b/mevislab.github.io/content/examples/data_objects/contours/example4/index.md index e9e5fd737..6ff2da024 100644 --- a/mevislab.github.io/content/examples/data_objects/contours/example4/index.md +++ b/mevislab.github.io/content/examples/data_objects/contours/example4/index.md @@ -10,7 +10,7 @@ This example shows how to add annotations to an image. ## Summary In this example, the network of **Contour Example 3** is extended so that the volume of the 3D mask generated by the `VoxelizeCSO` module is calculated. The `CalculateVolume` module counts the number of voxels in the given mask and returns the correct volume in ml. The calculated volume will be used for a custom `SoView2DAnnotation` displayed in the `View2D`. -![Screenshot](/examples/data_objects/contours/example4/image.png) +![Screenshot](examples/data_objects/contours/example4/image.png) # Download -You can download the example network [here](/examples/data_objects/contours/example4/ContourExample4.mlab) +You can download the example network [here](examples/data_objects/contours/example4/ContourExample4.mlab) diff --git a/mevislab.github.io/content/examples/data_objects/contours/example5/index.md b/mevislab.github.io/content/examples/data_objects/contours/example5/index.md index 564e771b1..dae91cd32 100644 --- a/mevislab.github.io/content/examples/data_objects/contours/example5/index.md +++ b/mevislab.github.io/content/examples/data_objects/contours/example5/index.md @@ -14,7 +14,7 @@ Ghosting means not only showing contours available on the currently visible slic The contours are also displayed in a three-dimensionsl `SoExaminerViewer` by using the `SoCSO3DRenderer`. -![Screenshot](/examples/data_objects/contours/example5/image.png) +![Screenshot](examples/data_objects/contours/example5/image.png) # Download -You can download the example network [here](/examples/data_objects/contours/example5/ContourExample5.mlab) +You can download the example network [here](examples/data_objects/contours/example5/ContourExample5.mlab) diff --git a/mevislab.github.io/content/examples/data_objects/curves/example1/index.md b/mevislab.github.io/content/examples/data_objects/curves/example1/index.md index 8230f5278..7e89a52a6 100644 --- a/mevislab.github.io/content/examples/data_objects/curves/example1/index.md +++ b/mevislab.github.io/content/examples/data_objects/curves/example1/index.md @@ -6,7 +6,7 @@ category: "data_objects" # Curves Example: Drawing Curves This examples shows how to create and render curves. -![Screenshot](/examples/data_objects/curves/example1/image.png) +![Screenshot](examples/data_objects/curves/example1/image.png) # Download -You can download the example network [here](/examples/data_objects/curves/example1/Curves.mlab) +You can download the example network [here](examples/data_objects/curves/example1/Curves.mlab) diff --git a/mevislab.github.io/content/examples/data_objects/markers/example1/index.md b/mevislab.github.io/content/examples/data_objects/markers/example1/index.md index 70128d12f..1641fe1cc 100644 --- a/mevislab.github.io/content/examples/data_objects/markers/example1/index.md +++ b/mevislab.github.io/content/examples/data_objects/markers/example1/index.md @@ -6,7 +6,7 @@ category: "data_objects" # Marker Example 1: Distance Between Markers This examples shows how to create markers in a viewer and measure their distance. -![Screenshot](/examples/data_objects/markers/example1/image.png) +![Screenshot](examples/data_objects/markers/example1/image.png) # Download -You can download the example network [here](/examples/data_objects/markers/example1/Marker_Example1.mlab) +You can download the example network [here](examples/data_objects/markers/example1/Marker_Example1.mlab) diff --git a/mevislab.github.io/content/examples/data_objects/surface_objects/example1/index.md b/mevislab.github.io/content/examples/data_objects/surface_objects/example1/index.md index 1b9a6bf4c..1bc93beba 100644 --- a/mevislab.github.io/content/examples/data_objects/surface_objects/example1/index.md +++ b/mevislab.github.io/content/examples/data_objects/surface_objects/example1/index.md @@ -6,7 +6,7 @@ category: "data_objects" # Surface Example 1: Creation of WEMs This example shows how to create WEMs out of voxel images and CSOs. -![Screenshot](/examples/data_objects/surface_objects/example1/image.png) +![Screenshot](examples/data_objects/surface_objects/example1/image.png) # Download -You can download the example network [here](/examples/data_objects/surface_objects/example1/SurfaceExample1.mlab) +You can download the example network [here](examples/data_objects/surface_objects/example1/SurfaceExample1.mlab) diff --git a/mevislab.github.io/content/examples/data_objects/surface_objects/example2/index.md b/mevislab.github.io/content/examples/data_objects/surface_objects/example2/index.md index 7ca35ab38..f01acebf2 100644 --- a/mevislab.github.io/content/examples/data_objects/surface_objects/example2/index.md +++ b/mevislab.github.io/content/examples/data_objects/surface_objects/example2/index.md @@ -6,7 +6,7 @@ category: "data_objects" # Surface Example 2: Processing and Modification of WEMs This example shows how to process and modify WEMs using the modules `WEMModify`, `WEMSmooth`, and `WEMSurfaceDistance`. -![Screenshot](/examples/data_objects/surface_objects/example2/DO7_03.png) +![Screenshot](examples/data_objects/surface_objects/example2/DO7_03.png) # Download -You can download the example network [here](/examples/data_objects/surface_objects/example2/SurfaceExample2.mlab) +You can download the example network [here](examples/data_objects/surface_objects/example2/SurfaceExample2.mlab) diff --git a/mevislab.github.io/content/examples/data_objects/surface_objects/example3/index.md b/mevislab.github.io/content/examples/data_objects/surface_objects/example3/index.md index 4e4b29677..f75fc5513 100644 --- a/mevislab.github.io/content/examples/data_objects/surface_objects/example3/index.md +++ b/mevislab.github.io/content/examples/data_objects/surface_objects/example3/index.md @@ -7,14 +7,14 @@ category: "data_objects" # Surface Example 3: Interactions with WEM ## Scale, Rotate, and Move a WEM in a Scene In this example, we are using a `SoTransformerDragger` module to apply transformations on a 3D WEM object via mouse interactions. -![Screenshot](/examples/data_objects/surface_objects/example3/image.png) +![Screenshot](examples/data_objects/surface_objects/example3/image.png) ### Download -You can download the example network [here](/examples/data_objects/surface_objects/example3/SurfaceExample3.mlab) +You can download the example network [here](examples/data_objects/surface_objects/example3/SurfaceExample3.mlab) ## Interactively Modify WEMs In this example, we are using a `SoWEMBulgeEditor` module to modify a WEM using the mouse. -![Screenshot](/examples/data_objects/surface_objects/example3/image2.png) +![Screenshot](examples/data_objects/surface_objects/example3/image2.png) ### Download -You can download the example network [here](/examples/data_objects/surface_objects/example3/WEMExample3b.mlab) \ No newline at end of file +You can download the example network [here](examples/data_objects/surface_objects/example3/WEMExample3b.mlab) \ No newline at end of file diff --git a/mevislab.github.io/content/examples/data_objects/surface_objects/example4/index.md b/mevislab.github.io/content/examples/data_objects/surface_objects/example4/index.md index 7423dcc55..72b67c83c 100644 --- a/mevislab.github.io/content/examples/data_objects/surface_objects/example4/index.md +++ b/mevislab.github.io/content/examples/data_objects/surface_objects/example4/index.md @@ -6,7 +6,7 @@ category: "data_objects" # Surface Example 4: Interactively Moving WEM This example shows how to use dragger modules to modify objects in a 3D viewer. -![Screenshot](/examples/data_objects/surface_objects/example4/image.png) +![Screenshot](examples/data_objects/surface_objects/example4/image.png) # Download -You can download the example network [here](/examples/data_objects/surface_objects/example4/SurfaceExample4.zip) +You can download the example network [here](examples/data_objects/surface_objects/example4/SurfaceExample4.zip) diff --git a/mevislab.github.io/content/examples/data_objects/surface_objects/example5/index.md b/mevislab.github.io/content/examples/data_objects/surface_objects/example5/index.md index 95cbb7c09..6484669c5 100644 --- a/mevislab.github.io/content/examples/data_objects/surface_objects/example5/index.md +++ b/mevislab.github.io/content/examples/data_objects/surface_objects/example5/index.md @@ -6,7 +6,7 @@ category: "data_objects" # Surface Example 5: WEM - Primitive Value Lists This example shows how to use Primitive Value Lists (PVLs). With the help of PVLs, the distance between the surfaces of WEMs is color-coded. -![Screenshot](/examples/data_objects/surface_objects/example5/image.png) +![Screenshot](examples/data_objects/surface_objects/example5/image.png) # Download -You can download the example network [here](/examples/data_objects/surface_objects/example5/SurfaceExample5.mlab) +You can download the example network [here](examples/data_objects/surface_objects/example5/SurfaceExample5.mlab) diff --git a/mevislab.github.io/content/examples/howto.md b/mevislab.github.io/content/examples/howto.md index ac46244f0..c4eddf11e 100644 --- a/mevislab.github.io/content/examples/howto.md +++ b/mevislab.github.io/content/examples/howto.md @@ -30,18 +30,18 @@ Archives mostly contain macro modules.
To use those macro modules, you will need to know how to handle user packages. {{}} -See [Example 2.1: Package creation](/tutorials/basicmechanisms/macromodules/package/) for more information on packages in MeVisLab. +See [Example 2.1: Package creation](tutorials/basicmechanisms/macromodules/package/) for more information on packages in MeVisLab. {{}} The contents can be extracted into the directory of your package. Make sure to keep the directory's structure for the examples to be loaded and displayed correctly. The typical directory structure of a MeVisLab package looks like this: -![Package directory structure](/images/examples/howto_1.png "Package directory structure") +![Package directory structure](images/examples/howto_1.png "Package directory structure") The package *TutorialSummary* within the package group *MeVis* is shown above. A package typically contains at least a *Projects* directory, which is where the macro modules are located. When extracting the contents of a *.zip* file, the *Projects* folder of your package should be the target directory. Sometimes we even provide test cases. Extract them into the *TestCases* directory. -![Package directory structure](/images/examples/howto_2.png "Package directory structure") +![Package directory structure](images/examples/howto_2.png "Package directory structure") {{}} Feel free to create certain directories if they do not exist yet, but make sure to name them conforming the directory structure shown above. diff --git a/mevislab.github.io/content/examples/image_processing/example1/index.md b/mevislab.github.io/content/examples/image_processing/example1/index.md index 2b1420588..947758a7c 100644 --- a/mevislab.github.io/content/examples/image_processing/example1/index.md +++ b/mevislab.github.io/content/examples/image_processing/example1/index.md @@ -10,7 +10,7 @@ In this example, we apply scalar functions on two images like Add, Multiply, Sub ## Summary We are loading two images by using the `LocalImage` module and show them in a `SynchroView2D`. In addition to that, both images are used for arithmetic processing in the module `Arithmetic2`. -![Screenshot](/examples/image_processing/example1/image.png) +![Screenshot](examples/image_processing/example1/image.png) # Download -You can download the example network [here](/examples/image_processing/example1/BasicFilter.mlab) +You can download the example network [here](examples/image_processing/example1/BasicFilter.mlab) diff --git a/mevislab.github.io/content/examples/image_processing/example2/index.md b/mevislab.github.io/content/examples/image_processing/example2/index.md index f6a59398c..1f5ac6916 100644 --- a/mevislab.github.io/content/examples/image_processing/example2/index.md +++ b/mevislab.github.io/content/examples/image_processing/example2/index.md @@ -10,7 +10,7 @@ In this example, we create a simple mask on an image, so that background voxels ## Summary We are loading images by using the `LocalImage` module and show them in a `SynchroView2D`. The same image is shown in the right viewer of the `SynchroView2D` but with a `Threshold` based `Mask`. -![Screenshot](/examples/image_processing/example2/image.png) +![Screenshot](examples/image_processing/example2/image.png) # Download -You can download the example network [here](/examples/image_processing/example2/ImageMask.mlab) +You can download the example network [here](examples/image_processing/example2/ImageMask.mlab) diff --git a/mevislab.github.io/content/examples/image_processing/example3/index.md b/mevislab.github.io/content/examples/image_processing/example3/index.md index 6f18ba31f..27a928e10 100644 --- a/mevislab.github.io/content/examples/image_processing/example3/index.md +++ b/mevislab.github.io/content/examples/image_processing/example3/index.md @@ -10,7 +10,7 @@ In this example, we create a simple mask on an image by using the `RegionGrowing ## Summary We are loading images by using the `LocalImage` module and show them in a `SynchroView2D`. The same image is used as input for the `RegionGrowing` module. The starting point for the algorithm is a list of markers created by the `SoView2DMarkerEditor`. As the `RegionGrowing` may leave gaps, an additional `CloseGap` module is added. The resulting segmentation mask is shown as an overlay on the original image via `SoView2DOverlay`. -![Screenshot](/examples/image_processing/example3/image.png) +![Screenshot](examples/image_processing/example3/image.png) # Download -You can download the example network [here](/examples/image_processing/example3/RegionGrowingExample.mlab) +You can download the example network [here](examples/image_processing/example3/RegionGrowingExample.mlab) diff --git a/mevislab.github.io/content/examples/image_processing/example4/index.md b/mevislab.github.io/content/examples/image_processing/example4/index.md index 16c7f8a2f..89aa6a307 100644 --- a/mevislab.github.io/content/examples/image_processing/example4/index.md +++ b/mevislab.github.io/content/examples/image_processing/example4/index.md @@ -10,7 +10,7 @@ In this example, we subtract a sphere from another WEM. ## Summary We are loading images by using the `LocalImage` module and render them as a 3D scene in a `SoExaminerViewer`. We also add a sphere that is then subtracted from the original image. -![Screenshot](/examples/image_processing/example4/image.png) +![Screenshot](examples/image_processing/example4/image.png) # Download -You can download the example network [here](/examples/image_processing/example4/Subtract3DObjects.mlab) +You can download the example network [here](examples/image_processing/example4/Subtract3DObjects.mlab) diff --git a/mevislab.github.io/content/examples/image_processing/example5/index.md b/mevislab.github.io/content/examples/image_processing/example5/index.md index ae4d5dedd..23db05a1e 100644 --- a/mevislab.github.io/content/examples/image_processing/example5/index.md +++ b/mevislab.github.io/content/examples/image_processing/example5/index.md @@ -10,7 +10,7 @@ In this example, we are using the currently visible slice from a 2D view as a cl ## Summary We are loading images by using the `LocalImage` module and render them as a two-dimensional image stack `SoRenderArea`. The displayed slice is used to create a 3D plane/clip plane in a `SoExaminerViewer`. -![Screenshot](/examples/image_processing/example5/image.png) +![Screenshot](examples/image_processing/example5/image.png) # Download -You can download the example network [here](/examples/image_processing/example4/ImageProcessingExample5.mlab) +You can download the example network [here](examples/image_processing/example4/ImageProcessingExample5.mlab) diff --git a/mevislab.github.io/content/examples/open_inventor/example1/index.md b/mevislab.github.io/content/examples/open_inventor/example1/index.md index 7205561ba..649fd41fd 100644 --- a/mevislab.github.io/content/examples/open_inventor/example1/index.md +++ b/mevislab.github.io/content/examples/open_inventor/example1/index.md @@ -14,7 +14,7 @@ Three 3D objects are created (`SoCone`, `SoSphere`, and `SoCube`) having a defin In the end, all three objects including their materials and transformations are added to the `SoExaminerViewer` by a `SoGroup`. -![Screenshot](/examples/open_inventor/example1/image.png) +![Screenshot](examples/open_inventor/example1/image.png) # Download -You can download the example network [here](/examples/open_inventor/example1/OpenInventorExample1.mlab) +You can download the example network [here](examples/open_inventor/example1/OpenInventorExample1.mlab) diff --git a/mevislab.github.io/content/examples/open_inventor/example2/index.md b/mevislab.github.io/content/examples/open_inventor/example2/index.md index e8ec855bc..136957af3 100644 --- a/mevislab.github.io/content/examples/open_inventor/example2/index.md +++ b/mevislab.github.io/content/examples/open_inventor/example2/index.md @@ -10,9 +10,9 @@ This example shows how to implement object interactions. ## Summary A `SoExaminerViewer` is used to render a `SoCube` object. The `SoMouseGrabber` is used to identify mouse interactions in the viewer and to resize the cube. -![Screenshot](/examples/open_inventor/example2/image.png) +![Screenshot](examples/open_inventor/example2/image.png) # Download -You can download the example network [here](/examples/open_inventor/example2/OpenInventorExample2.mlab) +You can download the example network [here](examples/open_inventor/example2/OpenInventorExample2.mlab) diff --git a/mevislab.github.io/content/examples/open_inventor/example3/index.md b/mevislab.github.io/content/examples/open_inventor/example3/index.md index 8c3caedec..5b7fab0f4 100644 --- a/mevislab.github.io/content/examples/open_inventor/example3/index.md +++ b/mevislab.github.io/content/examples/open_inventor/example3/index.md @@ -10,9 +10,9 @@ This example shows different options for using a camera and different viewers in ## Summary We will show the difference between a `SoRenderArea` and a `SoExaminerViewer` and use different modules of the `SoCamera*` group. -![Screenshot](/examples/open_inventor/example3/image.png) +![Screenshot](examples/open_inventor/example3/image.png) # Download -You can download the example network [here](/examples/open_inventor/example3/CameraInteractions.mlab) +You can download the example network [here](examples/open_inventor/example3/CameraInteractions.mlab) diff --git a/mevislab.github.io/content/examples/open_inventor/example4/index.md b/mevislab.github.io/content/examples/open_inventor/example4/index.md index 880f332f8..f8fdf2ace 100644 --- a/mevislab.github.io/content/examples/open_inventor/example4/index.md +++ b/mevislab.github.io/content/examples/open_inventor/example4/index.md @@ -12,9 +12,9 @@ This example has been taken from the [MeVisLab forum](https://forum.mevislab.de/ ## Summary A local macro `flightControl` allows you to navigate with the camera through the scene. -![Screenshot](/examples/open_inventor/example4/image.png) +![Screenshot](examples/open_inventor/example4/image.png) # Download -You can download the example network [here](/examples/open_inventor/example4/flight2.zip) +You can download the example network [here](examples/open_inventor/example4/flight2.zip) diff --git a/mevislab.github.io/content/examples/testing/Example1/index.md b/mevislab.github.io/content/examples/testing/Example1/index.md index 5de45d245..e20ef1e47 100644 --- a/mevislab.github.io/content/examples/testing/Example1/index.md +++ b/mevislab.github.io/content/examples/testing/Example1/index.md @@ -8,4 +8,4 @@ category: "testing" This example shows how to write and execute test cases in MeVisLab. The Python files can be downloaded below. # Download -You can download the Python files [here](/examples/testing/example1/TestCases.zip) +You can download the Python files [here](examples/testing/example1/TestCases.zip) diff --git a/mevislab.github.io/content/examples/thirdparty/example1/index.md b/mevislab.github.io/content/examples/thirdparty/example1/index.md index a2c841d03..4f71ceeea 100644 --- a/mevislab.github.io/content/examples/thirdparty/example1/index.md +++ b/mevislab.github.io/content/examples/thirdparty/example1/index.md @@ -8,4 +8,4 @@ category: "thirdparty" This Python file shows how to access the webcam via OpenCV and use the video via `PythonImage` module in MeVisLab. # Download -You can download the Python files [here](/examples/thirdparty/example1/OpenCVExample.zip) +You can download the Python files [here](examples/thirdparty/example1/OpenCVExample.zip) diff --git a/mevislab.github.io/content/examples/thirdparty/example2/index.md b/mevislab.github.io/content/examples/thirdparty/example2/index.md index 07e7d366f..9f384b50c 100644 --- a/mevislab.github.io/content/examples/thirdparty/example2/index.md +++ b/mevislab.github.io/content/examples/thirdparty/example2/index.md @@ -8,4 +8,4 @@ category: "thirdparty" This Python file shows how to access the webcam and detect faces in the video stream via OpenCV. # Download -You can download the Python files [here](/examples/thirdparty/example2/FaceDetection.py) +You can download the Python files [here](examples/thirdparty/example2/FaceDetection.py) diff --git a/mevislab.github.io/content/examples/thirdparty/pytorch1/index.md b/mevislab.github.io/content/examples/thirdparty/pytorch1/index.md index 48d31b288..f899924df 100644 --- a/mevislab.github.io/content/examples/thirdparty/pytorch1/index.md +++ b/mevislab.github.io/content/examples/thirdparty/pytorch1/index.md @@ -7,7 +7,7 @@ category: "thirdparty" # ThirdParty Example 5: Segmentation in Webcam Stream by using PyTorch This macro module segments a person shown in a webcam stream by using a pre-trained network from PyTorch (torchvision). -![Screenshot](/images/tutorials/thirdparty/pytorch_example3_10.png) +![Screenshot](images/tutorials/thirdparty/pytorch_example3_10.png) # Download -You can download the Python files [here](/examples/thirdparty/pytorch1/PyTorchSegmentationExample.zip) +You can download the Python files [here](examples/thirdparty/pytorch1/PyTorchSegmentationExample.zip) diff --git a/mevislab.github.io/content/examples/visualization/example1/index.md b/mevislab.github.io/content/examples/visualization/example1/index.md index faf4ac4d7..43fd8ebbd 100644 --- a/mevislab.github.io/content/examples/visualization/example1/index.md +++ b/mevislab.github.io/content/examples/visualization/example1/index.md @@ -7,7 +7,7 @@ category: "visualization" # Visualization Example 1: Synchronous View of Two Images This very simple example shows how to load an image and apply a basic `Convolution` filter to the image. The image with and without filter is shown in a Viewer and scrolling is synchronized so that the same slice is shown for both images. -![Screenshot](/examples/visualization/example1/image.png) +![Screenshot](examples/visualization/example1/image.png) # Download -You can download the example network [here](/examples/visualization/example1/VisualizationExample1.mlab) +You can download the example network [here](examples/visualization/example1/VisualizationExample1.mlab) diff --git a/mevislab.github.io/content/examples/visualization/example2/index.md b/mevislab.github.io/content/examples/visualization/example2/index.md index 9dc8b0e17..af8bbd5bc 100644 --- a/mevislab.github.io/content/examples/visualization/example2/index.md +++ b/mevislab.github.io/content/examples/visualization/example2/index.md @@ -6,7 +6,7 @@ category: "visualization" # Visualization Example 2: Creating a Magnifier This example shows how to create a magnifier. Using the module `SubImage`, a fraction of the original image can be extracted and enlarged. -![Screenshot](/examples/visualization/example2/image.png) +![Screenshot](examples/visualization/example2/image.png) # Download -You can download the example network [here](/examples/visualization/example2/VisualizationExample2.mlab) +You can download the example network [here](examples/visualization/example2/VisualizationExample2.mlab) diff --git a/mevislab.github.io/content/examples/visualization/example3/index.md b/mevislab.github.io/content/examples/visualization/example3/index.md index 8dc962e8f..a51f1a5da 100644 --- a/mevislab.github.io/content/examples/visualization/example3/index.md +++ b/mevislab.github.io/content/examples/visualization/example3/index.md @@ -6,7 +6,7 @@ category: "visualization" # Visualization Example 3: Image Overlays This example shows the creation of an overlay. Using the module `SoView2DOverlay`, an overlay can be blended over a 2D image. -![Screenshot](/examples/visualization/example3/image.png) +![Screenshot](examples/visualization/example3/image.png) # Download -You can download the example network [here](/examples/visualization/example3/VisualizationExample3.mlab) +You can download the example network [here](examples/visualization/example3/VisualizationExample3.mlab) diff --git a/mevislab.github.io/content/examples/visualization/example4/index.md b/mevislab.github.io/content/examples/visualization/example4/index.md index 4f10381c2..6ba607646 100644 --- a/mevislab.github.io/content/examples/visualization/example4/index.md +++ b/mevislab.github.io/content/examples/visualization/example4/index.md @@ -6,7 +6,7 @@ category: "visualization" # Visualization Example 4: Display Images Converted to Open Inventor Scene Objects This example shows how to convert images to Open Inventor scene objects using the module `SoView2D` and modules based on `SoView2D`. -![Screenshot](/examples/visualization/example4/image.png) +![Screenshot](examples/visualization/example4/image.png) # Download -You can download the example network [here](/examples/visualization/example4/VisualizationExample4.mlab) +You can download the example network [here](examples/visualization/example4/VisualizationExample4.mlab) diff --git a/mevislab.github.io/content/examples/visualization/example5/index.md b/mevislab.github.io/content/examples/visualization/example5/index.md index 8c7c53f5b..68e85669b 100644 --- a/mevislab.github.io/content/examples/visualization/example5/index.md +++ b/mevislab.github.io/content/examples/visualization/example5/index.md @@ -6,7 +6,7 @@ category: "visualization" # Visualization Example 5: Volume Rendering and Interactions This example shows the volume rendering of a scan. The texture of the volume is edited and animations are implemented. -![Screenshot](/examples/visualization/example5/image.png) +![Screenshot](examples/visualization/example5/image.png) # Download -You can download the example network [here](/examples/visualization/example5/VisualizationExample5.mlab) +You can download the example network [here](examples/visualization/example5/VisualizationExample5.mlab) diff --git a/mevislab.github.io/content/examples/visualization/example6/index.md b/mevislab.github.io/content/examples/visualization/example6/index.md index 2094567c2..2031b2b8a 100644 --- a/mevislab.github.io/content/examples/visualization/example6/index.md +++ b/mevislab.github.io/content/examples/visualization/example6/index.md @@ -6,7 +6,7 @@ category: "visualization" # Visualization Example 6.1: Volume Rendering vs. Path Tracing This example shows a comparison between Volume Rendering and Path Tracing. The same scene is rendered and the camera interactions in both viewers are synchronized. -![Screenshot](/examples/visualization/example6/image.png) +![Screenshot](examples/visualization/example6/image.png) # Download -You can download the example network [here](/examples/visualization/example6/pathtracer1.mlab) +You can download the example network [here](examples/visualization/example6/pathtracer1.mlab) diff --git a/mevislab.github.io/content/introduction/introduction.md b/mevislab.github.io/content/introduction/introduction.md index 6112f813d..cb5b725f7 100644 --- a/mevislab.github.io/content/introduction/introduction.md +++ b/mevislab.github.io/content/introduction/introduction.md @@ -15,7 +15,7 @@ menu: ## Tutorial Introduction {#tutorial_introduction} -Welcome to [MeVisLab](/glossary/#mevislab)! +Welcome to [MeVisLab](glossary/#mevislab)! More than 20 years of experience and the continuous implementation of adaptations made MeVisLab one of the most powerful development platforms for medical image processing. @@ -25,17 +25,17 @@ analysis, surgery planning, and cardiovascular analysis. MeVisLab is a development environment for rapid prototyping and product development of medical and industrial imaging applications. It includes -a [*Software Development Kit (SDK)*](/glossary/#mevislab-sdk) and an [*ApplicationBuilder*](/glossary/#mevislab-apk) for deploying your applications to end-customers. +a [*Software Development Kit (SDK)*](glossary/#mevislab-sdk) and an [*ApplicationBuilder*](glossary/#mevislab-apk) for deploying your applications to end-customers. -In turn, the *MeVisLab SDK* consists of an [*Integrated Development Environment (IDE)*](/glossary/#mevislab-ide) -for visual programming and the advanced text editor [*MATE*](/glossary/#mevislab-mate) for Python +In turn, the *MeVisLab SDK* consists of an [*Integrated Development Environment (IDE)*](glossary/#mevislab-ide) +for visual programming and the advanced text editor [*MATE*](glossary/#mevislab-mate) for Python scripting, providing code completion, debugging, profiling, and automated test development as well as execution. -You can re-use thousands of pre-defined [*Modules*](/glossary/#module) for image processing +You can re-use thousands of pre-defined [*Modules*](glossary/#module) for image processing (2D up to 6D images) and visualization, combine them, or even build your own. -A quick introduction on available modules and [example networks](/glossary/#example-network) will be given in the following tutorials. +A quick introduction on available modules and [example networks](glossary/#example-network) will be given in the following tutorials. ### Structure and Usage of Provided Tutorials @@ -45,10 +45,10 @@ features of MeVisLab. Starting with this introduction, we will be leading you through all relevant aspects of the user interface, commonly used functionalities, and provide you with all the basic knowledge you need to build your own web applications. -Additional information is accessible through embedded links, forwarding you to a related glossary entry or tutorial and shortcuts, advice and hints will be highlighted as shown [here](/about/about/). +Additional information is accessible through embedded links, forwarding you to a related glossary entry or tutorial and shortcuts, advice and hints will be highlighted as shown [here](about/about/). The tutorials are divided into chapters by their topic and each chapter contains at least one example for you to try. -You find them at the end of the tutorial or, also sorted by chapters, under the menu entry [Examples](/examples/howto). +You find them at the end of the tutorial or, also sorted by chapters, under the menu entry [Examples](examples/howto). The examples under the designated menu entry are more suitable if you already have a little experience and rather search for inspiration than for explanations. ### Starting MeVisLab for the First Time @@ -67,25 +67,25 @@ Maybe postpone the usage of the *QuickStart* icons as they can cause created pac First, start the MeVisLab IDE. After the Welcome Screen, the standard user interface opens. -![MeVisLab IDE User Interface](/images/tutorials/introduction/IDE1.png "MeVisLab IDE User Interface") +![MeVisLab IDE User Interface](images/tutorials/introduction/IDE1.png "MeVisLab IDE User Interface") #### Workspace -By default, MeVisLab starts with an empty [workspace](/glossary/#workspace). +By default, MeVisLab starts with an empty [workspace](glossary/#workspace). This is where you will be developing and editing networks. Essentially, networks form the base of all processing and visualization pipelines, so the workspace is where the visual programming is done. #### Views Area -The standard [Views Area](/glossary/#views-area) contains the [Output Inspector and Module Inspector](./tutorials/basicmechanisms#The_Output_Inspector_and_the_Module_Inspector "Output Inspector and Module Inspector"). With the help of the Output Inspector, you can visualize the modules output. +The standard [Views Area](glossary/#views-area) contains the [Output Inspector and Module Inspector](./tutorials/basicmechanisms#The_Output_Inspector_and_the_Module_Inspector "Output Inspector and Module Inspector"). With the help of the Output Inspector, you can visualize the modules output. {{}} -Further information on each module, e.g., about [module parameters](/glossary/#field), can be found using the [Module Inspector](/glossary/#module-inspector). +Further information on each module, e.g., about [module parameters](glossary/#field), can be found using the [Module Inspector](glossary/#module-inspector). {{}} #### Debug Output -Debugging information can be found using the [Debug Output](/glossary/#debug-output). +Debugging information can be found using the [Debug Output](glossary/#debug-output). The MeVisLab IDE and its layout are completely configurable. You can rearrange the items and add new views via {{< menuitem "Main Menu" "View" "Views" >}}. @@ -107,18 +107,18 @@ rearrange the items and add new views via {{< menuitem "Main Menu" "View" "Views ### Module Types {#Module_Types} {{}} -[Modules](/glossary/#module) are the basic entities the MeVisLab concept is built upon.
+[Modules](glossary/#module) are the basic entities the MeVisLab concept is built upon.
They provide the functionalities to process, display, and interact with images. {{
}} -The three existing module types (ML, [Open Inventor](/glossary/#open-inventor), and [macro module](/glossary/#macro-module)) can be distinguished by their colors: +The three existing module types (ML, [Open Inventor](glossary/#open-inventor), and [macro module](glossary/#macro-module)) can be distinguished by their colors: {{< bootstrap-table table_class="table table-striped" >}} |
Type
|
Appearance
| Characteristics | | --- | --- | --- | -| ML module (blue) | ![ML module](/images/tutorials/introduction/MLMModuleML.png "ML module") | Page-based, demand-driven processing of voxels. | -| Open Inventor module (green) | ![Open Inventor module](/images/tutorials/introduction/MLMModuleSo.png "Open Inventor module") | Visual scene graphs (3D). Usually starting with *So* (for **S**cene **o**bject) as a naming convention. | -| Macro module (brown) | ![Macro module](/images/tutorials/introduction/MLMModuleMacro.png "Macro module") | Combination of other module types, allowing the implementation of hierarchies and scripted interaction. | +| ML module (blue) | ![ML module](images/tutorials/introduction/MLMModuleML.png "ML module") | Page-based, demand-driven processing of voxels. | +| Open Inventor module (green) | ![Open Inventor module](images/tutorials/introduction/MLMModuleSo.png "Open Inventor module") | Visual scene graphs (3D). Usually starting with *So* (for **S**cene **o**bject) as a naming convention. | +| Macro module (brown) | ![Macro module](images/tutorials/introduction/MLMModuleMacro.png "Macro module") | Combination of other module types, allowing the implementation of hierarchies and scripted interaction. | {{< /bootstrap-table >}} ### Invalid Modules @@ -128,8 +128,8 @@ If a module is invalid, it is displayed in bright red. This might happen if the {{< bootstrap-table table_class="table table-striped" >}} |
Appearance
| Explanation | | --- | --- | -| ![Invalid module](/images/tutorials/introduction/MLMModuleStateInvalid.png "Invalid module") | Invalid module | - ![Macro State Invalid](/images/tutorials/introduction/MLMModuleStateMacroInvalidModule.png "Macro State Invalid") | Macro containing an invalid module | +| ![Invalid module](images/tutorials/introduction/MLMModuleStateInvalid.png "Invalid module") | Invalid module | + ![Macro State Invalid](images/tutorials/introduction/MLMModuleStateMacroInvalidModule.png "Macro State Invalid") | Macro containing an invalid module | {{< /bootstrap-table >}} As you can see, the number of warning and error messages that are being printed to the @@ -145,15 +145,15 @@ Informational messages are indicated in a similar matter on the same spot, but i ### Module Interactions Through the Context Menu Each module has a context menu, providing the following options: -![Context Menu of a module](/images/tutorials/introduction/ModuleContextMenu.png "Context Menu of a module") +![Context Menu of a module](images/tutorials/introduction/ModuleContextMenu.png "Context Menu of a module") -* **Show Internal Network:** [Macro modules](/glossary/#macro-module) provide an entry to open the internal network. You can see what happens inside a macro module. The internal network may also contain other macro modules. +* **Show Internal Network:** [Macro modules](glossary/#macro-module) provide an entry to open the internal network. You can see what happens inside a macro module. The internal network may also contain other macro modules. * **Show Window:** If a module does not provide a User Interface, you will see the automatic panel showing the module's name. Modules may additionally have one or more windows that can be opened. You can also open the Scripting Console of a module to integrate Python. * **Instance Name:** You can edit or copy the instance name. Renaming can be useful if the same module appears more than once in one network and/or if you want to access and distinguish the modules in your Python script. * **Help:** The menu entry Help provides access to the Module Help pages and to an example network where the module is used. This example network often helps to understand which additional modules can be added to create your desired effect. * **Extras:** Automated tests written for the specific module can be executed here. You can also run this module in a separate process. * **Reload Definition:** In the case you are currently working on a module, you may need to reload the definition so that your changes are applied on the module (for example, attached Python scripts). -* **Related Files:** Related files allows a quick access to the modules *.script* or *.py* files. The files are automatically opened in [MATE](/glossary/#mevislab-mate) for editing. +* **Related Files:** Related files allows a quick access to the modules *.script* or *.py* files. The files are automatically opened in [MATE](glossary/#mevislab-mate) for editing. * **Show Enclosing Folder:** This entry opens the directory where your module is stored. * **Grouping:** Multiple modules can be clustered and the groups can be named. This adds clarity to the structure of your network. In addition to that, grouped modules can be converted to local or global macro modules easily. @@ -165,9 +165,9 @@ Once again, three types can be distinguished: {{< bootstrap-table table_class="table table-striped" >}} |
Appearance
|
Shape
| Definition | | --- | --- | --- | -| ![Triangle](/images/tutorials/introduction/MLMConnectorTriangle.png "Triangle - ML Image") | triangle | ML images | -| ![Circle](/images/tutorials/introduction/MLMConnectorHalfCircle.png "Circle - Inventor Scene") | half-circle | Inventor scene | -| ![Square](/images/tutorials/introduction/MLMConnectorSquare.png "Square - Base Object") | square | Base objects: Pointers to data structures | +| ![Triangle](images/tutorials/introduction/MLMConnectorTriangle.png "Triangle - ML Image") | triangle | ML images | +| ![Circle](images/tutorials/introduction/MLMConnectorHalfCircle.png "Circle - Inventor Scene") | half-circle | Inventor scene | +| ![Square](images/tutorials/introduction/MLMConnectorSquare.png "Square - Base Object") | square | Base objects: Pointers to data structures | {{< /bootstrap-table >}} {{}} @@ -183,13 +183,13 @@ If you want to know more about establishing, removing, moving, and replacing con Besides through a module's input and output connectors, connections can also be established between parameters in the module's panel. {{}} -An exemplary use case for a parameter connection is synchronization. Have a look [here](/tutorials/basicmechanisms/#TutorialParameterConnection). +An exemplary use case for a parameter connection is synchronization. Have a look [here](tutorials/basicmechanisms/#TutorialParameterConnection). {{}} ### Macro Modules {#Macro_Modules} {{}} -The creation of macros is explained in more detail in [Tutorial Chapter I - Example 2.2](/tutorials/basicmechanisms/macromodules/globalmacromodules) +The creation of macros is explained in more detail in [Tutorial Chapter I - Example 2.2](tutorials/basicmechanisms/macromodules/globalmacromodules) {{}} ### Adding Modules to your Workspace {#Searching_and_Adding_Modules} @@ -206,7 +206,7 @@ Both the menu entry{{< menuitem "Modules" >}} and the Module Browser display all Therefore, both places are a good starting point when in need of a specific function, like an `ImageLoad` module. -![Modules Menu and Module Browser](/images/tutorials/introduction/GSExampleNetworkViewImage01c.png "Modules Menu and Module Browser") +![Modules Menu and Module Browser](images/tutorials/introduction/GSExampleNetworkViewImage01c.png "Modules Menu and Module Browser") The advantage of the Module Browser is that you can right-click {{< mousebutton "right" >}} the entries, open the context menu and, for example, open the help (in your @@ -214,13 +214,13 @@ default Internet browser) or the module files (in MATE, the built-in text editor). {{}} -For a module to be listed, it has to be available in the [SDK](/glossary/#mevislab-sdk) or in your self-defined -[packages](/glossary/#package). A detailed tutorial on how to create packages can be found [here](/tutorials/basicmechanisms/macromodules/package/). If in doubt or missing something, check out the loaded packages in the preferences. +For a module to be listed, it has to be available in the [SDK](glossary/#mevislab-sdk) or in your self-defined +[packages](glossary/#package). A detailed tutorial on how to create packages can be found [here](tutorials/basicmechanisms/macromodules/package/). If in doubt or missing something, check out the loaded packages in the preferences. {{}} Usually the quickest way to add modules to a network is the quick search in the menu bar. It offers the possibility to search for modules by module name. By default, the search will also be extended to keywords and substrings and is case-insensitive. To change these settings, click the magnifier button for the search options. -![Quick Search Options](/images/tutorials/introduction/MLMQuickSearch.png "Quick Search Options") +![Quick Search Options](images/tutorials/introduction/MLMQuickSearch.png "Quick Search Options") {{}} Any time you enter something in the MeVisLab GUI while not focussing a dialog window, your entry will be put into the quick search automatically. @@ -228,7 +228,7 @@ Any time you enter something in the MeVisLab GUI while not focussing a dialog wi Use the {{< keyboard "ArrowUp" >}} and {{< keyboard "ArrowDown" >}} keys on your keyboard to move to one of the listed modules. The module's decription will appear next to it, allowing you to decide if this is the right module for your use case. -![Quick Search Results](/images/tutorials/introduction/GSExampleNetworkViewImage02.png "Quick Search Results") +![Quick Search Results](images/tutorials/introduction/GSExampleNetworkViewImage02.png "Quick Search Results") {{}} For a more complex search, use the Module Search View. diff --git a/mevislab.github.io/content/tutorials/basicmechanisms.md b/mevislab.github.io/content/tutorials/basicmechanisms.md index 6ec13cb77..2a0f7ce83 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms.md @@ -30,7 +30,7 @@ First, we need to load the data we would like to work on, e.g., a CT scan. In Me Starting off, we will add the module `ImageLoad` to our network to load our data. The module can be found by typing its name into the search bar on the top-right corner and is added to your network by clicking it. -![Search for ImageLoad](/images/tutorials/basicmechanics/BM_01.png "Search for ImageLoad") +![Search for ImageLoad](images/tutorials/basicmechanics/BM_01.png "Search for ImageLoad") Next, we select and load the data we'd like to process. Double-click the module `ImageLoad` to open its panel. You can browse through your folders to select the data you'd like to open. Example data can be found in the MeVisLab DemoData directory *$(InstallDir)/Packages/MeVisLab/Resources/DemoData* located in the MeVisLab installation path. Select a file, for example, an MRI scan of a shoulder *Shoulder_Fracture.tif*. The image is loaded immediately and basic information of the loaded image can be seen in the Panel. @@ -53,7 +53,7 @@ You can now inspect your image in 2D: [//]: <> (MVL-653 when reworking the Manual, add an anchor to the 4.9.8. Views on this page and create a reference directly to this part on the page, as this is more suitable ) -![Output Inspector](/images/tutorials/basicmechanics/BM_03.png "Output Inspector") +![Output Inspector](images/tutorials/basicmechanics/BM_03.png "Output Inspector") Your image does not look like this? One reason might be that the slice of the image you are looking at has no information. Click on the Output Inspector and scroll through the slices (This process is called "Slicing") by using the mouse wheel {{< mousebutton "middle" >}}. Still not seeing anything? Then try to adjust the contrast of the given image by keeping the right mouse button {{< mousebutton "right" >}} pressed while moving the mouse. @@ -70,7 +70,7 @@ You are not restricted to 2D. The Output Inspector offers a 3D View of most load Below the Output Inspector, you'll find the Module Inspector. The Module Inspector displays properties and parameters of the selected module. Parameters are stored in so called **Fields**. Using the Module Inspector you can examine different fields of your `ImageLoad` module. The module has, for example, the fields *filename* (the path, the loaded image is stored in), as well as *sizeX*, *sizeY* and *sizeZ* (the size of the loaded image). -![Module Inspector](/images/tutorials/basicmechanics/BM_04.png "Module Inspector") +![Module Inspector](images/tutorials/basicmechanics/BM_04.png "Module Inspector") ### Viewer {#TutorialViewer} @@ -78,7 +78,7 @@ Instead of using the Output Inspector to inspect images, we'd suggest to add an The module `View2D` has one input connector for voxel images (triangle-shaped) and three other possible input connectors (Shaped like half-circles) on the bottom. The half-circle-shaped input connectors will be explained later on. Generally, module outputs can be connected to module inputs with the same symbol and thus transmit information and data between those modules. -![2D Viewer](/images/tutorials/basicmechanics/BM_05.png "2D Viewer") +![2D Viewer](images/tutorials/basicmechanics/BM_05.png "2D Viewer") You can now display the loaded image in the newly added viewer module by connecting the output of the module `ImageLoad` to the input connector of the module `View2D`. Follow these steps to do so: @@ -90,11 +90,11 @@ You can now display the loaded image in the newly added viewer module by connect 4. Release the mouse button on the input connector of your `View2D`-module to establish the connection. -![Establish connection](/images/tutorials/basicmechanics/BM_06.png "Establish connection") +![Establish connection](images/tutorials/basicmechanics/BM_06.png "Establish connection") Although the connection is established, no image rendering has started yet. To initialize rendering, open the `View2D` panel by double-clicking on the module. Similar to the Output Inspector, you can scroll through the slices and set different levels of contrast. The amount of displayed annotations is altered by pressing {{< keyboard "A" >}} on the keyboard (annotation-mode). -![View2D Panel](/images/tutorials/basicmechanics/BM_07.png "View2D Panel") +![View2D Panel](images/tutorials/basicmechanics/BM_07.png "View2D Panel") By dragging the connection away from either the input or the output connector, the connection is interrupted. @@ -110,11 +110,11 @@ Connecting, Disconnecting, Moving, and Replacing Connections is explained in mor An average kernel will be used to smooth the image as our next step will be to actually process our image. Add the `Convolution` module to your workspace and disconnect the `View2D` module from the `ImageLoad` module by clicking on the connection and pressing {{< keyboard "DEL" >}}. Now, you can build new connections from the module `ImageLoad` to the module `Convolution` and the `Convolution` module to `View2D`. -![Convolution Module](/images/tutorials/basicmechanics/BM_08.png "Convolution Module") +![Convolution Module](images/tutorials/basicmechanics/BM_08.png "Convolution Module") Open the panel of the `Convolution` module by double-clicking it. The panel allows configuration of the module. You can adjust parameters or select a kernel. We will be using the *3x3 Average Kernel* for now. -![Select a Kernel](/images/tutorials/basicmechanics/BM_09.png "Select a Kernel") +![Select a Kernel](images/tutorials/basicmechanics/BM_09.png "Select a Kernel") The module `View2D` is now displaying the smoothed image. @@ -122,7 +122,7 @@ To compare the processed and unprocessed image, click on the output connector of You can also inspect changes between processed (output connector) and unprocessed (input connector) images by adding a second or even third viewer to your network. "Layers" of applied changes can be inspected next to each other using more than one viewer and placing as well as connecting them accordingly. We will be using a second `View2D` module. Notice how the second viewer is numbered for you to be able to distinguish them better. It might be important to know at this point that numerous connections can be established from one output connector but an input connector can only receive one stream of data. Please connect the module `ImageLoad` to the second viewer to display the images twice. You can now scroll through the slices of both viewers and inspect the images. -![Multiple Viewers](/images/tutorials/basicmechanics/BM_10.png "Multiple Viewers") +![Multiple Viewers](images/tutorials/basicmechanics/BM_10.png "Multiple Viewers") ### Parameter Connection for Synchronization {#TutorialParameterConnection} @@ -132,12 +132,12 @@ We already know data connections between module inputs and outputs. Besides modu In order to practise establishing parameter connections, add the `SyncFloat` module to your workspace. -![SyncFloat Module](/images/tutorials/basicmechanics/BM_11.png "SyncFloat Module") +![SyncFloat Module](images/tutorials/basicmechanics/BM_11.png "SyncFloat Module") We will be synchronizing the *startSlice* fields of our viewers to be able to directly compare the effect our processing module has on the slices: Right-click the viewer `View2D` to open its context menu and select {{< menuitem "Show Window" "Automatic Panel" >}}. -![Automatic Panel View2D](/images/tutorials/basicmechanics/BM_12.png "Automatic Panel View2D") +![Automatic Panel View2D](images/tutorials/basicmechanics/BM_12.png "Automatic Panel View2D") Doing so shows all parameter fields of the module `View2D`. @@ -147,39 +147,39 @@ Now, double-click the module `SyncFloat` to open its panel. Click on the label *startSlice* in the automatic panel of the module `View2D`, keep the button pressed and drag the connection to the label *Float1* in the panel of the module `SyncFloat`. -![Synchronize StartSlice](/images/tutorials/basicmechanics/BM_13.png "Synchronize StartSlice") +![Synchronize StartSlice](images/tutorials/basicmechanics/BM_13.png "Synchronize StartSlice") The connection is drawn as a thin gray arrow between both modules with the arrowhead pointing to the module that receives the field value as input. The value of the field *startSlice* is now transmitted to the field *Float1*. Changing *startSlice* automatically changes *Float1*, but not the other way round. -![Parameter Connection StartSlice](/images/tutorials/basicmechanics/BM_14.png "Parameter Connection StartSlice") +![Parameter Connection StartSlice](images/tutorials/basicmechanics/BM_14.png "Parameter Connection StartSlice") We will now establish a connection from the module `SyncFloat` to the second viewer, `Viewer2D1`. In order to do that, open the automatic panel `View2D1`. Draw a connection from the label `Float2` of the panel of the module `SyncFloat` to the label *startSlice* in the automatic panel of the module `View2D1`. Lastly, implement a connection between the parameter fields *startSlice* of both viewers. Draw the connection from `View2D1` to `View2D`. -![Synchronize both directions](/images/tutorials/basicmechanics/BM_15.png "Synchronize both directions") +![Synchronize both directions](images/tutorials/basicmechanics/BM_15.png "Synchronize both directions") As a result, scrolling through the slices with the mouse wheel {{< mousebutton "middle" >}} in one of the viewers synchronizes the rendered slice in the second viewer. In this case, you can inspect the differences between smoothed and unsmoothed data on every single slice. -![Your final Network](/images/tutorials/basicmechanics/BM_16.png "Your final Network") +![Your final Network](images/tutorials/basicmechanics/BM_16.png "Your final Network") -It is also possible to use the pre-defined module `SynchroView2D` to accomplish a similar result.(`SynchroView2D`'s usage is described in more detail in [this chapter](/tutorials/visualization/visualizationexample1/) ). +It is also possible to use the pre-defined module `SynchroView2D` to accomplish a similar result.(`SynchroView2D`'s usage is described in more detail in [this chapter](tutorials/visualization/visualizationexample1/) ). ### Grouping Modules {#TutorialGroupingModules} A contour filter can be created based on our previously created network. To finalize the filter, add the modules `Arithmetic2` and `Morphology` to your workspace and connect the modules as shown below. Double-click the module `Arithmetic2` to open its panel. Change the field *Function* of the module `Arithmetic2` to use the function *subtract* in the panel of the module. The contour filter is done now. You can inspect each processing step using the Output Inspector by clicking on the input and output connectors of the respective modules. The final results can be displayed using the viewer modules. If necessary, adjust the contrast by pressing the right mouse button and moving the cursor. -![Grouping modules](/images/tutorials/basicmechanics/BM_17.png "Grouping modules") +![Grouping modules](images/tutorials/basicmechanics/BM_17.png "Grouping modules") If you'd like to know more about specific modules, search for help. You can do this by right-clicking the module and select help, which offers an example network and further information about the selected module in particular. -![Module Help](/images/tutorials/basicmechanics/BM_18.png "Module Help") +![Module Help](images/tutorials/basicmechanics/BM_18.png "Module Help") To be able to better distinguish the image processing pipeline, you can encapsulate it in a group: Select the three modules, for example, by dragging a selection rectangle around them. Then right-click the selection to open the context menu and select {{< menuitem "Add to New Group" >}}. -![Add modules to new group](/images/tutorials/basicmechanics/BM_19.png "Add to new group") +![Add modules to new group](images/tutorials/basicmechanics/BM_19.png "Add to new group") Enter a name for the new group, for example, *Filter*. The new group is created and displayed as a green rectangle. The group allows for quick interactions with all its modules. -![Your Filter Group](/images/tutorials/basicmechanics/BM_20.png "Your Filter Group") +![Your Filter Group](images/tutorials/basicmechanics/BM_20.png "Your Filter Group") Your network got very complex and you lost track? No problem. Let MeVisLab arrange your modules automatically via {{< menuitem "Mein Menu" "Edit" "Auto Arrange Selection" >}} (or via keyboard shortcut {{< keyboard "CTRL" "1" >}}). @@ -201,12 +201,12 @@ You have probably already noticed how the modules differ in color. Each color re To condense our filter into one single module, we will now be creating a macro module out of it. To do that, right-click on the group title and select *Convert To Local Macro*. Name your new macro module and finish. You just created a local macro module. Local macros can only be used from networks in the same or any parent directory. -![Convert to local macro](/images/tutorials/basicmechanics/BM_21.png "Convert to local macro") -![Your first local macro](/images/tutorials/basicmechanics/BM_22.png "Your first local macro") +![Convert to local macro](images/tutorials/basicmechanics/BM_21.png "Convert to local macro") +![Your first local macro](images/tutorials/basicmechanics/BM_22.png "Your first local macro") Right-click the macro module and select *Show Internal Network* to inspect and change the internal network. You can change the properties of the new macro module by changing the properties in the internal network. You can, for example, right-click the module `Convolution` and change the kernel. These changes will be preserved. -![Internal Network of your local macro](/images/tutorials/basicmechanics/BM_23.png "Internal Network of your local macro") +![Internal Network of your local macro](images/tutorials/basicmechanics/BM_23.png "Internal Network of your local macro") {{< youtube "VmK6qx-vKWk">}} diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/coordinatesystems/coordinatesystems.md b/mevislab.github.io/content/tutorials/basicmechanisms/coordinatesystems/coordinatesystems.md index 846f9396f..de3655670 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/coordinatesystems/coordinatesystems.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/coordinatesystems/coordinatesystems.md @@ -23,7 +23,7 @@ World coordinate systems in MeVisLab are always [right handed](https://en.wikipe The blue rectangle shows the same region in the three coordinate systems. -![Coordinate Systems in MeVisLab](/images/tutorials/basicmechanics/GSExampleImageProcessing10b.png "Coordinate Systems in MeVisLab") +![Coordinate Systems in MeVisLab](images/tutorials/basicmechanics/GSExampleImageProcessing10b.png "Coordinate Systems in MeVisLab") ## World Coordinates World coordinates are: @@ -36,27 +36,27 @@ The origin of the world coordinate system can be anywhere and is not clearly def ### World Coordinates in MeVisLab You can show the world coordinates in MeVisLab by using the following example network: -![World Coordinates in MeVisLab](/images/tutorials/basicmechanics/WorldCoordinates.png "World Coordinates in MeVisLab") +![World Coordinates in MeVisLab](images/tutorials/basicmechanics/WorldCoordinates.png "World Coordinates in MeVisLab") The `ConstantImage` module generates an artificial image with a certain size, data type, and a constant fill value. The origin of the image is at the origin of the world coordinate system, therefore the `SoCoordinateSystem` module shows the world coordinate system. In order to have a larger z-axis, open the panel of the `ConstantImage` module and set *IMage Size* for *Z* to *256*. -![ConstantImage Info](/images/tutorials/basicmechanics/ConstantImageInfo.png "ConstantImage Info") +![ConstantImage Info](images/tutorials/basicmechanics/ConstantImageInfo.png "ConstantImage Info") Placing an object into the Open Inventor Scene of the `SoExaminerViewer`, in this case a `SoCube` with *width*, *height*, and *depth* of 10, places the object to the origin of the world coordinate system. -![SoCube in world coordinate system](/images/tutorials/basicmechanics/SoCubeWorldCoordinates.png "SoCube in world coordinate system") +![SoCube in world coordinate system](images/tutorials/basicmechanics/SoCubeWorldCoordinates.png "SoCube in world coordinate system") ### Translations You can move an object in your scene, for example by using a `SoTranslation` module. Update your network and add the module before your cube. Defining a translation vector 50, 0, 0 moves your cube by 50 in x-direction based on the origin of the world coordinate system. -![SoTranslation](/images/tutorials/basicmechanics/SoTranslation.png "SoTranslation") +![SoTranslation](images/tutorials/basicmechanics/SoTranslation.png "SoTranslation") ### Transformations More complex transformations can be done by using the `SoTransform` module. You can not only translate an existing object, but also rotate, scale, and apply many other transformations. -![SoTransform](/images/tutorials/basicmechanics/SoTransform.png "SoTransform") +![SoTransform](images/tutorials/basicmechanics/SoTransform.png "SoTransform") -{{< networkfile "/examples/basic_mechanisms/coordinatesystems/WorldCoordinates.mlab" >}} +{{< networkfile "examples/basic_mechanisms/coordinatesystems/WorldCoordinates.mlab" >}} ## Voxel Coordinates Voxel coordinates are: @@ -67,45 +67,45 @@ Voxel coordinates are: ### Voxel Coordinates in MeVisLab You can show the voxel coordinates in MeVisLab by using the following example network: -![Voxel Coordinates](/images/tutorials/basicmechanics/VoxelCoordinates.png "Voxel Coordinates") +![Voxel Coordinates](images/tutorials/basicmechanics/VoxelCoordinates.png "Voxel Coordinates") Load the file *Liver1_CT_venous.small.tif* .The `Info` module shows detailed information about the image loaded by the `LocalImage`. Opening the `SoExaminerViewer` shows the voxel coordinate system of the loaded image. You may have to change the LUT in `SoGVRVolumeRenderer` so that the image looks better. -![Voxel coordinates of the loaded image](/images/tutorials/basicmechanics/SoExaminerViewer_Voxel.png "Voxel coordinates of the loaded image") +![Voxel coordinates of the loaded image](images/tutorials/basicmechanics/SoExaminerViewer_Voxel.png "Voxel coordinates of the loaded image") The *Advanced* tab of the `Info` module shows the world coordinates of the image. In this case, the origin of the voxel coordinate system is located at -186.993, -173.993, -249.993. In addition to that, you can see a scaling that has been done on the image. The voxel sizes are shown in the diagonal values of the matrix as 3.985792, 3.985792, 3.985798. -![World coordinates of the loaded image](/images/tutorials/basicmechanics/ImageInfo_Advanced.png "World coordinates of the loaded image") +![World coordinates of the loaded image](images/tutorials/basicmechanics/ImageInfo_Advanced.png "World coordinates of the loaded image") You can change the scaling to 1 by adding a `Resample3D` module to the network: set the voxel size to 1, 1, 1 and inspect the `Info` module. -![Resample3D](/images/tutorials/basicmechanics/Resample3D.png "Resample3D") +![Resample3D](images/tutorials/basicmechanics/Resample3D.png "Resample3D") -![Image Info after Resampling](/images/tutorials/basicmechanics/ImageInfo_AdvancedResampled.png "Image Info after Resampling") +![Image Info after Resampling](images/tutorials/basicmechanics/ImageInfo_AdvancedResampled.png "Image Info after Resampling") The voxel size is now 1. You can add this network to the world coordinate system network developed above and see both coordinate systems. {{}} -Replace the `SoGroup` module from the World Group in your network by a `SoSeparator`. Additional details about the difference can be found [here](https://mevislab.github.io/examples/tutorials/openinventor). +Replace the `SoGroup` module from the World Group in your network by a `SoSeparator`. Additional details about the difference can be found [here](tutorials/openinventor). {{}} -![World coordinates of the loaded image](/images/tutorials/basicmechanics/WorldVoxelNetwork.png "World coordinates of the loaded image") +![World coordinates of the loaded image](images/tutorials/basicmechanics/WorldVoxelNetwork.png "World coordinates of the loaded image") Opening the `SoExaminerViewer` shows the world coordinate system in white and the voxel coordinate system in yellow. -![World and Voxel coordinates](/images/tutorials/basicmechanics/SoExaminerViewer_both.png "World and Voxel coordinates") +![World and Voxel coordinates](images/tutorials/basicmechanics/SoExaminerViewer_both.png "World and Voxel coordinates") On the yellow axis, we can see that the coordinate systems are located as already seen in the `Info` module *Advanced* tab. On the x-axis, the voxel coordinate origin is translated by -186.993 and on the y-axis by -173.993. You can also add a `SoVertexProperty` and a `SoLineSet` module and configure a line from the origin of the world coordinate system 0, 0, 0 to the origin of the voxel coordinate system as defined by the image -186.993, -173.993, -249.993. -![SoVertexProperty](/images/tutorials/basicmechanics/Arrow.png "SoVertexProperty") +![SoVertexProperty](images/tutorials/basicmechanics/Arrow.png "SoVertexProperty") -{{< networkfile "/examples/basic_mechanisms/coordinatesystems/VoxelCoordinates.mlab" >}} +{{< networkfile "examples/basic_mechanisms/coordinatesystems/VoxelCoordinates.mlab" >}} ## Device Coordinates Device coordinates are: diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/coordinatesystems/coordinatesystems2.md b/mevislab.github.io/content/tutorials/basicmechanisms/coordinatesystems/coordinatesystems2.md index 4a7fbea22..d95e33bdf 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/coordinatesystems/coordinatesystems2.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/coordinatesystems/coordinatesystems2.md @@ -22,7 +22,7 @@ World coordinates also refer to the patient axes. They are: * Right-handed * Not standardized regarding their origin -![World Coordinates in Context of the Human Body](/images/tutorials/visualization/V2_00.png "World Coordinates in Context of the Human Body") +![World Coordinates in Context of the Human Body](images/tutorials/visualization/V2_00.png "World Coordinates in Context of the Human Body") The DICOM (Digital Imaging and Communications in Medicine) standard defines a data format that groups information into data sets. This way, the image data is always kept together with all meta information like patient ID, study time, series time, acquisition data, etc. The image slice is represented by another tag with pixel information. @@ -51,17 +51,17 @@ Another option for Python is [pydicom](https://pydicom.github.io/). ## Orthogonal Views The module `OrthoView2D` provides a 2D view displaying the input image in three orthogonal viewing directions. By default, the view is configured as *Cube* where the transverse view is placed in the top right segment, sagittal in bottom left and coronal in bottom right segment. Use the left mouse button to set a position in the data set. This position will be displayed in all available views and is available as field *worldPosition*. -![OrthoView2D](/images/tutorials/basicmechanics/OrthoView2D.png "OrthoView2D") +![OrthoView2D](images/tutorials/basicmechanics/OrthoView2D.png "OrthoView2D") -As already learned in the previous example [1.1: MeVisLab Coordinate Systems](/tutorials/basicmechanisms/coordinatesystems/coordinatesystems), world and voxel positions are based on different coordinate systems. Selecting the top left corner of any of your views will not show a world position of 0, 0, 0. You can move the mouse cursor to the voxel position 0, 0, 0 as seen in the image information of the viewers in brackets *(x, y, z)*. The field *worldPosition* then shows the location of the image in world coordinate system (see `Info` module). +As already learned in the previous example [1.1: MeVisLab Coordinate Systems](tutorials/basicmechanisms/coordinatesystems/coordinatesystems), world and voxel positions are based on different coordinate systems. Selecting the top left corner of any of your views will not show a world position of 0, 0, 0. You can move the mouse cursor to the voxel position 0, 0, 0 as seen in the image information of the viewers in brackets *(x, y, z)*. The field *worldPosition* then shows the location of the image in world coordinate system (see `Info` module). -![OrthoView2D Voxel- and World Position](/images/tutorials/basicmechanics/OrthoView2D_WorldPosition.png "OrthoView2D Voxel- and World Position") +![OrthoView2D Voxel- and World Position](images/tutorials/basicmechanics/OrthoView2D_WorldPosition.png "OrthoView2D Voxel- and World Position") Another option is to use the module `OrthoReformat3` which transforms the input image (by rotating and/or flipping) into the three main views commonly used: * Output 0: Sagittal view * Output 1: Coronal view * Output 2: Transverse view -![OrthoReformat3](/images/tutorials/basicmechanics/OrthoReformat3.png "OrthoReformat3") +![OrthoReformat3](images/tutorials/basicmechanics/OrthoReformat3.png "OrthoReformat3") The general `View2D` always uses the original view from the image data without reconstructing another view. In case of *ProbandT1*, this is the sagittal view. diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/dataimport.md b/mevislab.github.io/content/tutorials/basicmechanisms/dataimport.md index 23d33e5be..d1ddc44a1 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/dataimport.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/dataimport.md @@ -21,10 +21,10 @@ The easiest way to load data in MeVisLab is to drop the file onto the MeVisLab w {{}} These chapters explain the data formats and modules related to this example: -* [Images](/tutorials/basicmechanisms/dataimport#ImageImport) -* [DICOM Data](/tutorials/basicmechanisms/dataimport#DICOMImport) -* [Segmentations / 2D Contours](/tutorials/basicmechanisms/dataimport#2DContours) -* [3D Data / Meshes](/tutorials/basicmechanisms/dataimport#3DMeshes) +* [Images](tutorials/basicmechanisms/dataimport#ImageImport) +* [DICOM Data](tutorials/basicmechanisms/dataimport#DICOMImport) +* [Segmentations / 2D Contours](tutorials/basicmechanisms/dataimport#2DContours) +* [3D Data / Meshes](tutorials/basicmechanisms/dataimport#3DMeshes) Example files and images can be found in your MeVisLab installation directory under Packages > MeVisLab > Resources > DemoData @@ -34,7 +34,7 @@ Detailed explanations on loading images onto your MeVisLab workspace can be foun ## Images {#ImageImport} A good option to load images is the `ImageLoad` module. -![ImageLoad Module](/images/tutorials/basicmechanics/ImageLoad.png "ImageLoad Module") +![ImageLoad Module](images/tutorials/basicmechanics/ImageLoad.png "ImageLoad Module") The `ImageLoad` module can import the following formats: * DICOM @@ -62,21 +62,21 @@ The `DicomImport` module allows to define a directory containing DICOM files to * **STUDY LEVEL** Study Date (0008,0020) - Study Description (0008,1030) * **SERIES/VOLUME LEVEL** Modality (0008,0060) - Series Description (0008,103e) - Rows (0028,0010) - Columns (0028,0011) - number of slices in volume - number of time points in volume -![DicomImport Module](/images/tutorials/basicmechanics/DicomImport.png "DicomImport Module") +![DicomImport Module](images/tutorials/basicmechanics/DicomImport.png "DicomImport Module") ### Configuration The `DicomImport` module generates volumes based on the **Dicom Processor Library (DPL)** which allows to define sorting and partitioning options. -![DicomImport Sort Part Configuration](/images/tutorials/basicmechanics/DicomImportSortPart.png "DicomImport Sort Part Configuration") +![DicomImport Sort Part Configuration](images/tutorials/basicmechanics/DicomImportSortPart.png "DicomImport Sort Part Configuration") ### DicomTree information In order to get all DICOM tags from your currently imported and selected volume, you can connect the `DicomImport` module to a `DicomTagBrowser`. -![DicomTagBrowser Module](/images/tutorials/basicmechanics/DicomTagBrowser.png "DicomTagBrowser Module") +![DicomTagBrowser Module](images/tutorials/basicmechanics/DicomTagBrowser.png "DicomTagBrowser Module") In MeVisLab versions later than 4.2.0 the *Output Inspector* provides the option to show the DICOM tags of the currently selected output directly. You do not need to add a separate `DicomTagBrowser` module anymore. -![DICOM Information in Output Inspector](/images/tutorials/basicmechanics/OutputInspectorDICOM.png "DICOM Information in Output Inspector") +![DICOM Information in Output Inspector](images/tutorials/basicmechanics/OutputInspectorDICOM.png "DICOM Information in Output Inspector") ## Segmentations / 2D Contours {#2DContours} 2-dimensional contours in MeVisLab are handled via *CSO*s (**C**ontour **S**egmentation **O**bjects). @@ -116,13 +116,13 @@ The module `WEMLoad` loads different 3D mesh file formats like: * VRML (\*.wrl) * Winged Edge Mesh (\*.wem) -![WEMLoad Module](/images/tutorials/basicmechanics/WEMLoad.png "WEMLoad Module") +![WEMLoad Module](images/tutorials/basicmechanics/WEMLoad.png "WEMLoad Module") WEMs can be rendered via Open Inventor by using the modules `SoExaminerViewer` or `SoRenderArea` and `SoCameraInteraction`. Before visualizing a WEM, it needs to be converted to a Scene Object via `SoWEMRenderer`. -![SoWEMRenderer Module](/images/tutorials/basicmechanics/SoWEMRenderer.png "SoWEMRenderer Module") +![SoWEMRenderer Module](images/tutorials/basicmechanics/SoWEMRenderer.png "SoWEMRenderer Module") {{}} Tutorials for WEMs are available [here](../../dataobjects/surfaces/surfaceobjects). @@ -135,10 +135,10 @@ The `SoSceneLoader` module is able to load external 3D formats. MeVisLab uses th Supported file formats of the assimp library are documented on their [website](https://github.com/assimp/assimp/blob/master/doc/Fileformats.md). {{}} -![SoSceneLoader Module](/images/tutorials/basicmechanics/SoSceneLoader.png "SoSceneLoader Module") +![SoSceneLoader Module](images/tutorials/basicmechanics/SoSceneLoader.png "SoSceneLoader Module") The {{< docuLinks "/../MeVisLab/Standard/Documentation/Publish/ModuleReference/SoSceneLoader.html" "SoSceneLoader" >}} module generates a 3D scene from your loaded files which can be rendered via {{< docuLinks "/../MeVisLab/Standard/Documentation/Publish/ModuleReference/SoExaminerViewer.html" "SoExaminerViewer" >}} or {{< docuLinks "/../MeVisLab/Standard/Documentation/Publish/ModuleReference/SoRenderArea.html" "SoRenderArea" >}} and {{< docuLinks "/../MeVisLab/Standard/Documentation/Publish/ModuleReference/SoCameraInteraction.html" "SoCameraInteraction" >}} {{}} -Example usage is explained in the tutorials for [Open Inventor](/tutorials/openinventor). +Example usage is explained in the tutorials for [Open Inventor](tutorials/openinventor). {{}} diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules.md index d8ea9d710..a6365898d 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules.md @@ -28,17 +28,17 @@ You have two main options for developing a macro module: * **With Internal Networks**: Use a macro module to reuse a network of modules. For example, if you build a network that applies a specific image filter and you want to use this setup in multiple projects, you can wrap the entire network into a single macro module. This way, you don’t need to manually reconnect all the individual modules each time — you just use your macro module. You can also add inputs and outputs to connect your internal network with other modules. -An example can be found in chapter [Basic Mechanics of MeVisLab (Example: Building a Contour Filter)](/tutorials/basicmechanisms#TutorialMacroModules). +An example can be found in chapter [Basic Mechanics of MeVisLab (Example: Building a Contour Filter)](tutorials/basicmechanisms#TutorialMacroModules). * **Without Internal Networks**: Use a macro module to add your own Python code. If MeVisLab is missing a specific functionality, you can write your own Python script and execute it it in a macro module. This allows you to extend the software with custom behavior that integrates smoothly into your project. You can see the Python code at the right side of the image below. The image shows these two options. The left side encapsulates a network of three modules into one macro module. The right side shows a macro module without an internal network, only containing your custom Python script. -A typical example for macro modules without an internal network is the execution of a pre-trained AI model on an input ML image, see [Example 2: Brain Parcellation using PyTorch](/tutorials/thirdparty/pytorch/pytorchexample2/) for details. +A typical example for macro modules without an internal network is the execution of a pre-trained AI model on an input ML image, see [Example 2: Brain Parcellation using PyTorch](tutorials/thirdparty/pytorch/pytorchexample2/) for details. It is also possible to combine both approaches. You can add internal networks and additionally write Python code for user interaction and processing. - ![Internal Processing and Python Interaction](/images/tutorials/basicmechanics/with.png "Internal Processing and Python Interaction") + ![Internal Processing and Python Interaction](images/tutorials/basicmechanics/with.png "Internal Processing and Python Interaction") ### Benefits of Macro Modules: * **Encapsulation:** @@ -65,7 +65,7 @@ A Local Macro module in MeVisLab exists within the context of the current networ * A local macro can only be reused elsewhere by copying it into another folder with your network file. #### Global Macro Module: - A global macro module is stored in a central location within your MeVisLab installation. The directory is called Package. Once a global macro module is created, it appears in the module browser and can be used in any MeVisLab network you open. See [Package creation](/tutorials/basicmechanisms/macromodules/package/) for details about Packages. + A global macro module is stored in a central location within your MeVisLab installation. The directory is called Package. Once a global macro module is created, it appears in the module browser and can be used in any MeVisLab network you open. See [Package creation](tutorials/basicmechanisms/macromodules/package/) for details about Packages. Local macro modules can be converted to global macro modules. MeVisLab then adds a definition file containing the name and package of the module and copies the content to your selected package directory. Package directories are loaded automatically when you start MeVisLab in case they have been added to your user packages via main menu {{< menuitem "Edit" "Preferences" "Packages" >}}. @@ -99,16 +99,16 @@ You have two options when adding fields to your macro module: * **Define your own fields:** You can define your own fields by specifying their name, type, and default value in the *\*.script* file. This allows you to provide custom parameters for your macro module, tailored to your specific needs. These parameters can be use as input from the user or output from the modules processing. * **Reuse fields from the internal network:** Instead of defining your own field, you can expose an existing field from one of the modules of your internal network. To do this, you reference the *internalName* of the internal field you want to reuse. This makes the internal field accessible at the macro module level, allowing users to interact with it directly without duplicating parameters. Changes of the field value are automatically applied in your internal network. -![Inputs, Outputs, and Fields](/images/tutorials/basicmechanics/fields.png "Inputs, Outputs, and Fields") +![Inputs, Outputs, and Fields](images/tutorials/basicmechanics/fields.png "Inputs, Outputs, and Fields") ### Files Associated with a Macro Module: Macro modules typically need the following files: * **Definition file (*\*.def*):** The module definition file contains the definition and information about the module like name, author, package, etc. **Definition files are only available for global macro modules**. * **Script file (*\*.script*):** The script file defines inputs, outputs, fields and the user interface of the macro module. In case you want to add Python code, it includes the reference to the Python file. The *\*.script* file allows you to define Python functions to be called on field changes and user interactions. -![user interface and the internal interface](/images/tutorials/basicmechanics/mycountourFilter.png "user interface and the internal interface") +![user interface and the internal interface](images/tutorials/basicmechanics/mycountourFilter.png "user interface and the internal interface") -* **Python file (*\*.py*):** *(Optional)* The Python file contains the Python code that is used by the module. See section [Python functions and Script files](/tutorials/basicmechanisms/macromodules#PythonAndScripts) for different options to add Python functions to user interactions. +* **Python file (*\*.py*):** *(Optional)* The Python file contains the Python code that is used by the module. See section [Python functions and Script files](tutorials/basicmechanisms/macromodules#PythonAndScripts) for different options to add Python functions to user interactions. * **Internal network file (*\*.mlab*):** *(Optional)* Stores the internal network of the module if available. This file essentially defines the macro module's internal structure and connections. * **Macro module help file (*\*.mhelp*):** *(Optional)* Provides help documentation for the macro module. This file is used to display information to users about the module’s functionality, usage, and any specific instructions. @@ -119,14 +119,14 @@ Python functions can be executed on any user interaction with your macro module. * **Module initialization**: You can add the *initCommand* to the *Commands* section and the given Python function is called whenever the module is added to the workspace or reloaded. * **Window creation**: You can add the *initCommand* to the *Window* section and the given Python function is called whenever the panel of the module is opened. * **User interaction**: You can add commands to any user interface element like *Buttons* to call Python functions on user interactions with this element. The image below shows you the user interface and the internal interface: -* **Field changes**: You can also react on any changes of fields in your module and create Field Listeners. See section [Field Listeners](/tutorials/basicmechanisms/macromodules#FieldListeners) for details. +* **Field changes**: You can also react on any changes of fields in your module and create Field Listeners. See section [Field Listeners](tutorials/basicmechanisms/macromodules#FieldListeners) for details. ### Field Listeners: {#FieldListeners} Field listeners are mechanisms to execute Python code automatically anytime the value of a field changes. This allows you to create dynamic responses to user interactions in the module's parameter panel. You can define field listeners within the *Commands* sections of the *\*.script* file. You get a reference to the field object and then use a method to add a callback function that will be executed when the field's value is modified. -For an example see [Example 2.5.2: Module interactions via Python scripting](/tutorials/basicmechanisms/macromodules/scriptingexample2/). +For an example see [Example 2.5.2: Module interactions via Python scripting](tutorials/basicmechanisms/macromodules/scriptingexample2/). ## Summary * Macro modules allow you to add your own functionality to MeVisLab. You can add inputs and outputs and connect existing modules to your new macro module. diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/globalmacromodules.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/globalmacromodules.md index 1e3884c10..3bec6f67e 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/globalmacromodules.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/globalmacromodules.md @@ -23,10 +23,10 @@ In this chapter you will learn how to create global macro modules. There are man ## Steps to Do ### Transform a Local Macro Module into a Global Macro Module -To transform our local macro module `Filter` from [Chapter I](/tutorials/basicmechanisms#TutorialMacroModules) into a global macro module, +To transform our local macro module `Filter` from [Chapter I](tutorials/basicmechanisms#TutorialMacroModules) into a global macro module, right-click {{< mousebutton "right" >}} the macro module to open the context menu and select {{< menuitem "Extras" "Convert To Global Module..." >}} -![Convert local macro to global macro](/images/tutorials/basicmechanics/GUI_03.png "Convert local macro to global macro") +![Convert local macro to global macro](images/tutorials/basicmechanics/GUI_03.png "Convert local macro to global macro") ### Define Module Properties @@ -53,7 +53,7 @@ If you are working with MeVisLab versions before 5.0, make sure to chose *Direct Also keep in mind that Python files are only created automatically if selected in the Project Wizard. Converting a local macro to a global macro does NOT create a Python file automatically. {{}} -![Create global macro module](/images/tutorials/basicmechanics/GUI_04.png "Create global macro module") +![Create global macro module](images/tutorials/basicmechanics/GUI_04.png "Create global macro module") ### Use the Project Wizard to Create Global Macro Modules Instead of converting a local macro module into a global macro module, you can also use the *Project Wizard* to create new macro modules. Open the Project Wizard via {{< menuitem "File" "Run Project Wizard ..." >}}. Then, select {{< menuitem "Modules (Scripting)" "Macro module" >}} and *Run Wizard*. @@ -81,7 +81,7 @@ Make sure to chose *Directory Structure* as *self-contained*. This ensures that Press *Next >* to edit further properties. You have the opportunity to directly define the internal network of the macro module, for example, by copying an existing network. In this case, we could copy the network of the local macro module `Filter` we already created. In addition, you have the opportunity to directly create a Python file. Python scripting can be used for the implementation of module interactions and other module functionalities. More information about Python scripting can be found [here](./tutorials/basicmechanisms/macromodules/pythonscripting). -{{< imagegallery 2 "/images" "ProjectWizard1" "ProjectWizard2" >}} +{{< imagegallery 2 "images" "ProjectWizard1" "ProjectWizard2" >}} ## Structure of Global Macro Modules After creating your global macro module, you can find the created project *MyProject* in your package. This project contains your macro module `Filter`. For the macro module exist three files: @@ -93,19 +93,19 @@ In addition, two folders may be created: * *mhelp*: contains the help files of all modules of this project * *network*: contains the example networks of all modules of this project -![Structure of global macro modules](/images/tutorials/basicmechanics/GUI_04_2.png "Structure of global macro modules") +![Structure of global macro modules](images/tutorials/basicmechanics/GUI_04_2.png "Structure of global macro modules") ## How to Find Global Macro Modules All available modules are categorized and can be found via {{< menuitem "Modules" >}} in the respective genre. After creating a global macro, the new module can be found via {{< menuitem "Modules" "Filters" >}}. In addition, you can now find your macro module via module search. -![Find module in menu](/images/tutorials/basicmechanics/GUI_05.png "Find module in menu") +![Find module in menu](images/tutorials/basicmechanics/GUI_05.png "Find module in menu") {{}} If you do not find your new global macro module, try to reload the module database. -![Reload module database](/images/tutorials/basicmechanics/GUI_05_2.png "Reload module database") +![Reload module database](images/tutorials/basicmechanics/GUI_05_2.png "Reload module database") {{}} ## Summary diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/guidesign.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/guidesign.md index 995537a47..c53e3ef2b 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/guidesign.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/guidesign.md @@ -30,15 +30,15 @@ More information about GUI design in MeVisLab can be found {{< docuLinks "/Resou ## Creating a Panel for the Macro Module Filter {#Example_Paneldesign} ### Creation of a module panel -In [Example 2.2](/tutorials/basicmechanisms/macromodules/globalmacromodules) we created the global macro module `Filter`. By now, this module does not have a proper panel. When double-clicking {{< mousebutton "left" >}} the module, the *Automatic Panel* is shown. +In [Example 2.2](tutorials/basicmechanisms/macromodules/globalmacromodules) we created the global macro module `Filter`. By now, this module does not have a proper panel. When double-clicking {{< mousebutton "left" >}} the module, the *Automatic Panel* is shown. The *Automatic Panel* contains fields, as well as module in and outputs. In this case, no fields exists except the *instanceName*. Accordingly, there is no possibility to interact with the module. Only the input and the output of the module are given. -![Automatic Panel](/images/tutorials/basicmechanics/GUI_10.png "Automatic Panel") +![Automatic Panel](images/tutorials/basicmechanics/GUI_10.png "Automatic Panel") To add and edit a panel, open the context menu and select {{< menuitem "Related Files" "Filter.script" >}}. The text editor {{< docuLinks "/Resources/Documentation/Publish/SDK/MeVisLabManual/ch26.html" "MATE">}} opens. You can see the file *Filter.script*, which you can edit to define a custom User Interface for the Module. -![Module script file](/images/tutorials/basicmechanics/GUI_11.png "Module script file") +![Module script file](images/tutorials/basicmechanics/GUI_11.png "Module script file") ### Module Interface Per default, the *.script* file contains the {{< docuLinks "/Resources/Documentation/Publish/SDK/MDLReference/index.html#mdl_Interface" "interface" >}} of the module. @@ -70,9 +70,9 @@ Creating an input/output causes: 1. Input/output connectors are added to the module. 2. You can find placeholders for the input and output in the internal network (see image). 3. Input/output fields are added to the automatic panel. -4. A description of the input/output fields is automatically added to the module help file, when opening the *\*.mhelp* file after input/output creation. Helpfile creation is explained in [Example 2.3](/tutorials/basicmechanisms/macromodules/helpfiles/). +4. A description of the input/output fields is automatically added to the module help file, when opening the *\*.mhelp* file after input/output creation. Helpfile creation is explained in [Example 2.3](tutorials/basicmechanisms/macromodules/helpfiles/). -![Internal Network of your macro module](/images/tutorials/basicmechanics/BM_23.png "Internal Network of your macro module") +![Internal Network of your macro module](images/tutorials/basicmechanics/BM_23.png "Internal Network of your macro module") ##### Module Fields @@ -115,7 +115,7 @@ Window MyWindowName { ``` {{}} -![Module Panel](/images/tutorials/basicmechanics/ModulePanel.png "Module Panel") +![Module Panel](images/tutorials/basicmechanics/ModulePanel.png "Module Panel") You can define different properties of your control. For a window, you can for example define a title, or whether the window should be shown in full screen (*fullscreen = True*). @@ -150,7 +150,7 @@ Window MyWindowName { ``` {{}} -![Vertical layout of Box and Text](/images/tutorials/basicmechanics/VerticalLayout.png "Vertical layout of Box and Text") +![Vertical layout of Box and Text](images/tutorials/basicmechanics/VerticalLayout.png "Vertical layout of Box and Text") {{< highlight filename="Filter.script" >}} ```Stan @@ -171,7 +171,7 @@ Window MyWindowName { ``` {{}} -![Horizontal layout of Box and Text](/images/tutorials/basicmechanics/HorizontalLayout.png "Horizontal layout of Box and Text") +![Horizontal layout of Box and Text](images/tutorials/basicmechanics/HorizontalLayout.png "Horizontal layout of Box and Text") There are much more controls, which can be used. For example a CheckBox, @@ -196,7 +196,7 @@ network name. To find the internal field name, open the internal network of the Then, open the panel of the module `Convolution` and right-click {{< mousebutton "right" >}} the field title *Use* of the box *Predefined Kernel* and select *Copy Name*. You now copied the internal network name of the field to your clipboard. The name is made up of *ModuleName.FieldName*, in this case *Convolution.predefKernel*. -![Convolution Module](/images/tutorials/basicmechanics/Convolution.png "Convolution Module") +![Convolution Module](images/tutorials/basicmechanics/Convolution.png "Convolution Module") In the panel of the module `Convolution`, you can change this variable *Kernel* via a drop-down menu. In MDL, a drop-down menu is called a {{< docuLinks "/Resources/Documentation/Publish/SDK/MDLReference/index.html#mdl_ComboBox" "ComboBox" >}}. We can take over the field *predefKernel*, its drop-down menu and all its properties by @@ -219,7 +219,7 @@ Window MyWindowName { ``` {{}} -![Selecting the kernel](/images/tutorials/basicmechanics/SelectingKernel.png "Selecting the kernel") +![Selecting the kernel](images/tutorials/basicmechanics/SelectingKernel.png "Selecting the kernel") As an alternative, you can define the field *kernel* in the *Parameters* environment, and reference the defined field by its name. The result in the panel is the same. You can see a difference in the Automatic Panel. All fields that are defined in the interface in the *Parameters* environment appear in the Automatic Panel. Fields of the internal network, which are used but not declared in the section *Parameters* of the module interface, do not appear in the Automatic Panel. diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/helpfiles.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/helpfiles.md index 502134896..8ce8979d4 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/helpfiles.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/helpfiles.md @@ -14,12 +14,12 @@ menu: --- # Example 2.3: Creation of Module Help -Generating help of a macro module is part of the video about macro modules from [Example 2: Creation of global macro modules](/tutorials/basicmechanisms/macromodules/globalmacromodules) +Generating help of a macro module is part of the video about macro modules from [Example 2: Creation of global macro modules](tutorials/basicmechanisms/macromodules/globalmacromodules) {{< youtube "M4HnA0d1V5k">}} ## Introduction -In this chapter, you will learn how to create a help page and an example network. For hands-on training, we will use the macro module `Filter`, which was created in the [previous chapter](/tutorials/basicmechanisms/macromodules/globalmacromodules). +In this chapter, you will learn how to create a help page and an example network. For hands-on training, we will use the macro module `Filter`, which was created in the [previous chapter](tutorials/basicmechanisms/macromodules/globalmacromodules). Depending on the way the macro module was created, the default help page and example network might or might not exist. In the case they exist, the help page only contains information about module inputs and outputs as well as module fields. The example network only contains the macro module itself. Both, the help page and the example network, can be created and edited after module creation. @@ -29,13 +29,13 @@ We will start by creating a help file using the built-in text editor {{< docuLin [//]: <> (MVL-653) -![Creation of module help](/images/tutorials/basicmechanics/GUI_06.png "Creation of module help") +![Creation of module help](images/tutorials/basicmechanics/GUI_06.png "Creation of module help") {{< docuLinks "/Resources/Documentation/Publish/SDK/MeVisLabManual/ch26.html" "MeVisLab MATE">}} opens. An *.mhelp* file (*Filter.mhelp*) is created automatically and stored in the folder your macro module `Filter` is stored in. You can find the folder structure in MATE on the left side. Editing the text field, you can edit the help file. [//]: <> (MVL-653) -![Edit module help file via MATE](/images/tutorials/basicmechanics/GUI_07.png "Edit module help file via MATE") +![Edit module help file via MATE](images/tutorials/basicmechanics/GUI_07.png "Edit module help file via MATE") When creating the help file of a module, all important information of the module down to the field specifications are extracted and created automatically. Thus, the @@ -45,11 +45,11 @@ side, you can find the outline of the help file. Each section can be edited. In this example, we added the purpose of the module to the help file. -![Edit module help file via MATE](/images/tutorials/basicmechanics/GUI_08.png "Edit module help file via MATE") +![Edit module help file via MATE](images/tutorials/basicmechanics/GUI_08.png "Edit module help file via MATE") MATE offers the possibility to format the text. By using the button *M*, module names can be formatted in such a way that links to the respective help file of the modules are created. -![Edit module help file via MATE](/images/tutorials/basicmechanics/GUI_08_2.png "Edit module help file via MATE") +![Edit module help file via MATE](images/tutorials/basicmechanics/GUI_08_2.png "Edit module help file via MATE") After finishing your documentation, you can click *Generate Help* or {{< keyboard "F7" >}} and your final help file is generated. @@ -62,7 +62,7 @@ The Module Help Editor is explained {{< docuLinks "/Resources/Documentation/Publ The result can be seen when opening the help file via context menu in MeVisLab IDE (or by pressing {{< keyboard "F1" >}}). -![Help file of the module](/images/tutorials/basicmechanics/GUI_09.png "Help file of the module") +![Help file of the module](images/tutorials/basicmechanics/GUI_09.png "Help file of the module") {{}} Depending on the way the macro module was created, more or less features are automatically given in the help file and the example network. All missing features can be added manually. @@ -73,11 +73,11 @@ To add an example network to your module, you need to add a reference to the res It is possible that the reference to the example network or the file *FilterExample.mlab* is missing. One reason could be that its creation was not selected when creating the macro module. In this case, add the reference and the file manually. -![Reference to Example Network](/images/tutorials/basicmechanics/ExpNetwork_01.png "Reference to Example Network") +![Reference to Example Network](images/tutorials/basicmechanics/ExpNetwork_01.png "Reference to Example Network") To create the example network, open the file *FilterExample.mlab* in MeVisLab and create an appropriate example. -![Example Network](/images/tutorials/basicmechanics/ExpNetwork_02.png "Example Network") +![Example Network](images/tutorials/basicmechanics/ExpNetwork_02.png "Example Network") ## Summary diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/itemmodelview.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/itemmodelview.md index 74646de77..a2a7629df 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/itemmodelview.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/itemmodelview.md @@ -23,7 +23,7 @@ We create a macro module that receives an input image and then shows some select ### Create a Macro Module {{}} -Make sure to create a package first. Packages are the way MeVisLab organizes different development projects. You can find an example in chapter [Package creation](/tutorials/basicmechanisms/macromodules/package/). +Make sure to create a package first. Packages are the way MeVisLab organizes different development projects. You can find an example in chapter [Package creation](tutorials/basicmechanisms/macromodules/package/). {{}} Use the *Project Wizard* via menu entry {{< menuitem "File" "Run Project Wizard ..." >}} to create a new macro module named `MyItemModelView`. @@ -34,14 +34,14 @@ We can leave the *Fields* empty for now. We can add them in the *.script* file. Click *Create* {{< mousebutton "left" >}}. -{{< imagegallery 3 "/images/tutorials/basicmechanics" "ItemModel_1" "ItemModel_2" "ItemModel_3">}} +{{< imagegallery 3 "images/tutorials/basicmechanics" "ItemModel_1" "ItemModel_2" "ItemModel_3">}} If you cannot find your module via *Module Search*, reload module cache by clicking the menu item {{< menuitem "Extras" "Reload Module Database (Clear Cache)" >}} ### Define the Necessary Fields Add your new module `MyItemModelView` to your workspace. It does not provide a user interface and you do not have any *Fields* available. -![Empty Module](/images/tutorials/basicmechanics/ItemModel_4.png "Empty Module") +![Empty Module](images/tutorials/basicmechanics/ItemModel_4.png "Empty Module") Open the *.script* file of your module via right-click {{< mousebutton "right" >}} and {{< menuitem "Related Files (4)" "MyItemModelView.script" >}}. @@ -98,7 +98,7 @@ Interface { If you now open your panel, you should see the *Input* *inImage* and the just created *Fields*. The *Field* *id* is necessary to identify unique objects in your *ItemModel* later. In order to make this example easier to understand, we defined all types of the *Fields* as *String*. You can also use different types, if you like. -![Module Input and Fields](/images/tutorials/basicmechanics/ItemModel_5.png "Module Input and Fields") +![Module Input and Fields](images/tutorials/basicmechanics/ItemModel_5.png "Module Input and Fields") ### Add the ItemModelView to Your Panel We can now add the *ItemModelView* to our panel and define the columns of the view, that we want to see. Add a *Window* section to your script file and define it as seen below. @@ -141,7 +141,7 @@ Outputs { Your module now also shows an output *MLBase* object and the columns you defined for the *ItemModelView*. -![Module Output and Columns](/images/tutorials/basicmechanics/ItemModel_6.png "Module Output and Columns") +![Module Output and Columns](images/tutorials/basicmechanics/ItemModel_6.png "Module Output and Columns") ### Fill Your Table with Data We want to get the necessary information from the defined input image *inImage*. We want the module to update the content whenever the input image changes. Therefore, we need a *Field Listener* calling a Python function whenever the input image changes. Add it to your *Commands* section. @@ -357,7 +357,7 @@ The image data is then used to create the root item of our model. We use the sel If you now open the panel of your module, you can already see the results. -![Module Panel](/images/tutorials/basicmechanics/ItemModel_7.png "Module Panel") +![Module Panel](images/tutorials/basicmechanics/ItemModel_7.png "Module Panel") The first line shows the information of the patient, the study and the series and each child item represents a single slice of the image. @@ -402,11 +402,11 @@ def itemClicked(field: "mevislab.MLABField"): The *itemClicked* function uses *id* from the selected item to get the value of column 8 (in this case, it is the *SOP Instance UID* of the image) and prints this value. -![Clicked Item](/images/tutorials/basicmechanics/ItemModel_8.png "Clicked Item") +![Clicked Item](images/tutorials/basicmechanics/ItemModel_8.png "Clicked Item") The problem is that the *Field* *selection* also changes whenever a new item is added to the model. Your debug output is already flooded with SOP Instance UIDs without interaction. -![Debug Output](/images/tutorials/basicmechanics/ItemModel_9.png "Debug Output") +![Debug Output](images/tutorials/basicmechanics/ItemModel_9.png "Debug Output") Add another global parameter to your Python script to prevent the *FieldListener* from executing during the *imageChanged* event. diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/package.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/package.md index 7a4ebf3cc..c2e19f33e 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/package.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/package.md @@ -31,7 +31,7 @@ Macro modules and projects are stored in packages. If you like to create a globa ## Steps to Do To create packages and package groups, we will use the Project Wizard. Open the Project Wizard via {{< menuitem "File" "Run Project Wizard ..." >}}. Then, select {{< menuitem "Package" "New Package" >}} and *Run Wizard*. -![The Project Wizard](/images/tutorials/basicmechanics/GUI_01.png "The Project Wizard") +![The Project Wizard](images/tutorials/basicmechanics/GUI_01.png "The Project Wizard") Next you need to: @@ -49,7 +49,7 @@ desired directory. The folder of your package group contains the folder of your package. We have now successfully created a package in which we can store our global macro module. -![Package creation](/images/tutorials/basicmechanics/GUI_02.png "Package creation") +![Package creation](images/tutorials/basicmechanics/GUI_02.png "Package creation") ## Summary * Packages are needed to store global macro modules and projects. diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythondebugger.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythondebugger.md index 168b18f2f..bb8df56d2 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythondebugger.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythondebugger.md @@ -22,7 +22,7 @@ MeVisLab provides the powerful integrated text editor MATE. By default, MATE is ## Prepare Your Network We are using a very simple network of pre-defined modules, but you can also debug your self-written Python scripts. Add a `LocalImage` module to your workspace and connect it to a `DicomTagBrowser` module. The `DicomTagBrowser` module shows a table containing the DICOM tags of your currently opened file. -![Example Network](/images/tutorials/basicmechanics/Debug1.png "Example Network") +![Example Network](images/tutorials/basicmechanics/Debug1.png "Example Network") ## Open Python Script in MATE To debug our module, we need to open the Python file. Right-click {{< mousebutton "right" >}} the module `DicomTagBrowser` and select {{< menuitem "Related Files (3)" "DicomTagBrowser.py" >}}. The file is opened in MATE. @@ -31,7 +31,7 @@ To debug our module, we need to open the Python file. Right-click {{< mousebutto MATE only opens Python files if the default configuration in *MeVisLab/Preferences* is not changed for *Supportive Programs*. {{}} -![MATE](/images/tutorials/basicmechanics/Debug2.png "MATE") +![MATE](images/tutorials/basicmechanics/Debug2.png "MATE") {{}} You cannot only debug your own files, but also Python scripts of pre-defined MeVisLab modules. @@ -54,17 +54,17 @@ First we need to enable debugging. In the MATE main menu, select {{< menuitem "D ### Debugging Panel The *Debugging* panel allows you to step through your code. -![Debugging Panel](/images/tutorials/basicmechanics/Debug3.png "Debugging Panel") +![Debugging Panel](images/tutorials/basicmechanics/Debug3.png "Debugging Panel") ### Stack Frames Panel The *Stack Frames* panel shows your current stack trace while debugging. -![Stack Frames](/images/tutorials/basicmechanics/Debug4.png "Stack Frames") +![Stack Frames](images/tutorials/basicmechanics/Debug4.png "Stack Frames") ### Variables/Watches/Evaluate Expression Panel Another panel *Variables/Watches/Evaluate Expression* appears, where you can see all current local and global variables. Add your own variables to watch their current value and evaluate your own expressions. -![Variables/Watches/Evaluate Expression](/images/tutorials/basicmechanics/Debug5.png "Variables/Watches/Evaluate Expression") +![Variables/Watches/Evaluate Expression](images/tutorials/basicmechanics/Debug5.png "Variables/Watches/Evaluate Expression") Scroll to line 180 and left click {{< mousebutton "left" >}} on the line number. @@ -81,11 +81,11 @@ You can see a red dot marking a break point for debugging. Whenever this line of Go back to MeVisLab and right click {{< mousebutton "right" >}} on any DICOM tag in the `DicomTagBrowser` module. Select {{< menuitem "Copy Tag Name" >}}. -![Copy Tag Name](/images/tutorials/basicmechanics/Debug6.png "Copy Tag Name") +![Copy Tag Name](images/tutorials/basicmechanics/Debug6.png "Copy Tag Name") MATE opens automatically and you can see an additional yellow arrow indicating the line about to be executed next. -![MATE Debugger](/images/tutorials/basicmechanics/Debug7.png "MATE Debugger") +![MATE Debugger](images/tutorials/basicmechanics/Debug7.png "MATE Debugger") You can now use the controls of the *Debugging* panels to step through your code or just continue execution of your code. Whenever your execution is stopped, you can use the *Stack Frames* and the *Variables/Watches/Evaluate Expression* panel to see the current value of all or just watched variables. @@ -104,23 +104,23 @@ Select *Watches* panel and enter **item.text(1)**. Again copy any tag name in Me Use the *Debugging* panel (fifth button *Step to next line*) or press {{< keyboard "F10" >}}. The debugger jumps to the next line (**181**) and the variable *item* is defined. You can see the value of the *Tag Name* you just copied. You can add any variables you are interested in the same way. -![Watches panel](/images/tutorials/basicmechanics/Debug7b.png "Watches panel") +![Watches panel](images/tutorials/basicmechanics/Debug7b.png "Watches panel") The *Variables* panel now shows all currently available local and global variables including their value(s). The *Stack Trace* panel shows that the *copyCurrentTagName* function has been called after the *DicomTagBrowser.MenuItem.command* from the \*.script file of the `DicomTagBrowser` module. -![Variables/Watches panel](/images/tutorials/basicmechanics/Debug7a.png "Variables/Watches panel") +![Variables/Watches panel](images/tutorials/basicmechanics/Debug7a.png "Variables/Watches panel") ## Conditions for Breakpoints You can also define conditions for your breakpoints. Remove breakpoint in line 180 and set a new one in line 181. In case you only want to stop the execution of your script if a specific condition is met, right click {{< mousebutton "right" >}} on your breakpoint and select {{< menuitem "Set Condition for Breakpoint" >}}. A dialog opens where you can define your condition. Enter **item.text(1) == 'SOPClassUID'** as condition. -![Conditions for Breakpoints](/images/tutorials/basicmechanics/Debug8.png "Conditions for Breakpoints") +![Conditions for Breakpoints](images/tutorials/basicmechanics/Debug8.png "Conditions for Breakpoints") Now, the code execution is only stopped if you copy the tag name *SOPClassUID*. In case another line is copied, the execution does not stop and just continues. ## Evaluate Expression The *Evaluate Expression* tab allows you to modify variables during execution. In our example you can set the result **item.text(1)** to something like **item.setText(1, "Hello")**. If you now step to the next line via {{< keyboard "F10" >}}, your watched value shows *"Hello"* instead of *"SOPClassUID"*. -{{< imagegallery 2 "/images/tutorials/basicmechanics" "Debug9" "Debug9a" >}} +{{< imagegallery 2 "images/tutorials/basicmechanics" "Debug9" "Debug9a" >}} ## Summary * MATE allows debugging of any Python files including files pre-defined in MeVisLab. diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythonpip.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythonpip.md index 8bd99789a..a08104c98 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythonpip.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythonpip.md @@ -38,7 +38,7 @@ These are some of the most important packages that have been adapted for MeVisLa ### Working with the PythonPip Module on your MeVisLab Workspace The module `PythonPip` can be found via module search. It provides a user interface showing the currently installed Python packages including version and MeVisLab package it has been installed to. -![PythonPip interface](/images/tutorials/thirdparty/pytorch_example1_2.png "PythonPip interface") +![PythonPip interface](images/tutorials/thirdparty/pytorch_example1_2.png "PythonPip interface") Select the package to install the Python package into, write the name of the package and click install. @@ -68,7 +68,7 @@ MeVisPython -m pip ... The commandline option does not provide the possibility to install into a specified user package. Third-party information and *.mli* files are not adapted automatically with the commandline tool. {{}} -In [Example 1: Installing PyTorch using the PythonPip module](/tutorials/thirdparty/pytorch/pytorchexample1/) we are installing PyTorch to use it in MeVisLab scripting. +In [Example 1: Installing PyTorch using the PythonPip module](tutorials/thirdparty/pytorch/pytorchexample1/) we are installing PyTorch to use it in MeVisLab scripting. ## Summary * The `PythonPip` module allows to install additional Python packages to adapt MeVisLab to a certain extent. diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythonscripting.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythonscripting.md index d7d6d00a2..7d2416de4 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythonscripting.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/pythonscripting.md @@ -30,7 +30,7 @@ You can find the internal name of one module field in the respective network. Op When entering *ctx* to the console, you can see the context you are working with. In the context of the *Scripting Console*, you have access to your workspace, meaning the whole network, its modules, and the module fields. -![Scripting context](/images/tutorials/basicmechanics/Scripting_02.png "Scripting context") +![Scripting context](images/tutorials/basicmechanics/Scripting_02.png "Scripting context") ### Editing the Workspace @@ -42,11 +42,11 @@ In the *Scripting Console*, you can add and connect modules using the following In this case, we added the modules `DicomImport` and `View2D` to the workspace and connected both modules. -![Add and connect modules via scripting](/images/tutorials/basicmechanics/Scripting_03.png "Add and connect modules via scripting") +![Add and connect modules via scripting](images/tutorials/basicmechanics/Scripting_03.png "Add and connect modules via scripting") It is also possible to add notes to your workspace. -![Add a note to the workspace](/images/tutorials/basicmechanics/Scripting_04.png "Add a note to your workspace") +![Add a note to the workspace](images/tutorials/basicmechanics/Scripting_04.png "Add a note to your workspace") ### Access Modules and Module Fields @@ -56,7 +56,7 @@ You can also directly access a module field via *ctx.field("* < ModuleName.Field [//]: <> (MVL-653) -![Access modules and module fields](/images/tutorials/basicmechanics/Scripting_05.png "Access modules and module fields") +![Access modules and module fields](images/tutorials/basicmechanics/Scripting_05.png "Access modules and module fields") ### Python Scripting Reference @@ -118,7 +118,7 @@ Under {{< menuitem "View" "Views" "Scripting Assistant" >}} you can find the vie For example: Open the *Scripting Assistant*. Add the module `WEMInitialize` to your workspace. You can select a *Model*, for example the cube. In addition, you can change the *Translation* and press *Apply*. All these actions can be seen in the *Scripting Assistant*, translated into Python code. Therefore, the *Scripting Assistant* is a powerful tool to help you to script you actions. -![Scripting Assistant](/images/tutorials/basicmechanics/Scripting_01.png "Scripting Assistant") +![Scripting Assistant](images/tutorials/basicmechanics/Scripting_01.png "Scripting Assistant") ## Examples See the following examples for Python scripting: diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/scriptingexample1.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/scriptingexample1.md index 5fb912f18..94952ff4d 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/scriptingexample1.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/scriptingexample1.md @@ -26,7 +26,7 @@ The module `RunPythonScript` allows to execute Python scripts from within a MeVi In this example, we like to dynamically change the color of a cube in an Open Inventor scene. For that, add and connect the following modules as shown. -![RunPythonScript Example](/images/tutorials/basicmechanics/Scripting_06.png "RunPythonScript") +![RunPythonScript Example](images/tutorials/basicmechanics/Scripting_06.png "RunPythonScript") ### Scripting Using the Module `RunPythonScript` @@ -35,7 +35,7 @@ Open the panel of `RunPythonScript`. There is an option to display input and out You can also name these fields individually, by ticking the box *Edit field titles*. Call the first input field *TimeCounter* and draw a parameter connection from the field *Value* of the panel of `TimeCounter` to the input field *TimeCounter* of the module `RunPythonScript`. We can name the first output field *DiffuseColor* and draw a parameter connection from this field to the field *Diffuse Color* in the panel of the module `SoMaterial`. -![TimeCounter](/images/tutorials/basicmechanics/Scripting_07.png "TimeCounter") +![TimeCounter](images/tutorials/basicmechanics/Scripting_07.png "TimeCounter") The module `TimeCounter` counts in a defined *Frequency*. We like to randomly change the color of the cube in the frequency the `TimeCounter` counts. Add this code: @@ -55,7 +55,7 @@ To update the output field *DiffuseColor*, it is important to use the methods *u You can now see a color change in the viewer `SoExaminerViewer` every time the `TimeCounter` counts. -![Triggered color change](/images/tutorials/basicmechanics/Scripting_08.png "Triggered color change") +![Triggered color change](images/tutorials/basicmechanics/Scripting_08.png "Triggered color change") ## Summary diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/scriptingexample2.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/scriptingexample2.md index f76eae5fa..49ae0ccd3 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/scriptingexample2.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/scriptingexample2.md @@ -39,15 +39,15 @@ Press *Next* and edit the following: Now, create your macro module and reload MeVisLab. You can find your module via search in MeVisLab. -![Creating macro module](/images/tutorials/basicmechanics/CreatingMacroModule.png "Creating macro module") +![Creating macro module](images/tutorials/basicmechanics/CreatingMacroModule.png "Creating macro module") -![Enable Python scripting](/images/tutorials/basicmechanics/EnablePythonScripting.png "Enable Python scripting") +![Enable Python scripting](images/tutorials/basicmechanics/EnablePythonScripting.png "Enable Python scripting") To design a panel and create a user interface for the macro module, open the *.script* file. You can see that a *Command* environment exist, which defines the Python file as source for all commands. -![Open the script file](/images/tutorials/basicmechanics/OpenScriptFile.png "Open the script file") +![Open the script file](images/tutorials/basicmechanics/OpenScriptFile.png "Open the script file") -![Script file](/images/tutorials/basicmechanics/ScriptFile.png "Script file") +![Script file](images/tutorials/basicmechanics/ScriptFile.png "Script file") ### Creating a Panel with Tabs and Viewers @@ -81,7 +81,7 @@ Window { ``` {{}} -![Panel with Tabs and Viewers](/images/tutorials/basicmechanics/PanelWithTabsAndViewers.png "Panel with Tabs and Viewers") +![Panel with Tabs and Viewers](images/tutorials/basicmechanics/PanelWithTabsAndViewers.png "Panel with Tabs and Viewers") ### Edit Viewer Settings in the Panel @@ -91,9 +91,9 @@ internal network either via the context menu or using the middle mouse button {{< mousebutton "middle" >}} and click on the module. After that, open the Automatic Panel of the module `SoExaminerViewer` via context menu {{< menuitem "Show Windows" "Automatic Panel" >}} and change the field *decoration* to *False*. Keep in mind, as we did not create CSOs by now, the right viewer stays black. -![Change viewer settings](/images/tutorials/basicmechanics/ChangeViewerSettings.png "Change viewer settings") +![Change viewer settings](images/tutorials/basicmechanics/ChangeViewerSettings.png "Change viewer settings") -![Changed viewer settings](/images/tutorials/basicmechanics/ChangedViewerSettings.png "Changed viewer settings") +![Changed viewer settings](images/tutorials/basicmechanics/ChangedViewerSettings.png "Changed viewer settings") ### Selection of Images @@ -104,7 +104,7 @@ internal network of your macro module. Now you are able to open the panel of the module `LocalImage`. Right-click {{< mousebutton "right" >}} the desired field: In this case, right-click the label *Name:*. Select *Copy Name*, to copy the internal name of this field. -![Copy the field name](/images/tutorials/basicmechanics/GUI_Exp_09.png "Copy the field name") +![Copy the field name](images/tutorials/basicmechanics/GUI_Exp_09.png "Copy the field name") Now, you can add this field as a new field to your window by pasting the name. All field settings are taken over from the internal field from the module `LocalImage`. @@ -138,7 +138,7 @@ Window { ``` {{}} -![Add name field](/images/tutorials/basicmechanics/AddNameField.png "Add name field") +![Add name field](images/tutorials/basicmechanics/AddNameField.png "Add name field") ### Add Buttons to your Panel @@ -225,7 +225,7 @@ def fileDialog(): ``` {{}} -![Automatically generate CSOs based on Iso value](/images/tutorials/basicmechanics/GUI_Exp_14.png "Automatically generate CSOs based on Iso value") +![Automatically generate CSOs based on Iso value](images/tutorials/basicmechanics/GUI_Exp_14.png "Automatically generate CSOs based on Iso value") ### Colorizing CSOs @@ -237,11 +237,11 @@ can do this in the following way: 1. Enable the View *Scripting Assistant*, which translates actions into Python code. - ![Scripting Assistant](/images/tutorials/basicmechanics/GUI_Exp_15.png "Scripting Assistant") + ![Scripting Assistant](images/tutorials/basicmechanics/GUI_Exp_15.png "Scripting Assistant") 2. Enable a functionality that allows us to notice the id of the CSO we are currently hovering over with our mouse. For this open the internal network of our macro module. We will use the module `SoView2DCSOExtensibleEditor`. Open its panel and select the tab *Advanced*. You can check a box to enable *Update CSO id under mouse*. If you now hover over a CSO, you can see its id in the panel. We can save the internal network to save this functionality, but we can also solve our problem via scripting. The Scripting Assistant translated our action into code, which we can use. - ![Enabling CSO id identification](/images/tutorials/basicmechanics/GUI_Exp_16.png "Enabling CSO id identification") + ![Enabling CSO id identification](images/tutorials/basicmechanics/GUI_Exp_16.png "Enabling CSO id identification") We like to activate this functionality when opening the panel of our macro module `IsoCSOs`. Thus, we add a starting command to the control Window. We can call this command for example *enableFunctionalities*. @@ -329,7 +329,7 @@ TabViewItem Settings { ``` {{}} -![Colored selection](/images/tutorials/basicmechanics/GUI_Exp_22.png "Colored selection") +![Colored selection](images/tutorials/basicmechanics/GUI_Exp_22.png "Colored selection") ## Summary * The control *Tabview* creates tabs in panels. diff --git a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/soviewportregion.md b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/soviewportregion.md index 8bf617a57..26837a967 100644 --- a/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/soviewportregion.md +++ b/mevislab.github.io/content/tutorials/basicmechanisms/macromodules/soviewportregion.md @@ -27,27 +27,27 @@ We will demonstrate how to: ### Displaying Three Images in One Panel Add an `ImageLoad` module to your workspace and select a 3D image like *./MeVisLab/Resources/DemoData/MRI_Head.tif* from the MeVisLab demo data directory. Connect an `OrthoReformat3` module and add three `View2D` modules. -![Image Display Setup](/images/tutorials/basicmechanics/E6_1.png "Image Display Setup") +![Image Display Setup](images/tutorials/basicmechanics/E6_1.png "Image Display Setup") Opening the three `View2D` module panels now shows the data in three orthogonal views. The module `OrthoReformat3` transforms the input image (by rotating and/or flipping) into the three main views commonly used. -![3 Views in 3 Viewers](/images/tutorials/basicmechanics/E6_2.png "3 Views in 3 Viewers") +![3 Views in 3 Viewers](images/tutorials/basicmechanics/E6_2.png "3 Views in 3 Viewers") The module `SoViewportRegion` divides the render window into multiple areas, allowing different views or slices to be shown in the same window. It's useful in medical applications, like displaying MRI or CT images from different angles (axial, sagittal, coronal) at once, making data analysis easier and faster. Add three `SoViewportRegion` modules and connect each one to a `View2D` module. To display the hidden outputs of the `View2D` module, press {{< keyboard "SPACE" >}} and connect the output to the input of `SoViewportRegion`, as shown below. -![Connect SoViewportRegion with View2D](/images/tutorials/basicmechanics/E6_3.png "Connect SoViewportRegion with View2D") +![Connect SoViewportRegion with View2D](images/tutorials/basicmechanics/E6_3.png "Connect SoViewportRegion with View2D") Add a `SoRenderArea` for your final result to the network and connect all three `SoViewportRegion` modules to it. The result is that all of your viewers are initially displayed on top of each other in the bottom right corner. -![All three viewers on top of each other](/images/tutorials/basicmechanics/E6_4.png "All three viewers on top of each other") +![All three viewers on top of each other](images/tutorials/basicmechanics/E6_4.png "All three viewers on top of each other") This happens, because all three `SoViewportRegion` modules have the same settings for position and height or width. -![SoViewportRegion](/images/tutorials/basicmechanics/E6_5.png "SoViewportRegion") +![SoViewportRegion](images/tutorials/basicmechanics/E6_5.png "SoViewportRegion") The `SoViewportRegion` module allows to define the x- and y-position and the width and height of the image in the `SoRenderArea` module. @@ -62,7 +62,7 @@ We want to create a layout with the following setting: * Coronal view on the top right side * Sagittal view on the bottom right side -![Target Layout](/images/tutorials/basicmechanics/E6_6.png "Target Layout") +![Target Layout](images/tutorials/basicmechanics/E6_6.png "Target Layout") Now open the left `SoViewportRegion` module and change settings: @@ -77,7 +77,7 @@ Now open the left `SoViewportRegion` module and change settings: * *Domain* Fraction of height * *Reference* Upper window border -![Axial View](/images/tutorials/basicmechanics/E6_7.png "Axial View") +![Axial View](images/tutorials/basicmechanics/E6_7.png "Axial View") Continue with the middle `SoViewportRegion` module and change settings: @@ -92,7 +92,7 @@ Continue with the middle `SoViewportRegion` module and change settings: * *Domain* Fraction of smallest dimension * *Reference* Upper window border -![Coronal View](/images/tutorials/basicmechanics/E6_8.png "Coronal View") +![Coronal View](images/tutorials/basicmechanics/E6_8.png "Coronal View") The right `SoViewportRegion` module should look as follows: @@ -107,16 +107,16 @@ The right `SoViewportRegion` module should look as follows: * *Domain* Fraction of smallest dimension * *Reference* Upper window border -![Sagittal View](/images/tutorials/basicmechanics/E6_9.png "Sagittal View") +![Sagittal View](images/tutorials/basicmechanics/E6_9.png "Sagittal View") #### Displaying Four Images in One Panel In the next example, the `SoRenderArea` will display four views at the same time: axial, coronal, sagittal, and a 3D view. -![3D View Layout](/images/tutorials/basicmechanics/E6_11.png "3D View Layout") +![3D View Layout](images/tutorials/basicmechanics/E6_11.png "3D View Layout") These views will be arranged in a single panel, split into two sides, with each side showing two images. To add the 3D view, insert a `View3D` module and connect it to the `ImageLoad` module. Then connect the `View3D` to `SoCameraInteraction`, connect that to another `SoViewportRegion`, and finally to `SoRenderArea`. -![3D View Network](/images/tutorials/basicmechanics/E6_10.png "3D View Network") +![3D View Network](images/tutorials/basicmechanics/E6_10.png "3D View Network") Now open the left `SoViewportRegion` module and change settings: @@ -146,37 +146,37 @@ Open the right `SoViewportRegion` connected to the `SoCameraInteraction` module This setup will let you interact with the 3D view and display all four views together, as shown in the figure below. -![3D View](/images/tutorials/basicmechanics/E6_12.png "3D View") +![3D View](images/tutorials/basicmechanics/E6_12.png "3D View") You will see that the orientation cube of the 3D viewer appears in the bottom right corner of the `SoRenderArea`. To resolve this, you can check *Render delayed paths* in the `SoViewportRegion` module of the 3D viewer. -![Final Network](/images/tutorials/basicmechanics/E6_13.png "Final Network") +![Final Network](images/tutorials/basicmechanics/E6_13.png "Final Network") ## Alternative Using `SoView2D` In case you want the same dataset to be visualized in multiple viewers, the module `SoView2D` already provides this functionality. -![Initial SoView2D](/images/tutorials/basicmechanics/SoView2D_1.png "Initial SoView2D") +![Initial SoView2D](images/tutorials/basicmechanics/SoView2D_1.png "Initial SoView2D") Whenever you are using the `SoView2D` module to visualize a 2D dataset, you need to add a `View2DExtensions` module and, for example, a `SoRenderArea` module. Without the `View2DExtensions` module, interactions like scrolling through slices or changing the window and level settings will not be possible. By default, you will see your images in a single viewer the same way as if you use the `View2D` module. The *number of columns* is defined as *1* by default. If you now change the *Number of Slices* to something like *3*, you will see three viewers shown in a single column. As we can only connect one dataset, this network cannot display multiple series at the same time. -![Multiple slices in SoView2D](/images/tutorials/basicmechanics/SoView2D_2.png "Multiple slices in SoView2D") +![Multiple slices in SoView2D](images/tutorials/basicmechanics/SoView2D_2.png "Multiple slices in SoView2D") Changing the *number of columns* to *3* and the *Number of Slices* to *9* results in a 3 x 3 layout. -![Multiple slices and columns in SoView2D](/images/tutorials/basicmechanics/SoView2D_3.png "Multiple slices and columns in SoView2D") +![Multiple slices and columns in SoView2D](images/tutorials/basicmechanics/SoView2D_3.png "Multiple slices and columns in SoView2D") By default, the module shows consecutive slices with a slice step size *1*. If you change this, you can define the size of the steps between the viewers. If the resulting slice does not exist in the dataset, the viewer remains empty. -![Not existing slices](/images/tutorials/basicmechanics/SoView2D_4.png "Not existing slices") +![Not existing slices](images/tutorials/basicmechanics/SoView2D_4.png "Not existing slices") You are also able to define a slab size. This means the depth of the slab. You can either use the blend mode *Maximum* or *Blend*. ## Exercise You can play around with the different `SoViewportRegion` modules to create your own layouts by setting the values a little different. -![Exercise](/images/tutorials/basicmechanics/E6_14.png "Exercise") +![Exercise](images/tutorials/basicmechanics/E6_14.png "Exercise") ## Summary * Own layouts can be created by using multiple `SoViewportRegion` modules diff --git a/mevislab.github.io/content/tutorials/dataobjects.md b/mevislab.github.io/content/tutorials/dataobjects.md index 7a52cc45d..e7dde76ed 100644 --- a/mevislab.github.io/content/tutorials/dataobjects.md +++ b/mevislab.github.io/content/tutorials/dataobjects.md @@ -15,11 +15,11 @@ menu: ## Data Objects in MeVisLab {#TutorialDataObjects} MeVisLab provides pre-defined data objects, e.g.: -* [Contour Segmentation Objects (CSOs)](/tutorials/dataobjects/contourobjects)
, +* [Contour Segmentation Objects (CSOs)](tutorials/dataobjects/contourobjects)
, which are three-dimensional objects encapsulating formerly defined contours within images. -* [Surface Objects (Winged Edge Meshes or WEMs)](/tutorials/dataobjects/surfaceobjects)
+* [Surface Objects (Winged Edge Meshes or WEMs)](tutorials/dataobjects/surfaceobjects)
represent the surface of geometrical figures and allow the user to manipulate them. -* [Markers](/tutorials/dataobjects/markerobjects)
+* [Markers](tutorials/dataobjects/markerobjects)
are used to mark specific locations or aspects of an image and allow to process those later on. * [Curves](tutorials/dataobjects/curves)
can print the results of a function as two-dimensional mathematical graphs into a diagram. diff --git a/mevislab.github.io/content/tutorials/dataobjects/contourobjects.md b/mevislab.github.io/content/tutorials/dataobjects/contourobjects.md index 84110f525..e76f121fd 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/contourobjects.md +++ b/mevislab.github.io/content/tutorials/dataobjects/contourobjects.md @@ -28,7 +28,7 @@ The *Path Points* form the connection between the *Seed Points* whereby contour In general, the *Seed Points* are created interactively using an editor module and the *Path Points* are generated automatically by interpolation or other algorithms. -![Contour Segmented Object (CSO)](/images/tutorials/dataobjects/contours/CSO_Expl_01.png "Contour Segmented Object (CSO)") +![Contour Segmented Object (CSO)](images/tutorials/dataobjects/contours/CSO_Expl_01.png "Contour Segmented Object (CSO)") #### CSO Editors {#CSOEditors} @@ -36,7 +36,7 @@ As mentioned, when creating CSOs, you can do this interactively by using an edit The following images show editors available in MeVisLab for drawing CSOs: -{{< imagegallery 6 "/images/tutorials/dataobjects/contours" "SoCSOPointEditor" "SoCSOAngleEditor" "SoCSOArrowEditor" "SoCSODistanceLineEditor" "SoCSODistancePolylineEditor" "SoCSOEllipseEditor" "SoCSORectangleEditor" "SoCSOSplineEditor" "SoCSOPolygonEditor" "SoCSOIsoEditor" "SoCSOLiveWireEditor">}} +{{< imagegallery 6 "images/tutorials/dataobjects/contours" "SoCSOPointEditor" "SoCSOAngleEditor" "SoCSOArrowEditor" "SoCSODistanceLineEditor" "SoCSODistancePolylineEditor" "SoCSOEllipseEditor" "SoCSORectangleEditor" "SoCSOSplineEditor" "SoCSOPolygonEditor" "SoCSOIsoEditor" "SoCSOLiveWireEditor">}} {{}} The `SoCSOIsoEditor` and `SoCSOLiveWireEditor` are special, because they are using an algorithm to detect edges themselves. @@ -49,15 +49,15 @@ The `SoCSOIsoEditor` and `SoCSOLiveWireEditor` are special, because they are usi All created CSOs are stored in CSO lists that can be saved and loaded on demand. The lists can not only store the coordinates of the CSOs, but also additional information in the form of name-value pairs (using specialized modules or Python scripting). -![Basic CSO Network](/images/tutorials/dataobjects/contours/BasicCSONetwork.png "Basic CSO Network") +![Basic CSO Network](images/tutorials/dataobjects/contours/BasicCSONetwork.png "Basic CSO Network") Each `SoCSO*Editor` requires a `SoView2DCSOExtensibleEditor` that manages attached CSO editors and renderers and offers an optional default renderer for all types of CSOs. In addition to that, the list of CSOs needs to be stored in a `CSOManager`. The appearance of the CSO can be defined by using a `SoCSOVisualizationSettings` module. -CSOs can also be grouped together. The following image shows two different CSO groups. Groups can be used to organize CSOs, in this case to distinguish the CSOs of the right and the left lung. [Here](/tutorials/dataobjects/contours/contourexample2/) you can find more information about CSO Groups. +CSOs can also be grouped together. The following image shows two different CSO groups. Groups can be used to organize CSOs, in this case to distinguish the CSOs of the right and the left lung. [Here](tutorials/dataobjects/contours/contourexample2/) you can find more information about CSO Groups. -![CSO Groups](/images/tutorials/dataobjects/contours/DO2_11_2.png "CSO Groups") +![CSO Groups](images/tutorials/dataobjects/contours/DO2_11_2.png "CSO Groups") {{}} For more information, see {{< docuLinks "/Standard/Documentation/Publish/Overviews/CSOOverview.html" "CSO Overview" >}} diff --git a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample1.md b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample1.md index 637915770..c4ceb4763 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample1.md +++ b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample1.md @@ -25,12 +25,12 @@ We like to start with the creation of CSOs. To create CSOs, you need a `SoCSO*`- ### Develop Your Network For this example, we need the following modules. Add the modules to your workspace, connect them as shown below, and load the example image *$(DemoDataPath)/BrainMultiModal/ProbandT1.tif*. -![Data Objects Contours Example 1](/images/tutorials/dataobjects/contours/DO1_01.png "Data Objects Contours Example 1") +![Data Objects Contours Example 1](images/tutorials/dataobjects/contours/DO1_01.png "Data Objects Contours Example 1") ### Edit Rectangular CSO Now, open the module `View2D`. Use your left mouse key {{< mousebutton "left" >}}, to draw a rectangle, which is your first CSO. -![Rectangle Contour](/images/tutorials/dataobjects/contours/DO1_02.png "Rectangle Contour") +![Rectangle Contour](images/tutorials/dataobjects/contours/DO1_02.png "Rectangle Contour") The involved modules have the following tasks: @@ -42,18 +42,18 @@ The involved modules have the following tasks: If you now open the panel of the `CSOManager`, you will find one CSO, the one we created before. If you like, you can name the CSO. -![CSO Manager](/images/tutorials/dataobjects/contours/DO1_04.png "CSO Manager") +![CSO Manager](images/tutorials/dataobjects/contours/DO1_04.png "CSO Manager") ### Change Properties of CSO Now, add the module `SoCSOVisualizationSettings` to your workspace and connect it as shown below. -![CSO Manager](/images/tutorials/dataobjects/contours/DO1_05.png "CSO Manager") +![CSO Manager](images/tutorials/dataobjects/contours/DO1_05.png "CSO Manager") Open the module to change the visualization settings of your CSOs. In this case, we change the line style (to dashed lines) and the color (to be red). Tick the *Auto apply* box at the bottom or press *Apply*. -![Visualization Settings](/images/tutorials/dataobjects/contours/DO1_07.png "Visualization Settings") +![Visualization Settings](images/tutorials/dataobjects/contours/DO1_07.png "Visualization Settings") ### CSOs of Different Shapes Exchange the module `SoCSORectangleEditor` with another editor, for @@ -62,12 +62,12 @@ allow to draw CSOs of other shapes. For polygon-shaped CSOs or CSOs consisting of splines, left-click on the image viewer to add new points to form the CSO. Double-click to finish the CSO. -![SoSCOPolygonEditor](/images/tutorials/dataobjects/contours/DO1_08.png "SoSCOPolygonEditor") -![SoCSOSplineEditor](/images/tutorials/dataobjects/contours/DO1_09.png "SoCSOSplineEditor") +![SoSCOPolygonEditor](images/tutorials/dataobjects/contours/DO1_08.png "SoSCOPolygonEditor") +![SoCSOSplineEditor](images/tutorials/dataobjects/contours/DO1_09.png "SoCSOSplineEditor") ### Draw Filled CSOs If you want to fill the shapes, you can simply add a `SoCSOFillingRenderer` module to your `SoView2DCSOExtensibleEditor`. -![SoCSOFillingRenderer](/images/tutorials/dataobjects/contours/DO1_09_filled.png "SoCSOFillingRenderer") +![SoCSOFillingRenderer](images/tutorials/dataobjects/contours/DO1_09_filled.png "SoCSOFillingRenderer") ## Exercises Create CSOs with green color and ellipsoid shapes. diff --git a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample2.md b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample2.md index cc4dcf29e..1f927b4e5 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample2.md +++ b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample2.md @@ -37,20 +37,20 @@ Now, create some CSOs on different, not consecutive slices. Afterwards, hover over the `CSOManager` and press the emerging plus-sign. This displays the amount of existing CSOs. -![Data Objects Contours Example 2](/images/tutorials/dataobjects/contours/DO2_02.png "Data Objects Contours Example 2") +![Data Objects Contours Example 2](images/tutorials/dataobjects/contours/DO2_02.png "Data Objects Contours Example 2") ### Create CSO Interpolations We like to generate interpolated contours for existing CSOs. In order to do that, add the module `CSOSliceInterpolator` to your workspace and connect it as shown. -![Slice Interpolation](/images/tutorials/dataobjects/contours/DO2_03.png "Slice Interpolation") +![Slice Interpolation](images/tutorials/dataobjects/contours/DO2_03.png "Slice Interpolation") Open the panel of module `CSOSliceInterpolator` and change the *Group Handling* and the *Mode* as shown. If you now press *Update*, interpolating CSOs are created. -![Slice Interpolation Settings](/images/tutorials/dataobjects/contours/DO2_04_2.png "Slice Interpolation Settings")   +![Slice Interpolation Settings](images/tutorials/dataobjects/contours/DO2_04_2.png "Slice Interpolation Settings")   You can see the interpolated CSOs are added to the `CSOManager`. If you now scroll through your slices, you can find the interpolated CSOs. @@ -59,7 +59,7 @@ You can also take a look on all existing CSOs by inspecting the output of the `CSOManager` using the Output Inspector. Custom CSOs are displayed in white and interpolated CSOs are marked in yellow. -![Interpolated CSOs](/images/tutorials/dataobjects/contours/DO2_06.png "Interpolated CSOs") +![Interpolated CSOs](images/tutorials/dataobjects/contours/DO2_06.png "Interpolated CSOs") ### Group CSOs We like to segment both lobes of the lung. To distinguish the CSOs of both lungs, we like to group CSOs together, according to the lung they belong to. First, we like to group together all CSOs belonging to the lung we already segmented. In order to do this, open the `CSOManager`. Create a new Group and label that Group. We chose the label *Left Lung*. Now, mark the created Group and all CSOs you want to include into that group and press *Combine*. If you click on the Group, all CSOs belonging to this Group are marked with a star. @@ -68,20 +68,20 @@ We like to segment both lobes of the lung. To distinguish the CSOs of both lungs Keep in mind, that the right lung might be displayed on the left side of the image and vice versa, depending on your view. {{}} -![Creating CSO Groups](/images/tutorials/dataobjects/contours/DO2_07.png "Creating CSO Groups") -![Creating CSO Groups](/images/tutorials/dataobjects/contours/DO2_07_2.png "Creating CSO Groups") +![Creating CSO Groups](images/tutorials/dataobjects/contours/DO2_07.png "Creating CSO Groups") +![Creating CSO Groups](images/tutorials/dataobjects/contours/DO2_07_2.png "Creating CSO Groups") As a next step, segment the right lung by creating new CSOs. -![Creation of further CSOs](/images/tutorials/dataobjects/contours/DO2_08.png "Creation of further CSOs") +![Creation of further CSOs](images/tutorials/dataobjects/contours/DO2_08.png "Creation of further CSOs") Create a new Group for all CSOs of the right lung. We labeled this Group *Right Lung*. Again, mark the group and the CSOs you like to combine and press *Combine*. -![Grouping remaining CSOs](/images/tutorials/dataobjects/contours/DO2_09.png "Grouping remaining CSOs") +![Grouping remaining CSOs](images/tutorials/dataobjects/contours/DO2_09.png "Grouping remaining CSOs") To visually distinguish the CSOs of both groups, change the color of each group under {{< menuitem "Group" "Visuals" >}}. We changed the color of the *Left Lung* to be green and of the *Right Lung* to be orange for path and seed points. In addition, we increased the *Width* of the path points. -![Interpolated CSOs](/images/tutorials/dataobjects/contours/DO2_10.png "Interpolated CSOs") +![Interpolated CSOs](images/tutorials/dataobjects/contours/DO2_10.png "Interpolated CSOs") As a last step, we need to disconnect the module `SoCSOVisualizationSettings`, as this module overwrites the visualization settings we enabled for each group in the `CSOManager`. -![Interpolated CSOs](/images/tutorials/dataobjects/contours/DO2_11.png "Interpolated CSOs") +![Interpolated CSOs](images/tutorials/dataobjects/contours/DO2_11.png "Interpolated CSOs") ## Summary * `SoCSOLiveWireEditor` can be used to create CSOs semi-automatically. diff --git a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample3.md b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample3.md index 7d27a713b..9eafb3b78 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample3.md +++ b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample3.md @@ -25,25 +25,25 @@ image. ## Steps to Do ### Develop Your Network -Use the network from the [contour example 2](/tutorials/dataobjects/contours/contourexample2) and add the modules `VoxelizeCSO`, +Use the network from the [contour example 2](tutorials/dataobjects/contours/contourexample2) and add the modules `VoxelizeCSO`, `SoView2DOverlay` and `View2D` to your workspace. Connect the module as shown. The module `VoxelizeCSO` allows to convert CSOs into voxel images. -![Data Objects Contours Example 3](/images/tutorials/dataobjects/contours/DO3_02.png "Data Objects Contours Example 3") +![Data Objects Contours Example 3](images/tutorials/dataobjects/contours/DO3_02.png "Data Objects Contours Example 3") ### Convert CSOs into Voxel Images Update the module `VoxelizeCSOs` to create overlays based on your CSOs. The result can be seen in `View2D1`. -![Overlay](/images/tutorials/dataobjects/contours/DO3_03.png "Overlay") +![Overlay](images/tutorials/dataobjects/contours/DO3_03.png "Overlay") Next, we like to inspect the marked lobe of the lung. This means we like to inspect the object that is built out of CSOs. In order to do that, add the `View3D` module. The 3D version of the lung can be seen in the viewer. -![Additional 3D Viewer](/images/tutorials/dataobjects/contours/DO3_04.png "Additional 3D Viewer") -![Extracted Object](/images/tutorials/dataobjects/contours/DO3_05.png "Extracted Object") +![Additional 3D Viewer](images/tutorials/dataobjects/contours/DO3_04.png "Additional 3D Viewer") +![Extracted Object](images/tutorials/dataobjects/contours/DO3_05.png "Extracted Object") ## Summary * The module `VoxelizeCSO` converts CSOs to voxel images. diff --git a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample4.md b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample4.md index 36fa74e46..9eb121124 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample4.md +++ b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample4.md @@ -26,7 +26,7 @@ Add the module `CalculateVolume` and `SoView2DAnnotation` to your workspace and connect both modules as shown. Update the module `CalculateVolume`, which directly shows the volume of our object. -![Data Objects Contours Example 4](/images/tutorials/dataobjects/contours/DO4_01.png "Data Objects Contours Example 4") +![Data Objects Contours Example 4](images/tutorials/dataobjects/contours/DO4_01.png "Data Objects Contours Example 4") ### Display the Lung Volume in the Image We now like to display the volume in the image viewer. For this, open @@ -37,25 +37,25 @@ the module `CalculateVolume` and the *input00* of the module `SoView2DAnnotation`. This connection projects the *Total Volume* to the input of `SoView2DAnnotation`. -![Display Volume](/images/tutorials/dataobjects/contours/DO4_02.png "Display Volume") +![Display Volume](images/tutorials/dataobjects/contours/DO4_02.png "Display Volume") Go back to the tab *General* to select the *Annotation Mode User*. A separate tab exists for each annotation mode. -![Annotate Image](/images/tutorials/dataobjects/contours/DO4_03_2.png "Annotate Image") +![Annotate Image](images/tutorials/dataobjects/contours/DO4_03_2.png "Annotate Image") We select the tab *User* that we like to work on. You can see four fields that display four areas of a viewer in which you can add information text to the image. -![Annotate Image 2](/images/tutorials/dataobjects/contours/DO4_04.png "Annotate Image") +![Annotate Image 2](images/tutorials/dataobjects/contours/DO4_04.png "Annotate Image") In this example we only like to add the volume, so delete all present input and replace that by the shown text. Now, you can see that the volume is displayed in the image viewer. If this is not the case, switch the annotations of the viewer by pressing the keyboard shortcut {{< keyboard "A" >}}. -![Display Volume in Image](/images/tutorials/dataobjects/contours/DO4_05.png "Display Volume in Image") +![Display Volume in Image](images/tutorials/dataobjects/contours/DO4_05.png "Display Volume in Image") ## Summary * `CalculateVolume` can calculate the volume of a voxel image. diff --git a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample5.md b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample5.md index 42fb183c0..0972a4b03 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample5.md +++ b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample5.md @@ -32,7 +32,7 @@ the module `View2D`. In addition to that, the number of CSOs is displayed in the `CSOIsoGenerator` generates isocontours for each slice at a fixed isovalue. This means that closed CSOs are formed based on the detection of the voxel value of 1200 on every slice. -![Data Objects Contours Example 5](/images/tutorials/dataobjects/contours/DO5_02.png "Data Objects Contours Example 5") +![Data Objects Contours Example 5](images/tutorials/dataobjects/contours/DO5_02.png "Data Objects Contours Example 5") ### Ghosting Now, we like to make CSOs of previous and subsequent slices visible (Ghosting). In @@ -42,7 +42,7 @@ which shows you the number of slices above and below the current slice in which CSOs are also seen in the viewer. The result can be seen in the viewer. -![Ghosting](/images/tutorials/dataobjects/contours/DO5_04.png "Ghosting") +![Ghosting](images/tutorials/dataobjects/contours/DO5_04.png "Ghosting") ### Display Created CSOs At last, we like to make all CSOs visible in a 3D viewer. To do that, @@ -50,7 +50,7 @@ add the modules `SoCSO3DRenderer` and `SoExaminerViewer` to your network and connect them as shown. In the viewer `SoExaminerViewer` you can see all CSOs together. In this case all scanned bones can be seen. -![CSOs in 3D View](/images/tutorials/dataobjects/contours/DO5_05.png "CSOs in 3D View") +![CSOs in 3D View](images/tutorials/dataobjects/contours/DO5_05.png "CSOs in 3D View") ## Summary * `CSOIsoGenerator` enables automatic CSO generation based on an isovalue. diff --git a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample6.md b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample6.md index d7436635d..a481dac56 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample6.md +++ b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample6.md @@ -29,17 +29,17 @@ The first CSO we want to create is a distance line. Add a `SoCSODistanceLineEdit We are going to add some more editors later. In order to have the same look and feel for all types of CSOs, add a `SoCSOVisualizationSettings` module as seen below. The module is used to adjust visual parameters like color and line style for CSOs. Also add a `CSOManager` module to organize CSOs and CSOGroups within a network. -![Initial Network](/images/tutorials/dataobjects/contours/Ex6_1.png "Initial Network") +![Initial Network](images/tutorials/dataobjects/contours/Ex6_1.png "Initial Network") We are now able to create lines in the `View2D`. You can also modify the lines by dragging the seed points to a different location. -![SoCSODistanceLineEditor](/images/tutorials/dataobjects/contours/Ex6_2.png "SoCSODistanceLineEditor") +![SoCSODistanceLineEditor](images/tutorials/dataobjects/contours/Ex6_2.png "SoCSODistanceLineEditor") The created lines do neither provide any details about the length of your measurement, nor a unique ID to identify it in the case of multiple CSOs. Add a `CSOLabelRenderer` module to your network and connect it to a `SoGroup`. Also connect your `SoCSODistanceLineEditor` to the `SoGroup` as seen below. The *ID* of each CSO appears next to your distance lines. Moving the ID also shows the *name* of the contour. -![CSOLabelRenderer](/images/tutorials/dataobjects/contours/Ex6_14.png "CSOLabelRenderer") +![CSOLabelRenderer](images/tutorials/dataobjects/contours/Ex6_14.png "CSOLabelRenderer") We now want to customize the details to be shown for each distance line. Open the panel of the `CSOLabelRenderer`. You can see the two parameters *labelString* and *labelName*. The *labelString* is set to the *ID* of the CSO. The *labelName* is set to a static text and the *label* property of the CSO. The label can be defined in the module `CSOManager`. You can do this, but we are not defining a name for each contour in this example. @@ -55,7 +55,7 @@ deviceOffsetY = 0 We are setting the *labelName* to a static text showing the type of the CSO and the unique *ID* of the contour. We also define the *labelString* to the static description of the measurement and the *length* parameter of the CSO. -![labelString and labelName](/images/tutorials/dataobjects/contours/Example6_5.png "labelString and labelName") +![labelString and labelName](images/tutorials/dataobjects/contours/Example6_5.png "labelString and labelName") You can also round the length by using: {{< highlight filename="CSOLabelRenderer" >}} @@ -66,19 +66,19 @@ labelString = f'Length: {cso.getLength():.2f} mm' In order to see all possible parameters of a CSO, add a `CSOInfo` module to your network and connect it to the `CSOManager`. The geometric information of the selected CSO from `CSOManager` can be seen there. -![CSOInfo](/images/tutorials/dataobjects/contours/Ex6_CSOInfo.png "CSOInfo") +![CSOInfo](images/tutorials/dataobjects/contours/Ex6_CSOInfo.png "CSOInfo") For labels shown on grayscale images, it makes sense to add a shadow. Open the panel of the `SoCSOVisualizationSettings` module and on tab *Misc* check the option *Should render shadow*. This increases the readability of your labels. -{{< imagegallery 2 "/images/tutorials/dataobjects/contours/" "Ex6_NoShadow" "Ex6_Shadow" >}} +{{< imagegallery 2 "images/tutorials/dataobjects/contours/" "Ex6_NoShadow" "Ex6_Shadow" >}} If you want to define your static text as a parameter in multiple labels, you can open the panel of the `CSOLabelRenderer` module and define text as User Data. The values can then be used in Python via *userData*. -![User Data](/images/tutorials/dataobjects/contours/Ex6_Parameters.png "User Data") +![User Data](images/tutorials/dataobjects/contours/Ex6_Parameters.png "User Data") You can also add multiple CSO editors to see the different options. Add the `SoCSORectangleEditor` module to your workspace and connect it to the `SoGroup` module. As we now have two different editors, we need to tell the `CSOLabelRenderer` which CSO is to be rendered. Open the panel of the `SoCSODistanceLineEditor`. You can see the field *Extension Id* set to *distanceLine*. Open the panel of the `SoCSORectangleEditor`. You can see the field *Extension Id* set to *rectangle*. -![Extension ID](/images/tutorials/dataobjects/contours/Ex6_ExtensionID.png "Extension ID") +![Extension ID](images/tutorials/dataobjects/contours/Ex6_ExtensionID.png "Extension ID") We currently defined the *labelName* and *labelString* for the distance line. If we want to define different labels for different types of CSOs, we have to change the `CSOLabelRenderer` Python script. Open the panel of the `CSOLabelRenderer` and change the Python code to the following: @@ -98,19 +98,19 @@ deviceOffsetY = 0 ``` {{}} -![SoCSORectangleEditor](/images/tutorials/dataobjects/contours/Ex6_LineAndRectangle.png "SoCSORectangleEditor") +![SoCSORectangleEditor](images/tutorials/dataobjects/contours/Ex6_LineAndRectangle.png "SoCSORectangleEditor") If you now draw new CSOs, you will notice that you still always create distance lines. Open the panel of the `SoView2DCSOExtensibleEditor`. You can see that the *Creator Extension Id* is set to *__default*. By default, the first found eligible editor is used to create a new CSO. In our case this is the `SoCSODistanceLineEditor`. -![SoCSORectangleEditor](/images/tutorials/dataobjects/contours/Ex6_DefaultExtension.png "SoCSORectangleEditor") +![SoCSORectangleEditor](images/tutorials/dataobjects/contours/Ex6_DefaultExtension.png "SoCSORectangleEditor") Change *Creator Extension Id* to *rectangle*. -![SoCSORectangleEditor & SoView2DCSOExtensibleEditor ](/images/tutorials/dataobjects/contours/Ex6_8.png "SoCSORectangleEditor & SoView2DCSOExtensibleEditor") +![SoCSORectangleEditor & SoView2DCSOExtensibleEditor ](images/tutorials/dataobjects/contours/Ex6_8.png "SoCSORectangleEditor & SoView2DCSOExtensibleEditor") Newly created CSOs are now rectangles. The label values are shown as defined in the `CSOLabelRenderer` and show the length and the area of the rectangle. -![Labeled Rectangle in View2D](/images/tutorials/dataobjects/contours/Ex6_9.png "Labeled Rectangle in View2D") +![Labeled Rectangle in View2D](images/tutorials/dataobjects/contours/Ex6_9.png "Labeled Rectangle in View2D") {{}} The *Length* attribute in the context of rectangles represents the perimeter of the rectangle, calculated as *2a + 2b*, where *a* and *b* are the lengths of the two sides of the rectangle. @@ -118,7 +118,7 @@ The *Length* attribute in the context of rectangles represents the perimeter of You will find a lot more information in the `CSOInfo` module for your rectangles. The exact meaning of the values for each type of CSO is explained in the table below. -![CSOInfo](/images/tutorials/dataobjects/contours/Ex6_10.png "CSOInfo") +![CSOInfo](images/tutorials/dataobjects/contours/Ex6_10.png "CSOInfo") ## Parameters and Meanings for All CSO Types diff --git a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample7.md b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample7.md index ef9d3371f..08e0c0f6e 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample7.md +++ b/mevislab.github.io/content/tutorials/dataobjects/contours/contourexample7.md @@ -20,9 +20,9 @@ menu: In this example, we are using the module `CSOListContainer` instead of the `CSOManager`. The `CSOManager` is a heavyweight, UI driven module. You can use it to see all of your CSOs and CSOGroups in the module panel. The `CSOListContainer` is a lightweight module with focus on Python scripting. We recommend to use this module for final application development, because Python provides much more flexibility in handling CSO objects. -![CSOManager](/images/tutorials/dataobjects/contours/Example_7_1.png "CSOManager") +![CSOManager](images/tutorials/dataobjects/contours/Example_7_1.png "CSOManager") -![CSOListContainer](/images/tutorials/dataobjects/contours/Example_7_2.png "CSOListContainer") +![CSOListContainer](images/tutorials/dataobjects/contours/Example_7_2.png "CSOListContainer") We will create multiple CSOs by using the `SoCSOEllipseEditor` and dynamically add these CSOs to different groups via Python scripting depending on their size. CSOs larger than a configurable threshold will be red, small CSOs will be drawn green. The colors will also be adapted if we manually resize the contours. @@ -33,7 +33,7 @@ Add a `LocalImage` and a `View2D` module to your workspace and connect them as s Add a `SoCSOEllipseEditor` and a `CSOListContainer` to the `SoView2DCSOExtensibleEditor` -![Initial Network](/images/tutorials/dataobjects/contours/Example_7_3.png "Initial Network") +![Initial Network](images/tutorials/dataobjects/contours/Example_7_3.png "Initial Network") You are now able to draw CSOs. @@ -42,11 +42,11 @@ Create a separate directory for this tutorial and save your network in this empt ### Create a Local Macro Module Select the module `CSOListContainer` and open menu {{}}. Enter some details about your new local macro module and click finish. Leave the already defined output as is. -![Create Local Macro](/images/tutorials/dataobjects/contours/Example_7_4.png "Create Local Macro") +![Create Local Macro](images/tutorials/dataobjects/contours/Example_7_4.png "Create Local Macro") The appearance of the `CSOListContainer` module changes, because it is a macro module named `csoList` now. -![Network with new local macro](/images/tutorials/dataobjects/contours/Example_7_5.png "Network with new local macro") +![Network with new local macro](images/tutorials/dataobjects/contours/Example_7_5.png "Network with new local macro") The behavior of your network does not change. You can still draw the same CSOs and they are still managed by the `CSOListContainer` module. The reason why we created a local macro with a single module inside is that we want to add Python scripting to the module. Python scripts can only be added to macro modules. @@ -182,7 +182,7 @@ def _getCSOList(): ``` {{}} -![Final Network](/images/tutorials/dataobjects/contours/Example_7_6.png "Final Network") +![Final Network](images/tutorials/dataobjects/contours/Example_7_6.png "Final Network") If you now draw contours, they are automatically colored depending on the size. You can also edit existing contours and the color is adapted. diff --git a/mevislab.github.io/content/tutorials/dataobjects/curves.md b/mevislab.github.io/content/tutorials/dataobjects/curves.md index 676633432..d73bfb28b 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/curves.md +++ b/mevislab.github.io/content/tutorials/dataobjects/curves.md @@ -16,6 +16,6 @@ menu: ## Introduction Curves can be used in MeVisLab to print the results of a function as two-dimensional mathematical curves into a diagram. -![Curves in MeVisLab](/images/tutorials/dataobjects/curves/Curves.png "Curves in MeVisLab") +![Curves in MeVisLab](images/tutorials/dataobjects/curves/Curves.png "Curves in MeVisLab") In the given example, only modules available in commercial **MeVisLab Professional SDK** have been used. The non-commercial **MeVisLab Standard SDK** provides more modules for curves. \ No newline at end of file diff --git a/mevislab.github.io/content/tutorials/dataobjects/curves/curvesexample1.md b/mevislab.github.io/content/tutorials/dataobjects/curves/curvesexample1.md index fb8ac25fe..f45358f81 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/curves/curvesexample1.md +++ b/mevislab.github.io/content/tutorials/dataobjects/curves/curvesexample1.md @@ -26,15 +26,15 @@ A curve requires x- and y-coordinates to be printed. You can use the `CurveCreat Add the modules to your workspace and connect them as seen below. -![Example Network](/images/tutorials/dataobjects/curves/example_network.png "Example Network") +![Example Network](images/tutorials/dataobjects/curves/example_network.png "Example Network") ### Creating a Curve Click on the output of the CurveCreator and open the Output Inspector. -![Empty Output Inspector](/images/tutorials/dataobjects/curves/OutputInspector_empty.png "Empty Output Inspector") +![Empty Output Inspector](images/tutorials/dataobjects/curves/OutputInspector_empty.png "Empty Output Inspector") Double-click {{}} on the `CurveCreator` module and open the Panel. -![CurveCreator Module](/images/tutorials/dataobjects/curves/CurveCreatorModule.png "CurveCreator Module") +![CurveCreator Module](images/tutorials/dataobjects/curves/CurveCreatorModule.png "CurveCreator Module") You can see a large input field *Curve Table*. Here you can enter the x- and y-values of your curve. The values of the first column will become the x-values and the 2nd any further column will become the y-series. Comment lines start with a '#' character. @@ -55,7 +55,7 @@ Enter the following into the *Curve Table*: Now your *Output Inspector* shows a yellow line through the previously entered coordinates. Exactly the same curve is shown in the `SoRenderArea`. -![SoRenderArea](/images/tutorials/dataobjects/curves/SoRenderArea.png "SoRenderArea") +![SoRenderArea](images/tutorials/dataobjects/curves/SoRenderArea.png "SoRenderArea") ### Creating Multiple Curves Now, update the *Curve Table* so that you are using three columns and click *Update* {{}}: @@ -75,26 +75,26 @@ Now, update the *Curve Table* so that you are using three columns and click *Upd You can see two curves. The second and third columns are printed as separate curves. Both appear yellow. After checking *Split columns into data sets*, you will see one yellow and one red curve. -{{}} +{{}} If the flag *Split columns into data sets* is set to *TRUE*, then a table with more than two columns is split into different *CurveData* objects. This gives the user the possibility to assign a different style and title for each series. ### Titles and Styles Let's do this. Open the panel of the `SoDiagram2D` module and check *Draw legend*. Enter *"Curve1 Curve2"* into the *Title(s)* text box of the `CurveCreator` module and click *Update* {{}}. -![SoRenderArea with Legend](/images/tutorials/dataobjects/curves/SoRenderArea2.png "SoRenderArea with Legend") +![SoRenderArea with Legend](images/tutorials/dataobjects/curves/SoRenderArea2.png "SoRenderArea with Legend") You can also define a different location of the legend and set font sizes. Now open the panel of the `StylePalette` module. -![StylePalette](/images/tutorials/dataobjects/curves/StylePalette.png "StylePalette") +![StylePalette](images/tutorials/dataobjects/curves/StylePalette.png "StylePalette") The `StylePalette` allows you to define twelve different styles for curves. Initially, without manual changes, the styles are applied one after the other. The first curve gets style 1, the second curve style 2, and so on. Open the Panel of your `CurveCreator` again and define *Curve Style(s)* as *"3 6"*. *Update* {{}} your curves. -![StylePalette applied](/images/tutorials/dataobjects/curves/StylePalette_applied.png "StylePalette applied") +![StylePalette applied](images/tutorials/dataobjects/curves/StylePalette_applied.png "StylePalette applied") You now applied the style three for your first curve and six for the second. This is how you can create twelve different curves with unique appearance. @@ -131,10 +131,10 @@ Update the *Curve Table* as defined below and click *Update* {{}} -For more complex visualizations, you can also use Matplotlib. See examples at [Thirdparty - Matplotlib](/tutorials/thirdparty/matplotlib "Thirdparty - Matplotlib"). +For more complex visualizations, you can also use Matplotlib. See examples at [Thirdparty - Matplotlib](tutorials/thirdparty/matplotlib "Thirdparty - Matplotlib"). {{}} ## Summary diff --git a/mevislab.github.io/content/tutorials/dataobjects/markerobjects.md b/mevislab.github.io/content/tutorials/dataobjects/markerobjects.md index fc4064a20..bca9a02c0 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/markerobjects.md +++ b/mevislab.github.io/content/tutorials/dataobjects/markerobjects.md @@ -18,15 +18,15 @@ In MeVisLab you can equip images and other data objects with markers. In this ex ## Creation and Rendering To create markers, you can use a marker editor, for example, the `SoView2DMarkerEditor`. Connect this editor to a viewer as shown below. Now you can interactively create new markers. Connect the module `XMarkerListContainer` to your marker editor to store markers in a list. -![Create Markers](/images/tutorials/dataobjects/markers/DO_Markers_01.png "Create Markers") +![Create Markers](images/tutorials/dataobjects/markers/DO_Markers_01.png "Create Markers") Using the module `StylePalette`, you can define a style for your markers. In order to set different styles for different markers, change the field *Color Mode* in the Panel of `SoView2DMarkerEditor` to *Index*. -![Style of Markers](/images/tutorials/dataobjects/markers/DO_Markers_08.png "Style of Markers") +![Style of Markers](images/tutorials/dataobjects/markers/DO_Markers_08.png "Style of Markers") With the help of the module `So3DMarkerRenderer`, markers of an `XMarkerList` can be rendered. -![Rendering of Markers](/images/tutorials/dataobjects/markers/DO_Markers_09.png "Rendering of Markers") +![Rendering of Markers](images/tutorials/dataobjects/markers/DO_Markers_09.png "Rendering of Markers") ## Working with Markers @@ -41,7 +41,7 @@ Learn how to convert markers by building the following network. Press the *Reloa Make sure to set *Lower Threshold* of the `MaskToMarkers` module to 1000 so that the 3D object is rendered correctly. {{}} -![Convert Markers](/images/tutorials/dataobjects/markers/DO_Markers_02.png "Convert Markers") +![Convert Markers](images/tutorials/dataobjects/markers/DO_Markers_02.png "Convert Markers") ## Exercise Get the HU value of the image at your markers location. diff --git a/mevislab.github.io/content/tutorials/dataobjects/markers/markerexample1.md b/mevislab.github.io/content/tutorials/dataobjects/markers/markerexample1.md index 449a0524f..112aa3aab 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/markers/markerexample1.md +++ b/mevislab.github.io/content/tutorials/dataobjects/markers/markerexample1.md @@ -26,7 +26,7 @@ Add the following modules and connect them as shown. We changed the names of the modules `SoView2DMarkerEditor` and `XMarkerListContainer`, to distinguish these modules from two similar modules we will add later on. Open the panel of `SoView2DMarkerEditor` and select the tab *Drawing*. Now choose the *Color* *red*. -![Marker Color](/images/tutorials/dataobjects/markers/DO_Markers_03.png "Marker Color") +![Marker Color](images/tutorials/dataobjects/markers/DO_Markers_03.png "Marker Color") As a next step, add two more modules: `SoView2DMarkerEditor` and `XMarkerListContainer`. @@ -34,24 +34,24 @@ Change their names and the marker color to *green* and connect them as shown. We In addition to that, we like to allow only one green marker to be present. If we place a new marker, the old marker should vanish. For this, select the *Max Size* to be one and select *Overflow Mode: Remove All*. -![Marker Editor Settings](/images/tutorials/dataobjects/markers/DO_Markers_04.png "Marker Editor Settings") +![Marker Editor Settings](images/tutorials/dataobjects/markers/DO_Markers_04.png "Marker Editor Settings") ### Create Markers of Different Type Now we can place as many red markers as we like, using the left mouse button {{< mousebutton "left" >}} and one green marker using the middle mouse button {{< mousebutton "middle" >}}. -![Two Types of Markers](/images/tutorials/dataobjects/markers/DO_Markers_05.png "Two Types of Markers") +![Two Types of Markers](images/tutorials/dataobjects/markers/DO_Markers_05.png "Two Types of Markers") ### Calculate the Distance Between Markers We like to calculate the minimum and maximum distance of the green marker to all the red markers. In order to do this, add the module `DistanceFromXMarkerList` and connect it to `RedMarkerList`. Open the panels of `DistanceFromXMarkerList` and `GreenMarkerList`. Now, draw a parameter connection from the coordinates of the green marker, which are stored in the field *Current Item -> Position* in the panel of `GreenMarkerList`, to the field *Position* of `DistanceFromXMarkerList`. You can now press *Calculate Distance* in the panel of `DistanceFromXMatkerList` to see the result, meaning the distance of the green marker to all the red markers in the panel of `DistanceFromXMarkerList`. -![Module DistanceFromXMarkerList](/images/tutorials/dataobjects/markers/DO_Markers_06.png "Module DistanceFromXMarkerList") +![Module DistanceFromXMarkerList](images/tutorials/dataobjects/markers/DO_Markers_06.png "Module DistanceFromXMarkerList") ### Automation of Distance Calculation To automatically update the calculation when placing a new marker, we need to tell the module `DistanceFromXMarkerList` **when** a new green marker is placed. Open the panels of `DistanceFromXMarkerList` and `GreenMarker` and draw a parameter connection from the field *Currently busy* in the panel of `GreenMarker` to *Calculate Distance* in the panel of `DistanceFromXMarkerList`. If you now place a new green marker, the distance from the new green marker to all red markers is automatically calculated. -![Calculation of Distance between Markers](/images/tutorials/dataobjects/markers/DO_Markers_07.png "Calculation of Distance between Markers") +![Calculation of Distance between Markers](images/tutorials/dataobjects/markers/DO_Markers_07.png "Calculation of Distance between Markers") {{}} -Another example for using a `SoView2DMarkerEditor` module can be found at [Image Processing - Example 3: Region Growing](/tutorials/image_processing/image_processing3 "Image Processing - Example 3: Region Growing") +Another example for using a `SoView2DMarkerEditor` module can be found at [Image Processing - Example 3: Region Growing](tutorials/image_processing/image_processing3 "Image Processing - Example 3: Region Growing") {{}} ## Summary diff --git a/mevislab.github.io/content/tutorials/dataobjects/surfaceobjects.md b/mevislab.github.io/content/tutorials/dataobjects/surfaceobjects.md index 0815f80c1..af9aed73e 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/surfaceobjects.md +++ b/mevislab.github.io/content/tutorials/dataobjects/surfaceobjects.md @@ -24,31 +24,31 @@ To explain WEMs in MeVisLab, we will build a network that shows the structure an ### Initialize a WEM Add the module `WEMInitialize` to your workspace, open its panel, and select a *Cube*. In general, a WEM is made up of surfaces. Here all surfaces are squares. In MeVisLab it is common to build WEMs out of triangles. -![WEM initializing](/images/tutorials/dataobjects/surfaces/WEM_01_1.png "WEM initializing") +![WEM initializing](images/tutorials/dataobjects/surfaces/WEM_01_1.png "WEM initializing") ### Rendering of WEMs For rendering WEMs, you can use the module `SoWEMRenderer` in combination with the viewer `SoExaminerViewer`. Add both modules to your network and connect them as shown. A background is always a nice feature to have. -![WEM rendering](/images/tutorials/dataobjects/surfaces/WEM_01_2.png "WEM rendering") +![WEM rendering](images/tutorials/dataobjects/surfaces/WEM_01_2.png "WEM rendering") ### Geometry of WEMs The geometry of WEMs is given by different structures. Using specialized WEM renderer modules, all structures can be visualized. #### Edges Add and connect the module `SoWEMRendererEdges` to your workspace to enable the rendering of WEM Edges. Here, we manipulated the line thickness to make the lines of the edges thicker. -![WEM Edges](/images/tutorials/dataobjects/surfaces/WEM_01_3.png "WEM Edges") +![WEM Edges](images/tutorials/dataobjects/surfaces/WEM_01_3.png "WEM Edges") #### Nodes Nodes mark the corner points of each surface. Therefore, nodes define the geometric properties of every WEM. To visualize the nodes, add and connect the module `SoWEMRendererNodes` as shown. By default, the nodes are visualized with an offset to the position they are located in. We reduced the offset to be zero, increased the point size, and changed the color. -![WEM Nodes](/images/tutorials/dataobjects/surfaces/WEM_01_4.png "WEM Nodes") +![WEM Nodes](images/tutorials/dataobjects/surfaces/WEM_01_4.png "WEM Nodes") #### Faces Between the nodes and alongside the edges, surfaces are created. The rendering of these surfaces can be enabled and disabled using the panel of `SoWEMRenderer`. -![WEM Faces](/images/tutorials/dataobjects/surfaces/WEM_01_5.png "WEM Faces") +![WEM Faces](images/tutorials/dataobjects/surfaces/WEM_01_5.png "WEM Faces") #### Normals Normals display the orthogonal vector either to the faces (Face Normals) or to the nodes (Nodes Normals). With the help of the module `SoWEMRendererNormals`, these structures can be visualized. -![WEM normal editor](/images/tutorials/dataobjects/surfaces/WEM_01_6.png "WEM normal editor") +![WEM normal editor](images/tutorials/dataobjects/surfaces/WEM_01_6.png "WEM normal editor") {{< imagegallery 2 "images/tutorials/dataobjects/surfaces/" "WEMNodeNormals" "WEMFaceNormals">}} ### WEMs in MeVisLab {#WEMsInMevislab} diff --git a/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample1.md b/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample1.md index bb0d15d56..57b50009b 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample1.md +++ b/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample1.md @@ -25,12 +25,12 @@ In this example you will learn how to create a Winged Edge Mesh (WEM). There are At first, we will create a WEM out of a voxel image using the module `WEMIsoSurface`. Add and connect the shown modules. Load the image *$(DemoDataPath)/Bone.tiff* and set the *Iso Min. Value* in the panel of `WEMIsoSurface` to 1200. Tick the box *Use image max. value*. The module `WEMIsoSurface` creates surface objects out of all voxels with an isovalue equal or above 1200 (and smaller than the image max value). The module `SoWEMRenderer` can now be used to generate an Open Inventor scene, which can be displayed by the module `SoExaminerViewer`. -![WEM](/images/tutorials/dataobjects/surfaces/DO6_01.png "WEM") +![WEM](images/tutorials/dataobjects/surfaces/DO6_01.png "WEM") ### From Surface to Image: Generating Voxel Images out of WEM It is not only possible to create WEMs out of voxel images. You can also transform WEMs into voxel images: Add and connect the modules `VoxelizeWEM` and `View2D` as shown and press the *Update* button of the module `VoxelizeWEM`. -![WEM](/images/tutorials/dataobjects/surfaces/DO6_02.png "WEM") +![WEM](images/tutorials/dataobjects/surfaces/DO6_02.png "WEM") ### From Contour to Surface: Generating WEMs out of CSOs @@ -38,11 +38,11 @@ Now we like to create WEMs out of CSOs. To create CSOs, load the network from [C Next, add and connect the module `CSOToSurface` to convert CSOs into a surface object. To visualize the created WEM, add and connect the modules `SoWEMRenderer` and `SoExaminerViewer`. -![WEM](/images/tutorials/dataobjects/surfaces/DO6_03.png "WEM") +![WEM](images/tutorials/dataobjects/surfaces/DO6_03.png "WEM") It is also possible to display the WEM in 2D in addition to the original image. In order to do that, add and connect the modules `SoRenderSurfaceIntersection` and `SoView2DScene`. The module `SoRenderSurfaceIntersection` allows to display the voxel image and the created WEM in one viewer using the same coordinates. In its panel, you can choose the color used for visualizing the WEM. The module `SoView2DScene` renders an Open Inventor scene graph into 2D slices. -![WEM](/images/tutorials/dataobjects/surfaces/DO6_04.png "WEM") +![WEM](images/tutorials/dataobjects/surfaces/DO6_04.png "WEM") If you like to transform WEMs back into CSOs, take a look at the module `WEMClipPlaneToCSO`. diff --git a/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample2.md b/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample2.md index de29133fe..e2d2e3a07 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample2.md +++ b/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample2.md @@ -24,43 +24,43 @@ In this example, you will learn how to modify and process WEMs. #### Modification of WEMs Use the module `WEMLoad` to load the file *venus.off*. Then add and connect the shown modules. We like to display the WEM *venus* two times, one time this WEM is modified. You can use the module `WEMModify` to apply modifications. In its panel, change the scale and the size of the WEM. Now you see two times the `venus` next to each other. -![WEMModify](/images/tutorials/dataobjects/surfaces/DO7_01.png "WEMModify") +![WEMModify](images/tutorials/dataobjects/surfaces/DO7_01.png "WEMModify") #### Smoothing of WEMs It is possible to smooth the WEM using the module `WEMSmooth`. Add this module to your network as shown. You can see the difference of the smoothed and the unsmoothed WEM in your viewer. There are more modules that can modify WEMs, for example, `WEMExtrude`. You can find them via search or in {{< menuitem "Modules" "Visualization" "Surface Meshes (WEM)" >}}. -![WEMSmooth](/images/tutorials/dataobjects/surfaces/DO7_02.png "WEMSmooth") +![WEMSmooth](images/tutorials/dataobjects/surfaces/DO7_02.png "WEMSmooth") #### Calculate Distance Between WEMs Now, we like to calculate the distance between our two WEMs. In order to do this, add and connect the module `WEMSurfaceDistance` as shown. -![Calculate surface distance](/images/tutorials/dataobjects/surfaces/DO7_03.png "Calculate surface distance") +![Calculate surface distance](images/tutorials/dataobjects/surfaces/DO7_03.png "Calculate surface distance") #### Annotations in 3D As a last step, we like to draw the calculated distances as annotations into the image. This is a little bit tricky as we need the module `SoView2DAnnotation` to create annotations in a 3D viewer. Add and connect the following modules as shown. What is done here? We use the module `SoView2D` to display a 2D image in the `SoExaminerViewer`, in addition to the WEMs we already see in the viewer. We do not see an additional image in the viewer, as we chose no proper input image to the module `SoView2D` using the module `ConstantImage` with value 0. Thus, we pretend to have a 2D image, which we can annotate. Now, we use the module `SoView2DAnnotation` to annotate the pretended 2D image, displayed in the viewer of `SoExaminerViewer`. We already used the module `SoView2DAnnotation` in [Contour Example 4](tutorials/dataobjects/contours/contourexample4/). In the `SoView2D` module, you need to uncheck the option *Draw image data*. -![Annotation modules](/images/tutorials/dataobjects/surfaces/DO7_05.png "Annotation modules") +![Annotation modules](images/tutorials/dataobjects/surfaces/DO7_05.png "Annotation modules") Now, change the *Annotation Mode* to *User*, as we like to insert custom annotations. In addition, disable to *Show vertical ruler*. -![Select annotation mode](/images/tutorials/dataobjects/surfaces/DO7_06.png "Select annotation mode") +![Select annotation mode](images/tutorials/dataobjects/surfaces/DO7_06.png "Select annotation mode") Next, open the tab *Input* and draw parameter connections from the results of the distance calculations, which can be found in the panel of `WEMSufaceDistance`, to the input fields in the panel of `SoView2DAnnotation`. -![Define annotation parameters](/images/tutorials/dataobjects/surfaces/DO7_07.png "Define annotation parameters") +![Define annotation parameters](images/tutorials/dataobjects/surfaces/DO7_07.png "Define annotation parameters") You can design the annotation overlay as you like in the tab *User*. We decided to only display the minimum and maximum distance between both WEMs. -![Annotation design](/images/tutorials/dataobjects/surfaces/DO7_04.png "Annotation design") +![Annotation design](images/tutorials/dataobjects/surfaces/DO7_04.png "Annotation design") As we use a 2D annotation module to annotate a 3D viewer, it is important to get rid of all 2D orientation annotations, which you can edit in the tab *Orientation*. -![Disable 2D orientation annotations](/images/tutorials/dataobjects/surfaces/DO7_08.png "Disable 2D orientation annotations") +![Disable 2D orientation annotations](images/tutorials/dataobjects/surfaces/DO7_08.png "Disable 2D orientation annotations") Now, you can see the result in the viewer. If the annotations are not visible, press {{< keyboard "a">}} a few times to change the annotation mode. -![Display surface distance in viewer](/images/tutorials/dataobjects/surfaces/DO7_09.png "Display surface distance in viewer") +![Display surface distance in viewer](images/tutorials/dataobjects/surfaces/DO7_09.png "Display surface distance in viewer") ## Summary * There are several modules to modify and process WEMs, e.g., `WEMModify`, `WEMSmooth`. diff --git a/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample3.md b/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample3.md index 431a84da2..4a8310d0b 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample3.md +++ b/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample3.md @@ -26,15 +26,15 @@ We are using a `SoTransformerDragger` module to apply transformations on a 3D WE Add a `SoCube` and a `SoBackground` module and connect both to a `SoExaminerViewer`. For a better understanding, you should also add a `SoCoordinateSystem` module and connect it to the viewer. Change the *User Transform Mode* to *User Transform Instead Of Input* and set *User Scale* to 2 for *x*, *y* and *z*. -![Initial Network](/images/tutorials/dataobjects/surfaces/WEMExample3_1.png "Initial Network") +![Initial Network](images/tutorials/dataobjects/surfaces/WEMExample3_1.png "Initial Network") The `SoExaminerViewer` shows your cube and the world coordinate system. You can interact with the camera (rotate, zoom, and pan), the cube itself does not change and remains in the center of the coordinate system. -![Initial Cube](/images/tutorials/dataobjects/surfaces/WEMExample3_2.png "Initial Cube") +![Initial Cube](images/tutorials/dataobjects/surfaces/WEMExample3_2.png "Initial Cube") Scaling, rotating, and translating the cube itself can be done by using the module `SoTransformerDragger`. Additionally, add a `SoTransform` module to your network. Add all modules but the `SoCoordinateSystem` to a `SoSeparator` so that transformations are not applied to the coordinate system. -![SoTransformerDragger and SoTransform](/images/tutorials/dataobjects/surfaces/WEMExample3_3.png "SoTransformerDragger and SoTransform") +![SoTransformerDragger and SoTransform](images/tutorials/dataobjects/surfaces/WEMExample3_3.png "SoTransformerDragger and SoTransform") Draw parameter connections from *Translation*, *Scale Factor*, and *Rotation* of the `SoTransformerDragger` to the same fields of the `SoTransform` module. @@ -44,7 +44,7 @@ Opening your SoExaminerViewer now allows you to use handles of the `SoTransforme You need to change the active tool on the right side of the `SoExaminerViewer`. Use the *Pick Mode* for applying transformations and the *View Mode* for using the camera. {{}} -![Moved, Rotated and Scaled Cube](/images/tutorials/dataobjects/surfaces/WEMExample3_4.png "Moved, Rotated and Scaled Cube") +![Moved, Rotated and Scaled Cube](images/tutorials/dataobjects/surfaces/WEMExample3_4.png "Moved, Rotated and Scaled Cube") You can also try the other `So*Dragger` modules in MeVisLab for variations of the `SoTransformerDragger`. @@ -55,41 +55,41 @@ We are using the `WEMBulgeEditor` module to interactively modify the WEM via mou Add a `WEMInitialize`, a `SoWEMRenderer`, and a `SoBackground` module to your workspace and connect them to a `SoExaminerViewer` as seen below. Select model *Icosahedron* for the `WEMInitialize` module. -![WEMLoad and SoWEMRenderer](/images/tutorials/dataobjects/surfaces/WEMExample3_5.png "WEMLoad and SoWEMRenderer") +![WEMLoad and SoWEMRenderer](images/tutorials/dataobjects/surfaces/WEMExample3_5.png "WEMLoad and SoWEMRenderer") You can see the WEM and interact with it in the viewer (zoom, move, and rotate). In the case the object does not rotate around its center, trigger the field *viewAll* of the `SoExaminerViewer`. Add a `WEMBulgeEditor` and a `SoWEMBulgeEditor` to your network and connect them as seen below. -![WEMBulgeEditor and SoWEMBulgeEditor](/images/tutorials/dataobjects/surfaces/WEMExample3_6.png "WEMBulgeEditor and SoWEMBulgeEditor") +![WEMBulgeEditor and SoWEMBulgeEditor](images/tutorials/dataobjects/surfaces/WEMExample3_6.png "WEMBulgeEditor and SoWEMBulgeEditor") Opening the viewer, you can still not edit the object. We need a lookup table (LUT) to interact with the WEM. Add a `WEMGenerateStatistics` between the WEMInitialize and the WEMBulgeEditor. The module `WEMGenerateStatistics` generates node, edge, and face statistics of a WEM and stores the information in the WEM's Primitive Value Lists. {{}} -More information about Primitive Value Lists (PVL) can be found in [Surface Example 5](/tutorials/dataobjects/surfaces/surfaceexample5). +More information about Primitive Value Lists (PVL) can be found in [Surface Example 5](tutorials/dataobjects/surfaces/surfaceexample5). {{}} Check *New node PVL* and set *New PVL Name* to *myPVL*. -![WEMGenerateStatistics](/images/tutorials/dataobjects/surfaces/WEMExample3_7.png "WEMGenerateStatistics") +![WEMGenerateStatistics](images/tutorials/dataobjects/surfaces/WEMExample3_7.png "WEMGenerateStatistics") In the `WEMBulgeEditor`, set *PVL Used as LUT Values* to previously generated *myPVL*. -![WEMBulgeEditor PVL](/images/tutorials/dataobjects/surfaces/WEMExample3_8.png "WEMBulgeEditor PVL") +![WEMBulgeEditor PVL](images/tutorials/dataobjects/surfaces/WEMExample3_8.png "WEMBulgeEditor PVL") Add a `SoLUTEditor` and connect it to `SoWEMRenderer`. You also have to connect the `WEMGenerateStatistics` to the `SoWEMRenderer`. Set `SoWEMRenderer` *Color Mode* to *Lut Values* and select *PVL Used as LUT Values* to *myPVL*. -![Final Network](/images/tutorials/dataobjects/surfaces/WEMExample3_10.png "Final Network") +![Final Network](images/tutorials/dataobjects/surfaces/WEMExample3_10.png "Final Network") Open the panel of the `SoLUTEditor`. Configure *New Range Min* as -1 and *New Range Max* as 1 in *Range* tab. Apply the new range. Define the LUT as seen below in *Editor* tab. -![SoLUTEditor](/images/tutorials/dataobjects/surfaces/WEMExample3_9.png "SoLUTEditor") +![SoLUTEditor](images/tutorials/dataobjects/surfaces/WEMExample3_9.png "SoLUTEditor") Now your Primitive Value List is used to colorize the affected region for your tansformations. You can see the region by the color on hovering the mouse over the WEM. -![Affected region colored](/images/tutorials/dataobjects/surfaces/Affected_Region.png "Affected region colored") +![Affected region colored](images/tutorials/dataobjects/surfaces/Affected_Region.png "Affected region colored") The size of the region can be changed via {{}} and mouse wheel {{< mousebutton "middle" >}}. Make sure that the *Influence Radius* in `WEMBulgeEditor` is larger than 0. @@ -97,13 +97,13 @@ The size of the region can be changed via {{}} and mouse wheel You need to change the active tool on the right side of the `SoExaminerViewer`. Use the *Pick Mode* for applying transformations and the *View Mode* for using the camera. {{}} -![Modify WEM](/images/tutorials/dataobjects/surfaces/Modify.png "Modify WEM") +![Modify WEM](images/tutorials/dataobjects/surfaces/Modify.png "Modify WEM") {{< networkfile "examples/data_objects/surface_objects/example3/WEMExample3b.mlab" >}} A much more complex example using medical images and allowing to modify in 3D and on 2D slices can be seen by opening the example network of the `WEMBulgeEditor`. -![WEMBulgeEditor Example Network](/images/tutorials/dataobjects/surfaces/WEMExample3_11.png "WEMBulgeEditor Example Network") +![WEMBulgeEditor Example Network](images/tutorials/dataobjects/surfaces/WEMExample3_11.png "WEMBulgeEditor Example Network") {{}} For other interaction possibilities, you can play around with the example networks of the modules `SoCSODrawOnSurface`, `SoVolumeCutting` and `WEMExtrude`. diff --git a/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample4.md b/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample4.md index 00074ee13..6bfe60690 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample4.md +++ b/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample4.md @@ -28,7 +28,7 @@ Add and connect the following modules as shown. On the panel of the module `WEMI * `SoMITranslate1Dragger`: This module allows interactive translation of the object alongside one axis. You can select the axis for translation in the panel of the module. * `SoMIDraggerContainer`: This module is responsible for actually changing the translation values of the object. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_01.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_01.png "Interactive dragging of objects") ### Interactively Translating a WEM Alongside Three Axes We like to be able to interactively move a WEM alongside all three axes. In MeVisLab, there is the module `SoMITranslate2Dragger`, which allows translations alongside two axis, but there is no module which allows object translation in all three directions. Therefore, we will create a network that solves this task. The next steps will show you how you create three planes intersecting the objects. Dragging one plane, will drag the object alongside one axis. In addition, these planes will only be visible when hovering over them. @@ -36,41 +36,41 @@ We like to be able to interactively move a WEM alongside all three axes. In MeVi #### Creation of Planes Intersecting an Object We start creating a plane that will allow dragging in x-direction. In order to do that, modify your network as shown: Add the modules `WEMModify`, and `SoBackground` and connect the module `SoCube` to the dragger modules. You can select the translation direction in the panel of `SoMITranslate1Dragger`. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_02.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_02.png "Interactive dragging of objects") We will modify the cube to be able to use it as a dragger plane. In order to do this, open the panel of `SoCube` and reduce the *Width* to be 0. This sets a plane in y- and z-direction. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_02_1.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_02_1.png "Interactive dragging of objects") We want to move the object when dragging the plane. Thus, we need to modify the translation of our object when moving the plane. Open the panels of the modules `WEMModify` and `SoMIDraggerContainer` and draw a parameter connection from one *Translation* vector to the other. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_03.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_03.png "Interactive dragging of objects") As a next step, we want to adapt the size of the plane to the size of the object we have. Add the modules `WEMInfo` and `DecomposeVector3` to your workspace and open their panels. The module `WEMInfo` presents information about the given WEM, for example, its position and size. The module `DecomposeVector3` splits a 3D vector into its components. Now, draw a parameter connection from *Size* of `WEMInfo` to the vector in `DecomposeVector3`. As a next step, open the panel of `SoCube` and draw parameter connections from the fields *Y* and *Z* of `DecomposeVector3` to *Height* and *Depth* of `SoCube`. Now, the size of the plane adapts to the size of the object. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_04.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_04.png "Interactive dragging of objects") The result can be seen in the next image. You can now select the plane in the *Interaction Mode* of the module `SoExaminerViewer` and move the plane together with the object alongside the x-axis. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_05.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_05.png "Interactive dragging of objects") #### Modifying the Appearance of the Plane For changing the visualization of the dragger plane, add the modules `SoGroup`, `SoSwitch`, and `SoMaterial` to your network and connect them as shown. In addition, group together all the modules that are responsible for the translation in the x-direction. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_06.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_06.png "Interactive dragging of objects") We want to switch the visualization of the plane dependent on the mouse position in the viewer. In other words, when hovering over the plane, the plane should be visible, when the mouse is in another position and the possibility to drag the object is not given, the plane should be invisible. We use the module `SoMaterial` to edit the appearance of the plane. Open the panel of the module `SoMITranslate1Dragger`. The box of the field *Highlighted* is ticked when the mouse hovers over the plane. Thus, we can use the field's status to switch between different presentations of the plane. In order to do this, open the panel of `SoSwitch` and draw a parameter connection from *Highlighted* of `SoMITranslate1Dragger` to *Which Child* of `SoSwitch`. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_06_02.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_06_02.png "Interactive dragging of objects") Open the panels of the modules `SoMaterial`. Change the *Transparency* of the first `SoMaterial` module to make the plane invisible when not hovering over the plane. Furthermore, we changed the *Diffuse Color* of the module `SoMaterial1` to red, so that the plane appears in red when hovering over it. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_07.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_07.png "Interactive dragging of objects") When hovering over the plane, the plane becomes visible and the option to move the object alongside the x-axis is given. When you do not hover over the plane, the plane is invisible. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_08.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_08.png "Interactive dragging of objects") #### Interactive Object Translation in Three Dimensions @@ -78,35 +78,35 @@ We do not only want to move the object in one direction, we like to be able to d We need to change the size of `SoCube1` and `SoCube2` to form planes that cover surfaces in x- and z-, as well as x- and y-directions. To do that, draw the respective parameter connections from `DecomposeVector3` to the fields of the modules `SoCube`. In addition, we need to adapt the field *Direction* in the panels of the modules `SoMITranslate1Dragger`. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_09.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_09.png "Interactive dragging of objects") Change width, height, and depth of the three cubes so that each of them represents one plane. The values need to be set to (0, 2, 2), (2, 0, 2) and (2, 2, 0). As a next step, we like to make sure that all planes always intersect the object, even though the object is moved. To do this, we need to synchronize the field *Translation* of all `SoMIDraggerContainer` modules and the module `WEMModify`. Draw parameter connections from one *Translation* field to the next, as shown below. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_10.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_10.png "Interactive dragging of objects") We like to close the loop, so that a change in one field *Translation* causes a change in all the other *Translation* fields. To do this, we need to include the module `SyncVector`. The module `SyncVector` avoids an infinite processing loop causing a permanent update of all fields *Translation*. Add the module `SyncVector` to your workspace and open its panel. Draw a parameter connection from the field *Translation* of the module `SoMIDraggerContainer2` to *Vector1* of `SyncVector`. The field *Vector1* is automatically synchronized to the field *Vector2*. Now, connect the field *Vector2* to the field *Translate* of the module `WEMModify`. Your synchronization network is now established. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_11.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_11.png "Interactive dragging of objects") To enable transformations in all directions, we need to connect the modules `SoMIDraggerContainer` to the viewer. First, connect the modules to `SoGroup`, after that connect `SoGroup` to `SoExaminerViewr`. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_12.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_12.png "Interactive dragging of objects") As a next step, we like to enlarge the planes to make them exceed the object. For that, add the module `CalculateVectorFromVectors` to your network. Open its panel and connect the field *Size* of `WEMInfo` to *Vector 1*. We like to enlarge the size by one, so we add the vector (1,1,1), by editing the field *Vector 2*. Now, connect the *Result* to the field *V* of the module `DecomposeVector3`. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_13.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_13.png "Interactive dragging of objects") At last, we can condense all the modules enabling the transformation into one local macro module. For that, group all the modules together and convert the group into a macro module as shown in [Chapter I: Basic Mechanisms](tutorials/basicmechanisms#TutorialMacroModules). -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_14.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_14.png "Interactive dragging of objects") The result can be seen in the next image. This module can now be used for interactive 3D transformations for all kinds of WEMs. -![Interactive dragging of objects](/images/tutorials/dataobjects/surfaces/DO10_15.png "Interactive dragging of objects") +![Interactive dragging of objects](images/tutorials/dataobjects/surfaces/DO10_15.png "Interactive dragging of objects") ## Summary diff --git a/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample5.md b/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample5.md index 553a40542..26c00ad12 100644 --- a/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample5.md +++ b/mevislab.github.io/content/tutorials/dataobjects/surfaces/surfaceexample5.md @@ -26,12 +26,12 @@ In this example we like to use PVLs to color-code and visualize the distance bet We start our network by initializing two WEMs using `WEMInitialize`. We chose an *Octasphere* and a resized *Cube*. Use the modules `SoWEMRenderer`, `SoExaminerViewer`, and `SoBackground` to visualize the WEMs. -![WEMInitialize](/images/tutorials/dataobjects/surfaces/DO12_01.png "WEMInitialize") +![WEMInitialize](images/tutorials/dataobjects/surfaces/DO12_01.png "WEMInitialize") #### Subdividing WEM Edges As a next step, add and connect two modules `WEMSubdivide` to further divide edges and surfaces. With this step we increase the node density to have an accurate distance measurement. -![WEMSubdivide](/images/tutorials/dataobjects/surfaces/DO12_02.png "WEMSubdivide") +![WEMSubdivide](images/tutorials/dataobjects/surfaces/DO12_02.png "WEMSubdivide") The difference when selecting different maximum edge lengths can be seen in the following images. @@ -40,45 +40,45 @@ The difference when selecting different maximum edge lengths can be seen in the #### Distances Between WEMs are Stored in PVLs Now, add the modules `WEMSurfaceDistance` and `WEMInfo` to your workspace and connect them as shown. `WEMSurfaceDistance` calculates the minimum distance between the nodes of both WEM. The distances are stored in the nodes' PVLs as LUT values. -![Distances between surfaces](/images/tutorials/dataobjects/surfaces/DO12_05.png "Distances between surfaces") +![Distances between surfaces](images/tutorials/dataobjects/surfaces/DO12_05.png "Distances between surfaces") Open the panels of the modules `WEMSurfaceDistance` and `WEMInfo`. In the panel of `WEMInfo` select the tab *Statistics*. You can see the statistics of the stored PVLs. The *Minimum Value* and the *Maximum Value* are similar to the calculated *Min Dist.* and *Max. Dist.* of `WEMSurfaceDistance`. -![WEM information](/images/tutorials/dataobjects/surfaces/DO12_06.png "WEM information") +![WEM information](images/tutorials/dataobjects/surfaces/DO12_06.png "WEM information") #### Color-coding the Distance Between WEMs What can we do with this information? We can use the calculated distances, stored in LUT values, to color-code the distance between the WEMs. For this, add and connect the module `SoLUTEditor`. Each LUT value from the PVLs will in the next step be translated into a color. But first, open the panel of `SoWEMRenderer` to select the *Color Mode* *LUT Values*. Now, the module `SoLUTEditor` defines the coloring of the WEM. -![SoWEMRenderer](/images/tutorials/dataobjects/surfaces/DO12_07.png "SoWEMRenderer") +![SoWEMRenderer](images/tutorials/dataobjects/surfaces/DO12_07.png "SoWEMRenderer") To translate the LUT values from the PVLs into color, open the panel of `SoLUTEditor` and select the tab *Range*. We need to define the value range we like to work with. As the distance and thus the PVL value is expected to be 0 when the surfaces of both WEMs meet, we set the *New Range Min* to 0. As the size of the WEMs does not exceed 3, we set the *New Range Max* to 3. After that, press *Apply New Range*. -![SoLUTEditor](/images/tutorials/dataobjects/surfaces/DO12_08.png "SoLUTEditor") +![SoLUTEditor](images/tutorials/dataobjects/surfaces/DO12_08.png "SoLUTEditor") Our goal is to colorize faces of the *Octasphere* in red if they are close to or even intersect the cubic WEM. And we like to colorize faces of the *Octasphere* in green if these faces are far away from the cubic WEM. Open the tab *Editor* of the panel of `SoLUTEditor`. This tab allows to interactively select a color for each PVL value. Select the color point on the left side. Its *Position* value is supposed to be 0, so we like to select the *Color* *red* in order to color-code small distances between the WEMs in red. In addition to that, increase the *Opacity* of this color point. Next, select the right color point. Its *Position* is supposed to be 3 and thus equals the value of the field *New Range Max*. As these color points colorize large distances between WEMs, select the *Color* *green*. You can add new color points by clicking on the colorized bar in the panel. Select, for example, the *Color* *yellow* for a color point in the middle. Select and shift the color points to get the desired visualization. -![Changing the LUT](/images/tutorials/dataobjects/surfaces/DO12_09.png "Changing the LUT") +![Changing the LUT](images/tutorials/dataobjects/surfaces/DO12_09.png "Changing the LUT") Add the module `WEMModify` to your workspace and connect the module as shown. If you now shift the WEM using `WEMModify`, you can see that the colorization adapts. -![WEMModify](/images/tutorials/dataobjects/surfaces/DO12_10.png "WEMModify") +![WEMModify](images/tutorials/dataobjects/surfaces/DO12_10.png "WEMModify") ### Interactive Shift of WEMs As a next step, we like to implement the interactive shift of the WEM. Add the modules `SoTranslateDragger1` and `SyncVector`. Connect all translation vectors: Draw connections from the field *Translate* of `SoTranslateDragger1` to *Vector1* of `SyncVector`, from *Vector2* of `SyncVector` to *Translate* of `WEMModify`, and at last from *Translate* of `WEMModify` to *Translate* of `SoTranslateDragger1`. You can now interactively drag the WEM inside the viewer. -![Dragging the WEM](/images/tutorials/dataobjects/surfaces/DO12_11.png "Dragging the WEM") +![Dragging the WEM](images/tutorials/dataobjects/surfaces/DO12_11.png "Dragging the WEM") At last, exchange the `WEMInitialize` module showing the cube with `WEMLoad` and load *venus.off*. You can decrease the *Face Alpha* in the panel of `SoWEMRenderer1` to make that WEM transparent. -![WEM transparency](/images/tutorials/dataobjects/surfaces/DO12_12.png "WEM transparency") +![WEM transparency](images/tutorials/dataobjects/surfaces/DO12_12.png "WEM transparency") The result can be seen in the next image. -![Your final result](/images/tutorials/dataobjects/surfaces/DO12_13.png "Your final result") +![Your final result](images/tutorials/dataobjects/surfaces/DO12_13.png "Your final result") ## Summary * Additional information of WEMs can be stored in *Primitive Value Lists* (PVL), attached to nodes, edges, or faces. diff --git a/mevislab.github.io/content/tutorials/image_processing/image_processing1.md b/mevislab.github.io/content/tutorials/image_processing/image_processing1.md index 91e17880e..aca69710f 100644 --- a/mevislab.github.io/content/tutorials/image_processing/image_processing1.md +++ b/mevislab.github.io/content/tutorials/image_processing/image_processing1.md @@ -26,18 +26,18 @@ Add two `LocalImage` modules to your workspace for the input images. Select *$(D In the end, add the `Arithmetic2` module and connect them as seen below. -![Example Network](/images/tutorials/image_processing/network_example1.png "Example Network") +![Example Network](images/tutorials/image_processing/network_example1.png "Example Network") Your `SynchroView2D` shows two images. On the left hand side, you can see the original image from your left `LocalImage` module. The right image shows the result of the arithmetic operation performed by the `Arithmetic2` module on the two input images. -![SynchroView2D](/images/tutorials/image_processing/arithmetic_viewer.png "SynchroView2D") +![SynchroView2D](images/tutorials/image_processing/arithmetic_viewer.png "SynchroView2D") The `SynchroView2D` module automatically synchronizes the visible slice of both input images; you can see the same slice with and without applied filter. ## Arithmetic Operations Double-click {{< mousebutton "left" >}} the `Arithmetic2` module to select different functions to be applied. -![Arithmetic2](/images/tutorials/image_processing/arithmetic2.png "Arithmetic2") +![Arithmetic2](images/tutorials/image_processing/arithmetic2.png "Arithmetic2") The selected function is applied automatically. diff --git a/mevislab.github.io/content/tutorials/image_processing/image_processing2.md b/mevislab.github.io/content/tutorials/image_processing/image_processing2.md index 1e1bc83d9..5c4ec4810 100644 --- a/mevislab.github.io/content/tutorials/image_processing/image_processing2.md +++ b/mevislab.github.io/content/tutorials/image_processing/image_processing2.md @@ -28,33 +28,33 @@ Image masking is a very good way to select a defined region where image processi ### Develop Your Network Add a `LocalImage` and a `SynchroView2D` module to your network and connect the modules as seen below. -![Example Network](/images/tutorials/image_processing/network_example2a.png "Example Network") +![Example Network](images/tutorials/image_processing/network_example2a.png "Example Network") Open the Automatic Panel of the `SynchroView2D` module via context menu {{< mousebutton "right" >}} and selecting {{< menuitem "Show Window" "Automatic Panel" >}}. Set the field *synchLUTs* to *TRUE*. -![Synchronize LUTs in SynchroView2D](/images/tutorials/image_processing/synchLUTs.png "Synchronize LUTs in SynchroView2D") +![Synchronize LUTs in SynchroView2D](images/tutorials/image_processing/synchLUTs.png "Synchronize LUTs in SynchroView2D") Double-click the `SynchroView2D` and change window/level values via right mouse button {{< mousebutton "right" >}}. You can see that the background of your images gets very bright and changes based on the LUT are applied to all voxels of your input image - even on the background. Hovering your mouse over the image(s) shows the current gray value under your cursor in [Hounsfield Unit (HU)](https://en.wikipedia.org/wiki/Hounsfield_scale). -![Without masking the image](/images/tutorials/image_processing/SynchroView2D_before.png "Without masking the image") +![Without masking the image](images/tutorials/image_processing/SynchroView2D_before.png "Without masking the image") Hovering the mouse over black background voxels shows a value between 0 and about 60. This means we want to create a mask that only allows modifications on voxels having a gray value larger than 60. Add a `Mask` and a `Threshold` module to your workspace and connect them as seen below. -![Example Network](/images/tutorials/image_processing/network_example2b.png "Example Network") +![Example Network](images/tutorials/image_processing/network_example2b.png "Example Network") Changing the window/level values in your viewer still also changes background voxels. The `Threshold` module still leaves the voxels as is because the threshold value is configured as larger than 0. Open the Automatic Panel of the modules `Threshold` and `Mask` via double-click {{< mousebutton "left" >}} and set the values as seen below. -{{< imagegallery 2 "/images/tutorials/image_processing" "Threshold" "Mask">}} +{{< imagegallery 2 "images/tutorials/image_processing" "Threshold" "Mask">}} Now all voxels having a HU value lower or equal 60 are set to 0, all others are set to 1. The resulting image from the `Threshold` module is a binary image that can now be used as a mask by the `Mask` module. -![Output of the Threshold module](/images/tutorials/image_processing/OutputInspector_Threshold.png "Output of the Threshold module") +![Output of the Threshold module](images/tutorials/image_processing/OutputInspector_Threshold.png "Output of the Threshold module") The `Mask` module is configured to use the *Masked Original* image. Changing the window/level values in your images now, you can see that the background voxels are not affected anymore (at least as long as you do not reach a very large value). -![After masking the image](/images/tutorials/image_processing/SynchroView2D_after.png "After masking the image") +![After masking the image](images/tutorials/image_processing/SynchroView2D_after.png "After masking the image") ## Summary * The module `Threshold` applies a relative or an absolute threshold to a voxel image. It can be defined what should be written to those voxels that pass or fail the adjustable comparison. diff --git a/mevislab.github.io/content/tutorials/image_processing/image_processing3.md b/mevislab.github.io/content/tutorials/image_processing/image_processing3.md index 099e69bca..e2c189c61 100644 --- a/mevislab.github.io/content/tutorials/image_processing/image_processing3.md +++ b/mevislab.github.io/content/tutorials/image_processing/image_processing3.md @@ -26,16 +26,16 @@ In this example, you will segment the brain of an image and show the segmentatio ### Develop Your Network Add a `LocalImage` module to your workspace and select load *$(DemoDataPath)/BrainMultiModal/ProbandT1.dcm*. Add a `View2D` module and connect both as seen below. -![Example Network](/images/tutorials/image_processing/network_example3.png "Example Network") +![Example Network](images/tutorials/image_processing/network_example3.png "Example Network") ### Add the RegionGrowing Module Add the `RegionGrowing` module and connect the input with the `LocalImage` module. You will see a message *results invalid*. The reason is that a region growing always needs a starting point for getting similar voxels. The output of the module does not show a result in *Output Inspector*. -![Results Invalid](/images/tutorials/image_processing/network_example3a.png "Results Invalid") +![Results Invalid](images/tutorials/image_processing/network_example3a.png "Results Invalid") Add a `SoView2DMarkerEditor` to your network and connect it with your `RegionGrowing` and with the `View2D`. Clicking into your viewer now creates markers that can be used for the region growing. -![SoView2DMarkerEditor](/images/tutorials/image_processing/SoView2DMarkerEditor.png "SoView2DMarkerEditor") +![SoView2DMarkerEditor](images/tutorials/image_processing/SoView2DMarkerEditor.png "SoView2DMarkerEditor") The region growing starts on manually clicking *Update* or automatically if *Update Mode* is set to *Auto-Update*. We recommend to set update mode to automatic update. Additionally, you should set the *Neighborhood Relation* to *3D-6-Neighborhood (x,y,z)*, because then your segmentation will also affect the z-axis. @@ -45,15 +45,15 @@ Set *Threshold Computation* to *Automatic* and define *Interval Size* as 1.600 % For more information, see {{< docuLinks "/Standard/Documentation/Publish/ModuleReference/RegionGrowing.html" "MeVisLab Module Reference" >}} {{}} -![Auto-Update for RegionGrowing](/images/tutorials/image_processing/RegionGrowing_AutoUpdate.png "Auto-Update for RegionGrowing") +![Auto-Update for RegionGrowing](images/tutorials/image_processing/RegionGrowing_AutoUpdate.png "Auto-Update for RegionGrowing") Clicking into your image in the `View2D` now already generates a mask containing your segmentation. As you did not connect the output of the `RegionGrowing`, you need to select the output of the module and use the *Output Inspector* to visualize your results. -![Output Inspector Preview](/images/tutorials/image_processing/OutputInspector.png "Output Inspector Preview") +![Output Inspector Preview](images/tutorials/image_processing/OutputInspector.png "Output Inspector Preview") In order to visualize your segmentation mask as an overlay in the `View2D`, you need to add the `SoView2DOverlay` module. Connect it as seen below. -![SoView2DOverlay](/images/tutorials/image_processing/network_example3b.png "SoView2DOverlay") +![SoView2DOverlay](images/tutorials/image_processing/network_example3b.png "SoView2DOverlay") Your segmentation is now shown in the `View2D`. You can change the color and transparency of the overlay via SoView2DOverlay. @@ -62,18 +62,18 @@ Scrolling through the slices, you will see that your segmentation is not closed. The difference before and after closing the gaps can be seen in the Output Inspector. -{{< imagegallery 2 "/images/tutorials/image_processing" "Output_Before" "Output_After">}} +{{< imagegallery 2 "images/tutorials/image_processing" "Output_Before" "Output_After">}} You can play around with the different settings of the `RegionGrowing` and `CloseGap` modules to get a better result. ### Visualize 2D and 3D You can now also add a `View3D` to show your segmentation in 3D. Your final result should look similar to this. -![Final Result](/images/tutorials/image_processing/network_example3c.png "Final Result") +![Final Result](images/tutorials/image_processing/network_example3c.png "Final Result") ## Summary * The module `RegionGrowing` allows a very simple segmentation of similar gray values. * Gaps in a segmentation mask can be closed by using the `CloseGap` module. * Segmentation results can be visualized in 2D and 3D. -{{< networkfile "/examples/image_processing/example3/RegionGrowingExample.mlab" >}} \ No newline at end of file +{{< networkfile "examples/image_processing/example3/RegionGrowingExample.mlab" >}} \ No newline at end of file diff --git a/mevislab.github.io/content/tutorials/image_processing/image_processing4.md b/mevislab.github.io/content/tutorials/image_processing/image_processing4.md index f9a42ee39..155ca005f 100644 --- a/mevislab.github.io/content/tutorials/image_processing/image_processing4.md +++ b/mevislab.github.io/content/tutorials/image_processing/image_processing4.md @@ -24,30 +24,30 @@ In this example, we load an image and render it as `WEMIsoSurface`. Then, we cre ### Develop Your Network Add a `LocalImage` module to your workspace and select load *$(DemoDataPath)/BrainMultiModal/ProbandT1.dcm*. Add a `WEMIsoSurface`, a `SoWEMRenderer`, a `SoBackground`, and a `SoExaminerViewer` module and connect them as seen below. Make sure to configure the `WEMIsoSurface` to use a *Iso Min. Value* of 420 and a *Voxel Sampling* 1. -![Example Network](/images/tutorials/image_processing/network_example4.png "Example Network") +![Example Network](images/tutorials/image_processing/network_example4.png "Example Network") The `SoExaminerViewer` now shows the head as a three-dimensional rendering. -![SoExaminerViewer](/images/tutorials/image_processing/SoExaminerViewer_initial.png "SoExaminerViewer") +![SoExaminerViewer](images/tutorials/image_processing/SoExaminerViewer_initial.png "SoExaminerViewer") ### Add a 3D Sphere to your Scene We now want to add a three-dimensional sphere to our scene. Add a `SoMaterial` and a `SoSphere` to your network, connect them to a `SoSeparator` and then to the `SoExaminerViewer`. Set your material to use a *Diffuse Color* red and adapt the size of the sphere to *Radius* 50. -![Example Network](/images/tutorials/image_processing/network_example4b.png "Example Network") +![Example Network](images/tutorials/image_processing/network_example4b.png "Example Network") The `SoExaminerViewer` now shows the head and the red sphere inside. -![SoExaminerViewer](/images/tutorials/image_processing/SoExaminerViewer_sphere.png "SoExaminerViewer") +![SoExaminerViewer](images/tutorials/image_processing/SoExaminerViewer_sphere.png "SoExaminerViewer") ### Set Location of your Sphere In order to define the best possible location of the sphere, we additionally add a `SoTranslation` module and connect it to the `SoSeparator` between the material and the sphere. Define a translation of x=0, y=20 and z=80. -![Example Network](/images/tutorials/image_processing/network_example4c.png "Example Network") +![Example Network](images/tutorials/image_processing/network_example4c.png "Example Network") ### Subtract the Sphere from the Head We now want to subtract the sphere from the head to get a hole. Add another `SoWEMRenderer`, a `WEMLevelSetBoolean`, and a `SoWEMConvertInventor` to the network and connect them to a `SoSwitch` as seen below. The `SoSwitch` also needs to be connected to the `SoWEMRenderer` of the head. Set your `WEMLevelSetBoolean` to use the *Mode* **Difference**. -![Example Network](/images/tutorials/image_processing/network_example4d.png "Example Network") +![Example Network](images/tutorials/image_processing/network_example4d.png "Example Network") What happens in your network now? @@ -57,7 +57,7 @@ What happens in your network now? 4) Both `SoWEMRenderer` (the head on the left side and the subtraction on the right side) are inputs for a `SoSwitch`. 5) The `SoSwitch` toggles through its inputs and you can show the original WEM of the head or the subtraction. -{{< imagegallery 2 "/images/tutorials/image_processing" "SoExaminerViewer_1" "SoExaminerViewer_2" >}} +{{< imagegallery 2 "images/tutorials/image_processing" "SoExaminerViewer_1" "SoExaminerViewer_2" >}} You can now toggle the hole to be shown or not, depending on your setting for the `SoSwitch`. @@ -65,4 +65,4 @@ You can now toggle the hole to be shown or not, depending on your setting for th * The module `WEMLevelSetBoolean` allows to subtract or add three-dimensional WEM objects. * The `SoSwitch` can toggle multiple Open Inventor scenes as input. -{{< networkfile "/examples/image_processing/example4/Subtract3DObjects.mlab" >}} \ No newline at end of file +{{< networkfile "examples/image_processing/example4/Subtract3DObjects.mlab" >}} \ No newline at end of file diff --git a/mevislab.github.io/content/tutorials/image_processing/image_processing5.md b/mevislab.github.io/content/tutorials/image_processing/image_processing5.md index ad54976ea..4e94dd08e 100644 --- a/mevislab.github.io/content/tutorials/image_processing/image_processing5.md +++ b/mevislab.github.io/content/tutorials/image_processing/image_processing5.md @@ -26,7 +26,7 @@ First we need to develop the network to scroll through the slices. Add a `LocalI Add the modules `OrthoReformat3`, `Switch`, `SoView2D`, `View2DExtensions`, and `SoRenderArea` and connect them as seen below. -![Example Network](/images/tutorials/image_processing/network_example5.png "Example Network") +![Example Network](images/tutorials/image_processing/network_example5.png "Example Network") In previous tutorials, we already learned that it is possible to show 2D slices in a `SoRenderArea`. For scrolling through the slices, a `View3DExtensions` module is necessary. In this network, we also have a `OrthoReformat3` module. It allows us to transform the input image (by rotating and/or flipping) into the three main views commonly used: * Axial @@ -37,43 +37,43 @@ The `Switch` module takes multiple input images and you can toggle between them The `SoRenderArea` now shows the 2D images in a view defined by the `Switch`. -{{< imagegallery 3 "/images/tutorials/image_processing" "View0" "View1" "View2" >}} +{{< imagegallery 3 "images/tutorials/image_processing" "View0" "View1" "View2" >}} ### Current 2D Slice in 3D We now want to visualize the slice visible in the 2D images as a 3D plane. Add a `SoGVRDrawOnPlane` and a `SoExaminerViewer` to your workspace and connect them. We should also add a `SoBackground` and a `SoLUTEditor`. The viewer remains empty because no source image is selected to display. Add a `SoGVRVolumeRenderer` and connect it to your viewer and the `LocalImage`. -![Example Network](/images/tutorials/image_processing/network_example5b.png "Example Network") +![Example Network](images/tutorials/image_processing/network_example5b.png "Example Network") A three-dimensional plane of the image is shown. Adapt the LUT as seen below. -![SoLUTEditor](/images/tutorials/image_processing/tutorial5_lut.png "SoLUTEditor") +![SoLUTEditor](images/tutorials/image_processing/tutorial5_lut.png "SoLUTEditor") We now have a single slice of the image in 3D, but the slice is static and cannot be changed. In order to use the currently visible slice from the 2D viewer, we need to create a parameter connection from the `SoView2D` position *Slice as plane* to the `SoGVRDrawOnPlane` plane vector. -![SoView2D Position](/images/tutorials/image_processing/SoView2D_Position.png "SoView2D Position") +![SoView2D Position](images/tutorials/image_processing/SoView2D_Position.png "SoView2D Position") -![SoGVRDrawOnPlane Plane](/images/tutorials/image_processing/SoGVRDrawOnPlane_Plane.png "SoGVRDrawOnPlane Plane") +![SoGVRDrawOnPlane Plane](images/tutorials/image_processing/SoGVRDrawOnPlane_Plane.png "SoGVRDrawOnPlane Plane") Now, the plane representation of the visible slice is synchronized to the plane of the 3D view. Scrolling through your 2D slices changes the plane in 3D. -![Visible slice in 3D](/images/tutorials/image_processing/2DSlice_3D.png "Visible slice in 3D") +![Visible slice in 3D](images/tutorials/image_processing/2DSlice_3D.png "Visible slice in 3D") ### Current 2D Slice as Clip Plane in 3D This slice shall now be used as a clip plane in 3D. In order to achieve this, you need another `SoExaminerViewer` and a `SoClipPlane`. Add them to your workspace and connect them as seen below. You can also use the same `SoLUTEditor` and `SoBackground` for the 3D view. Also use the same `SoGVRVolumeRenderer`; the 3D volume does not change. -![Example Network](/images/tutorials/image_processing/network_example5c.png "Example Network") +![Example Network](images/tutorials/image_processing/network_example5c.png "Example Network") Now your 3D scene shows a three-dimensional volume cut by a plane in the middle. Once again, the clipping is not the same slice as your 2D view shows. -![Clip plane in 3D](/images/tutorials/image_processing/3D_ClipPlane.png "Clip plane in 3D") +![Clip plane in 3D](images/tutorials/image_processing/3D_ClipPlane.png "Clip plane in 3D") Again create a parameter connection from the `SoView2D` position *Slice as plane*, but this time to the `SoClipPlane`. -![SoClipPlane Plane](/images/tutorials/image_processing/SoClipPlane_Plane.png "SoClipPlane Plane") +![SoClipPlane Plane](images/tutorials/image_processing/SoClipPlane_Plane.png "SoClipPlane Plane") If you now open all three viewers and scroll through the slices in 2D, the 3D viewers are both synchronized with the current slice. You can even toggle the view in the `Switch` and the plane is adapted automatically. -![Final 3 views](/images/tutorials/image_processing/Final3Views.png "Final 3 views") +![Final 3 views](images/tutorials/image_processing/Final3Views.png "Final 3 views") ## Summary * The module `OthoReformat3` transforms input images to the three viewing directions: coronal, axial, and sagittal. @@ -81,4 +81,4 @@ If you now open all three viewers and scroll through the slices in 2D, the 3D vi * The `SoGVRDrawOnPlane` module renders a single slice as a three-dimensional plane. * Three-dimensional clip planes on volumes can be created by using a `SoClipPlane` module. -{{< networkfile "/examples/image_processing/example5/ImageProcessingExample5.mlab" >}} \ No newline at end of file +{{< networkfile "examples/image_processing/example5/ImageProcessingExample5.mlab" >}} \ No newline at end of file diff --git a/mevislab.github.io/content/tutorials/image_processing/image_processing6.md b/mevislab.github.io/content/tutorials/image_processing/image_processing6.md index 01f461ab3..4e049e5b9 100644 --- a/mevislab.github.io/content/tutorials/image_processing/image_processing6.md +++ b/mevislab.github.io/content/tutorials/image_processing/image_processing6.md @@ -49,7 +49,7 @@ Add the module `DicomImport` to your workspace. Then click {{< mousebutton "left" >}} Browse and select the new folder named *DICOM_FILES* where you copied the content of the ZIP file earlier. Click Import {{< mousebutton "left" >}}. You can see the result after import below: -![DICOM RT Data in DicomImport module](/images/tutorials/image_processing/Example6_1.png "DICOM RT Data in DicomImport module") +![DICOM RT Data in DicomImport module](images/tutorials/image_processing/Example6_1.png "DICOM RT Data in DicomImport module") The dataset contains an anonymized patient with four series: * RTPLAN \ @@ -61,7 +61,7 @@ In order to see the images, add a `View2D` module and connect it to the `DicomIm The *RTPLAN* and *RTSTRUCT* files do not contain pixel data. Therefore, the `DicomImport` module informs that there is no image data available. The *CT* series contains the original CT data and the *RTDOSE* series contains a mask providing three-dimensional dose data. -{{< imagegallery 4 "/images/tutorials/image_processing/" "RTPLAN" "RTSTRUCT" "CT512" "RTDOSE">}} +{{< imagegallery 4 "images/tutorials/image_processing/" "RTPLAN" "RTSTRUCT" "CT512" "RTDOSE">}} Select the *CT 512×512×272×1* series. @@ -69,7 +69,7 @@ We now want to view the CT images and the *RTSTRUCT* data together. The module ` You have to select the correct index for the *RTSTRUCT*. In our example it is index 2. -![RTSTRUCT in DicomImportExtraOutput](/images/tutorials/image_processing/Example6_2.png "RTSTRUCT in DicomImportExtraOutput") +![RTSTRUCT in DicomImportExtraOutput](images/tutorials/image_processing/Example6_2.png "RTSTRUCT in DicomImportExtraOutput") ### Visualize RTSTRUCTs as Colored CSOs @@ -77,19 +77,19 @@ Add an `ExtractRTStruct` module to the `DicomImportExtraOutput` to convert *RTST A preview of the resulting CSOs can be seen in the *Output Inspector*. -![ExtractRTStruct in Output Inspector](/images/tutorials/image_processing/Example6_3.png "ExtractRTStruct in Output Inspector") +![ExtractRTStruct in Output Inspector](images/tutorials/image_processing/Example6_3.png "ExtractRTStruct in Output Inspector") Add a `SoView2DCSOExtensibleEditor` module to enable visualization and interaction with the CSOs in the 2D viewer. -![SoView2DCSOExtensibleEditor](/images/tutorials/image_processing/Example6_4.png "SoView2DCSOExtensibleEditor") +![SoView2DCSOExtensibleEditor](images/tutorials/image_processing/Example6_4.png "SoView2DCSOExtensibleEditor") We want to display the names for the contours available in the *RTSTRUCT* file to identify the segmented structure. Use the `CSOLabelRenderer` module to show labels (e.g., 'Bladder', 'Prostate') next to each contour. -![CSOLabelRenderer](/images/tutorials/image_processing/Example6_5.png " CSOLabelRenderer") +![CSOLabelRenderer](images/tutorials/image_processing/Example6_5.png " CSOLabelRenderer") By default, the ID of the contours is rendered. Open the panel of the `CSOLabelRenderer` and change the *labelString* parameter as seen below. -![CSOLabelRenderer labelString](/images/tutorials/image_processing/Example6_6.png "CSOLabelRenderer labelString") +![CSOLabelRenderer labelString](images/tutorials/image_processing/Example6_6.png "CSOLabelRenderer labelString") {{< highlight >}} ```Python @@ -101,14 +101,14 @@ Then press apply {{< mousebutton "left" >}}. The name of the structure is define The module `CSOLabelPlacementGlobal` implements an automatic label placement strategy that considers all CSOs on a slice. -![Edited CSOLabelRenderer Panel](/images/tutorials/image_processing/Example6_7.png " Edited CSOLabelRenderer Panel") +![Edited CSOLabelRenderer Panel](images/tutorials/image_processing/Example6_7.png " Edited CSOLabelRenderer Panel") ### 3D Visualization of Contours Using `SoExaminerViewer` The contours can also be shown in 3D. Add a `SoCSO3DRenderer` and a `SoExaminerViewer` module and connect them to the `ExtractRTStruct` module. The `SoCSO3DRenderer` will render the contours (CSOs) into the `SoExaminerViewer`. -![CSOs in 3D](/images/tutorials/image_processing/Example6_8.png "CSOs in 3D") +![CSOs in 3D](images/tutorials/image_processing/Example6_8.png "CSOs in 3D") ### Visualizing RTDOSE as a Colored Overlay We now want to show the *RTDOSE* data as provided for the patient as a semi-transparent, colored overlay. @@ -117,7 +117,7 @@ Add another `DicomImportExtraOutput` module to get the *RTDOSE* object. Again, s Add a `MinMaxScan` module to scan the input image and calculate the minimum and maximum values of the image. Connect it with the `DicomImportExtraOutput` module. -![MinMaxScan](/images/tutorials/image_processing/Example6_9.png "MinMaxScan") +![MinMaxScan](images/tutorials/image_processing/Example6_9.png "MinMaxScan") Add a `Histogram` and a `SoLUTEditor` module to calculate the image's intensity distribution and define a colored lookup table for the overlay. @@ -125,19 +125,19 @@ Change update mode of the `Histogram` module to *Auto Update*. Open the panel of the `SoLUTEditor` module and go to tab *Range*. Click {{< mousebutton "left" >}} *Update Range From Histogram* to apply the histogram values for the *Range* of the lookup table. -![Lookup table and Histogram](/images/tutorials/image_processing/Example6_10.png "Lookup table and Histogram") +![Lookup table and Histogram](images/tutorials/image_processing/Example6_10.png "Lookup table and Histogram") On tab *Editor*, define a lookup table as seen below. -![Lookup table](/images/tutorials/image_processing/Example6_11.png "Lookup table") +![Lookup table](images/tutorials/image_processing/Example6_11.png "Lookup table") The lookup table shall be used for showing the RT Dose data as a semi-transparent overlay on the CT image. Add a `SoView2DOverlay` and a `SoGroup` module to your network. Replace the input of the View2D module from the `SoView2DCSOExtensibleEditor` with the `SoGroup`. -![RT Dose data using SoView2DOverlay](/images/tutorials/image_processing/Example6_12.png "RT Dose data using SoView2DOverlay") +![RT Dose data using SoView2DOverlay](images/tutorials/image_processing/Example6_12.png "RT Dose data using SoView2DOverlay") If you want to visualize the RT Struct contours together with the RT Dose overlay, connect the `SoView2DCSOExtensibleEditor` module and the `SoGroup` module. -![RT Dose and RT Struct](/images/tutorials/image_processing/Example6_13.png "RT Dose and RT Struct") +![RT Dose and RT Struct](images/tutorials/image_processing/Example6_13.png "RT Dose and RT Struct") ## Summary * DICOM RT data can be loaded and processed in MeVisLab. diff --git a/mevislab.github.io/content/tutorials/openinventor.md b/mevislab.github.io/content/tutorials/openinventor.md index d27f4ea05..5766f1234 100644 --- a/mevislab.github.io/content/tutorials/openinventor.md +++ b/mevislab.github.io/content/tutorials/openinventor.md @@ -31,13 +31,13 @@ Inventor scenes are organized in structures called scene graphs. A scene graph i {{}} The model below depicts the order in which the modules are executed. The red arrow indicates the traversal order: from top to bottom and from left to right. The modules are numbered accordingly, from 1 to 8. Knowing about the traversal order can be crucial to achieve a certain ouput. -![Traversing in Open Inventor](/images/tutorials/openinventor/OI1_13.png "Traversing through a network of Open Inventor modules") +![Traversing in Open Inventor](images/tutorials/openinventor/OI1_13.png "Traversing through a network of Open Inventor modules") {{}} ## SoGroup and SoSeparator The `SoGroup` and `SoSeparator` modules can be used as containers for child nodes. They both allow multiple inputs and combine the results in one single output as seen above. Nevertheless, there is a big difference in handling the traversal state of the scene graph. -![SoGroup vs. SoSeparator](/images/tutorials/openinventor/SoGroup_SoSeparator.png "SoGroup vs. SoSeparator") +![SoGroup vs. SoSeparator](images/tutorials/openinventor/SoGroup_SoSeparator.png "SoGroup vs. SoSeparator") In the network above, we render four `SoCone` objects. The left side uses the `SoSeparator` modules, the right side uses the `SoGroup` ones. There is a `SoMaterial` module defining one of the left cone objects to be yellow. As you can see, the `SoMaterial` module is only applied to that cone, the other left cone remains in its default gray color, because the `SoSeparator` module isolates the separator's children from the rest of the scene graph. diff --git a/mevislab.github.io/content/tutorials/openinventor/camerainteraction.md b/mevislab.github.io/content/tutorials/openinventor/camerainteraction.md index 6f6caa981..48408307c 100644 --- a/mevislab.github.io/content/tutorials/openinventor/camerainteraction.md +++ b/mevislab.github.io/content/tutorials/openinventor/camerainteraction.md @@ -25,27 +25,27 @@ The module `SoRenderArea` is a simple renderer for Open Inventor scenes. It offe Add a `SoBackground`, a `SoMaterial` and a `SoOrientationModel` module to your workspace and connect them to a `SoGroup`. Add a `SoRenderArea` to the `SoGroup` and open the viewer. -![SoRenderArea without camera and lights](/images/tutorials/openinventor/Camera_1.png "SoRenderArea without camera and lights") +![SoRenderArea without camera and lights](images/tutorials/openinventor/Camera_1.png "SoRenderArea without camera and lights") You can not interact with your scene and the rendered content is very dark. Open the `SoOrientationModel` and change *Model* to *Skeleton* to see that a little better. You can also change the material by using the panel of the `SoMaterial` module. Add a `SoCameraInteraction` module and connect it between the `SoGroup` and the `SoRenderArea`. -![SoRenderArea with SoCameraInteraction](/images/tutorials/openinventor/Camera_2.png "SoRenderArea with SoCameraInteraction") +![SoRenderArea with SoCameraInteraction](images/tutorials/openinventor/Camera_2.png "SoRenderArea with SoCameraInteraction") The `SoCameraInteraction` does not only allow you to change the camera position in your scene but also adds light. The module automatically adds a headlight you can switch off in the fields of the module. -{{< imagegallery 2 "/images/tutorials/openinventor" "Headlight_TRUE" "Headlight_FALSE" >}} +{{< imagegallery 2 "images/tutorials/openinventor" "Headlight_TRUE" "Headlight_FALSE" >}} The `SoCameraInteraction` can also be extended by a `SoPerspectiveCamera` or a `SoOrthographicCamera`. Add a `SoSwitch` to your `SoGroup` and connect a `SoPerspectiveCamera` and a `SoOrthographicCamera`. -![SoPerspectiveCamera and SoOrthographicCamera](/images/tutorials/openinventor/Camera_3.png "SoPerspectiveCamera and SoOrthographicCamera") +![SoPerspectiveCamera and SoOrthographicCamera](images/tutorials/openinventor/Camera_3.png "SoPerspectiveCamera and SoOrthographicCamera") You can now switch between both cameras, but you can not interact with them in the viewer. Select the `SoCameraInteraction` and toggle *detectCamera*. Now the default camera of the `SoCameraInteraction` is replaced by the camera selected in the `SoSwitch`. Whenever you change the camera in the switch, you need to detect the new camera in the `SoCameraInteraction`. -{{< imagegallery 2 "/images/tutorials/openinventor" "SoPerspectiveCamera" "SoOrthographicCamera" >}} +{{< imagegallery 2 "images/tutorials/openinventor" "SoPerspectiveCamera" "SoOrthographicCamera" >}} A `SoPerspectiveCamera` camera defines a perspective projection from a viewpoint. @@ -59,7 +59,7 @@ By default, the camera is located at (0,0,1) and looks along the negative z-axis Add a `SoCameraWidget` and connect it to your `SoGroup`. -![SoCameraWidget](/images/tutorials/openinventor/Camera_3.png "SoCameraWidget") +![SoCameraWidget](images/tutorials/openinventor/Camera_3.png "SoCameraWidget") This module shows a simple widget on an Inventor viewer that can be used to rotate, pan, or zoom the scene. You can configure the *Main Interaction* in the panel of the `SoCameraWidget`. @@ -70,13 +70,13 @@ The `SoExaminerViewer` makes some things much easier, because a camera and a lig Add a `SoExaminerViewer` to your workspace and connect it to the `SoBackground`, the `SoMaterial` and the `SoOrientationModel` modules. -![SoExaminerViewer](/images/tutorials/openinventor/Camera_4.png "SoExaminerViewer") +![SoExaminerViewer](images/tutorials/openinventor/Camera_4.png "SoExaminerViewer") The difference to the `SoRenderArea` can be seen immediately. You can interact with your scene and a light is available initially. The module also allows you to switch between perspective and orthographic camera by changing the field *cameraType*. -{{< imagegallery 2 "/images/tutorials/openinventor" "SoExaminerViewer_Perspective" "SoExaminerViewer_Orthographic" >}} +{{< imagegallery 2 "images/tutorials/openinventor" "SoExaminerViewer_Perspective" "SoExaminerViewer_Orthographic" >}} The module also provides UI elements to interact. diff --git a/mevislab.github.io/content/tutorials/openinventor/mouseinteractions.md b/mevislab.github.io/content/tutorials/openinventor/mouseinteractions.md index 682595051..44bc3141f 100644 --- a/mevislab.github.io/content/tutorials/openinventor/mouseinteractions.md +++ b/mevislab.github.io/content/tutorials/openinventor/mouseinteractions.md @@ -29,7 +29,7 @@ Additional information about the `SoMouseGrabber` can be found here: {{< docuLin [//]: <> (MVL-653) -![SoMouseGrabber](/images/tutorials/openinventor/V5_01.png "SoMouseGrabber") +![SoMouseGrabber](images/tutorials/openinventor/V5_01.png "SoMouseGrabber") ### Configure mouse interactions Now, open the panels of the module `SoMouseGrabber` and the module `SoExaminerViewer`, which displays a cube. In the Viewer, press the right key of your mouse {{< mousebutton "right" >}} and move the mouse around. This action can be seen in the panel of the module SoMouseGrabber. @@ -37,19 +37,19 @@ Now, open the panels of the module `SoMouseGrabber` and the module `SoExaminerVi Make sure to configure `SoMouseGrabber` fields as seen below. {{}} -![SoMouseGrabber](/images/tutorials/openinventor/V5_02.png "SoMouseGrabber") +![SoMouseGrabber](images/tutorials/openinventor/V5_02.png "SoMouseGrabber") **You can see:** 1. *Button 3*, the right mouse button {{< mousebutton "right" >}}, is tagged as being pressed 2. Changes of the mouse coordinates are displayed in the box *Output*. -![Mouse Interactions](/images/tutorials/openinventor/V5_03.png "Mouse Interactions") +![Mouse Interactions](images/tutorials/openinventor/V5_03.png "Mouse Interactions") ### Resize cube via mouse interactions We like to use the detected mouse-movements to change the size of our cube. In order to that, open the panel of `SoCube`. Build parameter connections from the mouse coordinates to the width and depth of the cube. -![Change Cube size by Mouse Events](/images/tutorials/openinventor/V5_04.png "Change Cube size by Mouse Events") +![Change Cube size by Mouse Events](images/tutorials/openinventor/V5_04.png "Change Cube size by Mouse Events") If you now press the right mouse key {{< mousebutton "right" >}} inside the Viewer and move the mouse around, the size of the cube changes. diff --git a/mevislab.github.io/content/tutorials/openinventor/openinventorobjects.md b/mevislab.github.io/content/tutorials/openinventor/openinventorobjects.md index 104373c70..e28e9a871 100644 --- a/mevislab.github.io/content/tutorials/openinventor/openinventorobjects.md +++ b/mevislab.github.io/content/tutorials/openinventor/openinventorobjects.md @@ -25,52 +25,52 @@ In this example we like to construct an Open Inventor scene in which we display First, add the modules `SoExaminerViewer` and `SoCone` to the workspace and connect both modules as shown. The module `SoCone` creates a cone shaped object, which can be displayed in the Viewer `SoExaminerViewer`. -![SoExaminerViewer](/images/tutorials/openinventor/OI1_01.png "SoExaminerViewer") +![SoExaminerViewer](images/tutorials/openinventor/OI1_01.png "SoExaminerViewer") We like to change the color of the cone. In order to do so, add the module `SoMaterial` to the workspace and connect the module as shown below. When creating an Open Inventor scene (by creating networks of Open Inventor modules), the sequence of module connections, in this case the sequence of the inputs to the module `SoExaminerViewer` determines the functionality of the network. Open Inventor modules are executed like scene graphs. This means, modules are executed from top to bottom and from left to right. Here, it is important to connect the module `SoMaterial` to an input on the left side of the connection between `SoCone` and `SoExaminerViewer`. With this, we first select features like a color and these features are then assigned to all objects, which were executed afterwards. Now, open the panel of the module `SoMaterial` and select any *Diffuse Color* you like. Here, we choose green. -![Colors and Material in Open Inventor](/images/tutorials/openinventor/OI1_02.png "Colors and Material in Open Inventor") +![Colors and Material in Open Inventor](images/tutorials/openinventor/OI1_02.png "Colors and Material in Open Inventor") We like to add a second object to the scene. In order to do that, add the module `SoSphere` to the workspace. Connect this module to `SoExaminerViewer`. When connecting `SoSphere` to an input on the right side of the connection between the viewer and the module `SoMaterial`, the sphere is also colored in green. One problem now is, that currently both objects are displayed at the same position. -![Adding a SoSphere](/images/tutorials/openinventor/OI1_03.png "Adding a SoSphere") +![Adding a SoSphere](images/tutorials/openinventor/OI1_03.png "Adding a SoSphere") They display both objects at different positions, add the modules `SoSeparator` and `SoTransform` to the scene and connect both modules shown on the following picture. Open the panel of `SoTransform` and implement a translation in x-direction to shift the object. Now you can examine two things: 1. The sphere loses its green color 2. The cone is shifted to the side -![Transformation](/images/tutorials/openinventor/OI1_05.png "Transformation") +![Transformation](images/tutorials/openinventor/OI1_05.png "Transformation") The module `SoTransform` is responsible for shifting objects, in this case the cone, to the side. The module `SoSeparator` ensures that only the cone is shifted and also only the cone is colored in green. It separates this features from the rest of the scene. We like to add a third object, a cube, and shift it to the other side of the sphere. Add the modules `SoCube` and `SoTransform` to the workspace and connect both modules as shown below. To shift the cube to the other side of the sphere, open the panel of `SoTransform` and adjust the Translation in x direction. The sphere is not affected by the translation, as the connection from `SoTransform1` to `SoExaminerViewer` is established on the right side of the connection between `SoSphere` and `SoExaminerViewer`. -![Adding a SoCube](/images/tutorials/openinventor/OI1_07.png "Adding a SoCube") +![Adding a SoCube](images/tutorials/openinventor/OI1_07.png "Adding a SoCube") Again, we use the module `SoMaterial` to select a color for the cone and the sphere. -![Multiple Materials](/images/tutorials/openinventor/OI1_08.png "Multiple Materials") +![Multiple Materials](images/tutorials/openinventor/OI1_08.png "Multiple Materials") For easier handling we group an object together with its features by using the module `SoGroup`. This does not separate features, which is the reason for the cube to be colorized. All modules that are derived from `SoGroup` offer a basically infinite number of input connectors (a new connector is added for every new connection). -![SoGroup](/images/tutorials/openinventor/OI1_09.png "SoGroup") +![SoGroup](images/tutorials/openinventor/OI1_09.png "SoGroup") If we do not want to colorize the cube, we have to exchange the module `SoGroup` by another `SoSeparator` module. -![SoSeparator](/images/tutorials/openinventor/OI1_10.png "SoSeparator") +![SoSeparator](images/tutorials/openinventor/OI1_10.png "SoSeparator") The implementation of all objects can be grouped together. -![Grouping](/images/tutorials/openinventor/OI1_11.png "Grouping") +![Grouping](images/tutorials/openinventor/OI1_11.png "Grouping") In addition to the objects, a background can be added to the scene using the module `SoBackground`. -![SoBackground](/images/tutorials/openinventor/OI1_12.png "SoBackground") +![SoBackground](images/tutorials/openinventor/OI1_12.png "SoBackground") ## Summary * Scene objects are represented by nodes. diff --git a/mevislab.github.io/content/tutorials/openinventor/posteffectsinopeninventor.md b/mevislab.github.io/content/tutorials/openinventor/posteffectsinopeninventor.md index f1cd4a432..9028da984 100644 --- a/mevislab.github.io/content/tutorials/openinventor/posteffectsinopeninventor.md +++ b/mevislab.github.io/content/tutorials/openinventor/posteffectsinopeninventor.md @@ -22,13 +22,13 @@ In this tutorial, we will go over the steps to add shadows to our 3D-objects, ma ### From DICOM to scene object -To incorporate DICOMs into your Open Inventor Scene, they have to be rendered as Open Inventor objects, which can be done by converting them into [WEMs](/glossary/#winged-edge-meshes) first. Begin by adding the modules `LocalImage`, `WEMIsoSurface` and `SoWEMRenderer` to your workspace. Open the panel of the `LocalImage` module, browse your files and choose a DICOM with multiple frames as input data. Connect the `LocalImage` module's output connector to `WEMIsoSurface` module's input connector to create a WEM of the study's surface. Then connect the `WEMIsoSurface` module's output connector to the `SoWEMRenderer` module's input connector to render a scene object, that can be displayed by adding a `SoExaminerViewer` module to the workspace and connecting the `SoWEMRenderer` module's output connector to its input connector. +To incorporate DICOMs into your Open Inventor Scene, they have to be rendered as Open Inventor objects, which can be done by converting them into [WEMs](glossary/#winged-edge-meshes) first. Begin by adding the modules `LocalImage`, `WEMIsoSurface` and `SoWEMRenderer` to your workspace. Open the panel of the `LocalImage` module, browse your files and choose a DICOM with multiple frames as input data. Connect the `LocalImage` module's output connector to `WEMIsoSurface` module's input connector to create a WEM of the study's surface. Then connect the `WEMIsoSurface` module's output connector to the `SoWEMRenderer` module's input connector to render a scene object, that can be displayed by adding a `SoExaminerViewer` module to the workspace and connecting the `SoWEMRenderer` module's output connector to its input connector. {{}} We don't recommend using single frame DICOMs for this example as a certain depth is required to interact with the scene objects as intended. Also make sure that the pixel data of the DICOM file you choose contains all slices of the study, as it might be difficult to arrange scene objects of individual slices to resemble the originally captured study. {{}} -![From DICOM to SO](/images/tutorials/openinventor/multiframetoso.PNG "How to create a scene object out of a multi-frame DICOM") +![From DICOM to SO](images/tutorials/openinventor/multiframetoso.PNG "How to create a scene object out of a multi-frame DICOM") {{}} Consider adding a `View2D` and an `Info` module to your `LocalImage` module's output connector to be able to compare the rendered object with the original image and adapt the ISO values to minimize noise. @@ -38,8 +38,8 @@ Consider adding a `View2D` and an `Info` module to your `LocalImage` module's ou To apply shading to our DICOM scene object, add a `SoShaderPipeline` and a `SoShaderPipelineCellShading` module to our network and connect their output connectors to a `SoToggle` module's input connector. Then connect the `SoToggle` module's output connector to the `SoExaminerViewer`, but on the left side of the connection to the `SoWEMRenderer` module. This way, shading can be toggled and is applied to all scene objects connected to the right of the `SoToggle` module's connection. -![Shading toggled off](/images/tutorials/openinventor/shadingtoggled1.PNG "Shading toggled off") -![Shading toggled on](/images/tutorials/openinventor/shadingtoggledon1.PNG "Shading toggled on") +![Shading toggled off](images/tutorials/openinventor/shadingtoggled1.PNG "Shading toggled off") +![Shading toggled on](images/tutorials/openinventor/shadingtoggledon1.PNG "Shading toggled on") ### Tidying your workspace and preparing the next steps @@ -51,7 +51,7 @@ Structuring the workspace by grouping modules based on their functionality helps Use a `SoPostEffectMainGeometry` module to connect both of the groups you just created to the `SoExaminerViewer` module. Lastly, add a `SoPostEffectRenderer` module to your workspace and connect its output connector to the `SoExaminerViewer` module's input connector. -![Grouped](/images/tutorials/openinventor/GroupedModules.PNG "Grouped modules") +![Grouped](images/tutorials/openinventor/GroupedModules.PNG "Grouped modules") You can now change your Open Inventor scene's background color. @@ -60,9 +60,9 @@ You can now change your Open Inventor scene's background color. Add the module `SoPostEffectEdges` to your workspace and connect its output connector with the `SoExaminerViewer` module's input connector. Then open its panel and choose a color. You can try different modes, sampling distances and thresholds: -![Colored Edges](/images/tutorials/openinventor/Edges1.PNG "Colored edges") -![Colored Edges 2](/images/tutorials/openinventor/Edges2.PNG "Varying settings of colored edges") -![Colored Edges 3](/images/tutorials/openinventor/Edges3.PNG "Varying settings of colored edges") +![Colored Edges](images/tutorials/openinventor/Edges1.PNG "Colored edges") +![Colored Edges 2](images/tutorials/openinventor/Edges2.PNG "Varying settings of colored edges") +![Colored Edges 3](images/tutorials/openinventor/Edges3.PNG "Varying settings of colored edges") ### PostEffectGeometry @@ -72,13 +72,13 @@ To include geometrical objects in your Open Inventor scene, add two `SoSeparator You'll observe that the transparency setting in the `SoMaterial` module does not apply to the geometrical objects. Add a `SoPostEffectTransparentGeometry` module to your workspace, connect its output connector to the `SoExaminerViewer` module's input connector and its input connectors to the `SoSeparator` module's output connector to create transparent geometrical objects in your scene. {{}} - ![Workspace](/images/tutorials/openinventor/WorkspaceAndNetwork.PNG "Workspace") + ![Workspace](images/tutorials/openinventor/WorkspaceAndNetwork.PNG "Workspace") ### PostEffectGlow To put a soft glow on the geometrical scene objects, the module `SoPostEffectGlow` can be added to the workspace. -![Glow](/images/tutorials/openinventor/WorkspaceWithGlow.PNG "Applied SoPostEffectGlow") +![Glow](images/tutorials/openinventor/WorkspaceWithGlow.PNG "Applied SoPostEffectGlow") ## Summary * Multi-frame DICOM images can be rendered to be scene objects by converting them into WEMs first diff --git a/mevislab.github.io/content/tutorials/shorts.md b/mevislab.github.io/content/tutorials/shorts.md index ab0a76635..fc4fbbdbc 100644 --- a/mevislab.github.io/content/tutorials/shorts.md +++ b/mevislab.github.io/content/tutorials/shorts.md @@ -17,12 +17,12 @@ menu: This chapter shows some features and functionalities that are helpful but do not provide its own tutorial. -* [Keyboard Shortcuts](/tutorials/shorts#shortcuts) -* [Using Snippets](/tutorials/shorts#snippets) -* [Scripting Assistant](/tutorials/shorts#scriptingassistant) -* [User Scripts](/tutorials/shorts#user_scripts) -* [Show status of module in- and output](/tutorials/shorts#mlimagestate) -* [Module suggestion of module in- and output](/tutorials/shorts#modulesuggest) +* [Keyboard Shortcuts](tutorials/shorts#shortcuts) +* [Using Snippets](tutorials/shorts#snippets) +* [Scripting Assistant](tutorials/shorts#scriptingassistant) +* [User Scripts](tutorials/shorts#user_scripts) +* [Show status of module in- and output](tutorials/shorts#mlimagestate) +* [Module suggestion of module in- and output](tutorials/shorts#modulesuggest) ## Keyboard Shortcuts {#shortcuts} This is a collection of useful keyboard shortcuts in MeVisLab. @@ -93,7 +93,7 @@ This is a collection of useful keyboard shortcuts in MeVisLab. Sometimes you have to create the same network over and over again -- for example, to quickly preview DICOM files. Generally, you will at least add one module to load and another module to display your images. Sometimes you may also want to view the DICOM header data. A network you possibly generate whenever opening DICOM files will be the following: -![Open DICOM files](/images/tutorials/Snippets_Network.png "Open DICOM files") +![Open DICOM files](images/tutorials/Snippets_Network.png "Open DICOM files") Create a snippet of your commonly used networks by adding the snippets list from the main menu. Open {{< menuitem "View" "Views" "Snippets List">}}. A new panel is shown. Select all modules of your network and double-click *New...* in your *Snippets List*. @@ -101,7 +101,7 @@ Enter a name for your snippet like *DICOM Viewer* and click *Add*. A new snippet will be shown in your Snippets List. You can drag and drop the snippet to your workspace and the modules are re-used, including all defined field values. -![Snippets List](/images/tutorials/Snippets_Panel.png "Snippets List") +![Snippets List](images/tutorials/Snippets_Panel.png "Snippets List") ## Scripting Assistant {#scriptingassistant} @@ -113,7 +113,7 @@ Open {{< menuitem "View" "Views" "Scripting Assistant">}}. A new panel is shown. If you now interact with a network, module, or macro module, your user interactions are converted into Python calls. You can see the calls in the panel of the Scripting Assistant and copy and paste them for your Python script. -![Scripting Assistant](/images/tutorials/ScriptingAssistant_Panel.png "Scripting Assistant") +![Scripting Assistant](images/tutorials/ScriptingAssistant_Panel.png "Scripting Assistant") ## User Scripts {#user_scripts} @@ -179,19 +179,19 @@ Switch back to the MeVisLab IDE and select the menu item {{< menuitem "Extras" " Especially in large networks it is useful to see the state of the input and output connectors of a module. By default, the module connectors do not show if data is available. Below image shows a `DicomImport` module and a `View2D` module where no data is loaded. -![No status on connector](/images/tutorials/LMIMageState_Off.png "No status on connector") +![No status on connector](images/tutorials/LMIMageState_Off.png "No status on connector") In the MeVisLab preferences dialog, you can see a checkbox *Show ML image state*. By default, the setting is *Off*. -![Show ML image state](/images/tutorials/LMIMageState.png "Show ML image state") +![Show ML image state](images/tutorials/LMIMageState.png "Show ML image state") After enabling *Show ML image state*, your network changes and the input and output connectors appear red in case no data is available at the output. -![No data on connector](/images/tutorials/LMIMageState_On_1.png "No data on connector") +![No data on connector](images/tutorials/LMIMageState_On_1.png "No data on connector") After loading a valid DICOM directory, the connectors providing a valid ML image appear green. The previously red outputs are beige again, showing there is data available. -![No data on connector](/images/tutorials/LMIMageState_On_2.png "No data on connector") +![No data on connector](images/tutorials/LMIMageState_On_2.png "No data on connector") ## Module Suggestion of Module Input and Output {#modulesuggest} @@ -203,6 +203,6 @@ Especially for new users learning MeVisLab, it makes sense to enable the module If you now select an input or output, MeVisLab shows the modules that have been frequently used for this connector in our example networks. -![Module suggestion](/images/tutorials/ModuleSuggest.png "Module suggestion") +![Module suggestion](images/tutorials/ModuleSuggest.png "Module suggestion") You can toggle through the suggestions via keyboard shortcut {{< keyboard "," >}} or {{< keyboard "shift+," >}}. diff --git a/mevislab.github.io/content/tutorials/summary.md b/mevislab.github.io/content/tutorials/summary.md index c19d45254..0e73e7bd2 100644 --- a/mevislab.github.io/content/tutorials/summary.md +++ b/mevislab.github.io/content/tutorials/summary.md @@ -17,7 +17,7 @@ menu: ## Summary This chapter will summarize all previous chapters and you will develop a whole application in MeVisLab. The complete workflow from developing a prototype to delivering your final application to your customer is explained step-by-step. -![Prototype to Product](/images/tutorials/summary/Prototyping.png "Prototype to Product") +![Prototype to Product](images/tutorials/summary/Prototyping.png "Prototype to Product") {{}} Some of the features described here will require a separate license. Building an installable executable requires the **MeVisLab ApplicationBuilder** license. It extends the **MeVisLab SDK** so that you can generate an installer of your developed macro module. @@ -45,12 +45,12 @@ In the first step, you are developing an application based on the following requ * **Requirement 9.3**: All ### Step 2: Create Your Macro Module -Your network will be encapsulated in a macro module for later application development. For details about macro modules, see [Example 2.2: Global macro modules](/tutorials/basicmechanisms/macromodules/globalmacromodules/). +Your network will be encapsulated in a macro module for later application development. For details about macro modules, see [Example 2.2: Global macro modules](tutorials/basicmechanisms/macromodules/globalmacromodules/). ### Step 3: Develop a User Interface and Add Python Scripting {#UIDesign} Develop the UI and Python Scripts based on your requirements from Step 1. The resulting UI will look like below mockup: -![User Interface Design](/images/tutorials/summary/UIMockUp.png "User Interface Design") +![User Interface Design](images/tutorials/summary/UIMockUp.png "User Interface Design") ## Review ### Step 4: Write Automated Tests for Your Macro Module diff --git a/mevislab.github.io/content/tutorials/summary/summary1.md b/mevislab.github.io/content/tutorials/summary/summary1.md index d018334cc..3e6167db0 100644 --- a/mevislab.github.io/content/tutorials/summary/summary1.md +++ b/mevislab.github.io/content/tutorials/summary/summary1.md @@ -17,13 +17,13 @@ menu: {{< youtube "-hbddg0bXcA" >}} ## Introduction -In this example, we will develop a network which fulfills the requirements mentioned on the [overview page](/tutorials/summary#DevelopNetwork). The network will be developed by re-using existing modules and defining basic field values. +In this example, we will develop a network which fulfills the requirements mentioned on the [overview page](tutorials/summary#DevelopNetwork). The network will be developed by re-using existing modules and defining basic field values. ## Steps to do ### 2D viewer The 2D viewer shall visualize the loaded images. In addition to that, it shall be possible to click into the image to trigger a RegionGrowing algorithm to segment parts of the loaded image based on a threshold. -The following requirements from the [overview](/tutorials/summary#DevelopNetwork) will be implemented: +The following requirements from the [overview](tutorials/summary#DevelopNetwork) will be implemented: * **Requirement 1**: The application shall be able to load DICOM data. * **Requirement 3**: The 2D viewer shall display the loaded images * **Requirement 4**: The 2D viewer shall provide the possibility to segment parts of the image based on a RegionGrowing algorithm @@ -34,7 +34,7 @@ The following requirements from the [overview](/tutorials/summary#DevelopNetwork Add a `LocalImage` and a `View2D` module to your workspace. You are now able to load an image and view the slices. -![Loading an image](/images/tutorials/summary/Example1_1.png "Loading an image") +![Loading an image](images/tutorials/summary/Example1_1.png "Loading an image") RegionGrowing requires a `SoView2DMarkerEditor`, a `SoView2DOverlay` and a `RegionGrowing` module. Add them to your network and connect them as seen below. Configure the `RegionGrowing` module to use a *3D-6-Neighborhood (x,y,z)* relation and an automatic threshold value of *1.500*. Also select *Auto-Update*. @@ -44,10 +44,10 @@ If you now click into your loaded image via left mouse button {{< mousebutton "l The overlay is shown in white. -![RegionGrowing via marker editor](/images/tutorials/summary/Example1_2.png "RegionGrowing via marker editor") +![RegionGrowing via marker editor](images/tutorials/summary/Example1_2.png "RegionGrowing via marker editor") Open the `SoView2DOverlay` module, change Blend Mode to *Blend* and select any color and *Alpha Factor* for your overlay. The applied changes are immediately visible. -![Overlay color and transparency](/images/tutorials/summary/Example1_3.png "Overlay color and transparency") +![Overlay color and transparency](images/tutorials/summary/Example1_3.png "Overlay color and transparency") The segmented results from the `RegionGrowing` module might contain gaps because of differences in the intensity value of neighboring pixels. You can close these gaps by adding a `CloseGap` module. Connect it to the `RegionGrowing` and the `SoView2DOverlay` module and configure Filter Mode as *Binary Dilatation*, Border Handling as *Pad Dst Fill* and set KernelZ to *3*. @@ -55,12 +55,12 @@ Lastly, we want to calculate the volume of the segmented parts. Add a `Calculate You can group the modules in your network for an improved overview by selecting {{}}. Leave `LocalImage` out of the group and name it *2D Viewer*. Your network should now look like this: -![Group 2D Viewer](/images/tutorials/summary/Example1_4.png "Group 2D Viewer") +![Group 2D Viewer](images/tutorials/summary/Example1_4.png "Group 2D Viewer") ### 3D Viewer The 3D viewer shall visualize your loaded image in 3D and additionally provide the possibility to render your segmentation results. You will be able to decide for different views, displaying the image and the segmentation, only the image or only the segmentation. The volume (in ml) of your segmentation results shall be calculated. -The following requirements from [overview](/tutorials/summary#DevelopNetwork) will be implemented: +The following requirements from [overview](tutorials/summary#DevelopNetwork) will be implemented: * **Requirement 2**: The application shall provide a 2D and a 3D viewer. * **Requirement 6**: The 3D viewer shall visualize the loaded data in a 3-dimensional volume rendering. * **Requirement 7**: The 3D viewer shall additionally show the segmentation result as a 3-dimensional mesh. @@ -72,11 +72,11 @@ The following requirements from [overview](/tutorials/summary#DevelopNetwork) wi Add a `SoExaminerViewer`, a `SoWEMRenderer` and an `IsoSurface` module to your existing network and connect them to the `LocalImage` module. Configure the `IsoSurface` to use an IsoValue of *200*, a Resolution of *1* and check *Auto-Update* and *Auto-Apply*. -![3D Viewer](/images/tutorials/summary/Example1_5.png "3D Viewer") +![3D Viewer](images/tutorials/summary/Example1_5.png "3D Viewer") The result should be a 3-dimensional rendering of your image. -![SoExaminerViewer](/images/tutorials/summary/Example1_6.png "SoExaminerViewer") +![SoExaminerViewer](images/tutorials/summary/Example1_6.png "SoExaminerViewer") {{}} If the rendering is not immediately applied, click *Apply* in your `IsoSurface` module. @@ -86,11 +86,11 @@ Define the field instanceName of your `IsoSurface` module as *IsoSurfaceImage* a Set instanceName of the `SoWEMRenderer` module to *SoWEMRendererImage* and add another `SoWEMRenderer` module. Set this instanceName to *SoWEMRendererSegmentation* and connect it to the *IsoSurfaceSegmentation* module. Selecting the output of the new `SoWEMRenderer` shows the segmented parts as a 3D object in the output inspector. -![Segmentation preview in output inspector](/images/tutorials/summary/Example1_7.png "Segmentation preview in output inspector") +![Segmentation preview in output inspector](images/tutorials/summary/Example1_7.png "Segmentation preview in output inspector") Once again, we should group the modules used for 3D viewing and name the new group *3D Viewer*. -![Grouped network](/images/tutorials/summary/Example1_8.png "Grouped network") +![Grouped network](images/tutorials/summary/Example1_8.png "Grouped network") We now want to allow the user to toggle the different 3D visualizations as defined by the requirements above. It shall be possible to show: * Original data only @@ -99,26 +99,26 @@ We now want to allow the user to toggle the different 3D visualizations as defin Add a `SoSwitch` module to your network. Connect the switch to both of your `SoWEMRenderer` modules and to the `SoExaminerViewer`. -![SoSwitch](/images/tutorials/summary/Example1_9.png "SoSwitch") +![SoSwitch](images/tutorials/summary/Example1_9.png "SoSwitch") The default input of the switch is *None*. Your 3D viewer remains black. Using the arrows on the `SoSwitch` allows you to toggle between the segmentation and the image. Input 0 shows the segmented brain, input 1 shows the head. You are now able to toggle between them. A view with both objects is still missing. -{{< imagegallery 2 "/images/tutorials/summary" "Example1_Segmentation" "Example1_Image" >}} +{{< imagegallery 2 "images/tutorials/summary" "Example1_Segmentation" "Example1_Image" >}} Add a `SoGroup` module and connect both `SoWEMRenderer` modules as input. The output needs to be connected to the right input of the `SoSwitch` module. -![SoGroup](/images/tutorials/summary/Example1_10.png "SoGroup") +![SoGroup](images/tutorials/summary/Example1_10.png "SoGroup") You can now also toggle input 2 of the switch showing both 3D objects. The only problem is: You cannot see the brain because it is located inside the head. Open the `SoWEMRendererImage` module panel and set faceAlphaValue to *0.5*. The viewer now shows the head in a semi transparent manner so that you can see the brain. Certain levels of opacity are difficult to render. Add a `SoDepthPeelRenderer` module and connect it to the semi transparent `SoWEMRendererImage` module. Set Layers of the renderer to *1*. -![SoDepthPeelRenderer](/images/tutorials/summary/Example1_Both.png "SoDepthPeelRenderer") +![SoDepthPeelRenderer](images/tutorials/summary/Example1_Both.png "SoDepthPeelRenderer") You have a 2D and a 3D viewer now. Let's define the colors of the overlay to be re-used for the 3D segmentation. ### Parameter connections for visualization Open the panels of the `SoView2DOverlay` and the `SoWEMRendererSegmentation` module. Draw a parameter connection from *SoView2DOverlay.baseColor* to *SoWEMRendererSegmentation.faceDiffuseColor*. -![Synchronized segmentation colors](/images/tutorials/summary/Example1_11.png "Synchronized segmentation colors") +![Synchronized segmentation colors](images/tutorials/summary/Example1_11.png "Synchronized segmentation colors") Now the 3D visualization uses the same color as the 2D overlay. diff --git a/mevislab.github.io/content/tutorials/summary/summary2.md b/mevislab.github.io/content/tutorials/summary/summary2.md index fdebc0d0c..319bdef8a 100644 --- a/mevislab.github.io/content/tutorials/summary/summary2.md +++ b/mevislab.github.io/content/tutorials/summary/summary2.md @@ -20,29 +20,29 @@ menu: In this example, we encapsulate the previously developed prototype network into a macro module for future application development and automated testing. ## Steps to do -Make sure to have your *.mlab file from the previous [tutorial](/tutorials/summary/summary1/) available. +Make sure to have your *.mlab file from the previous [tutorial](tutorials/summary/summary1/) available. ### Package creation -Packages are described in detail in [Example 2.1: Package creation](/tutorials/basicmechanisms/macromodules/package/). If you already have your own package, you can skip this part and continue creating a macro module. +Packages are described in detail in [Example 2.1: Package creation](tutorials/basicmechanisms/macromodules/package/). If you already have your own package, you can skip this part and continue creating a macro module. Open Project Wizard via {{< menuitem "File" "Run Project Wizard..." >}} and select *New Package*. Run the Wizard and enter details of your new package and click *Create*. -![Package wizard](/images/tutorials/summary/Example2_1.png "Package wizard") +![Package wizard](images/tutorials/summary/Example2_1.png "Package wizard") MeVisLab reloads and you can start creating your macro module. ### Create a macro module Open Project Wizard via {{< menuitem "File" "Run Project Wizard..." >}} and select *macro module*. Run the Wizard and enter details of your new macro module. -![Macro module wizard](/images/tutorials/summary/Example2_2.png "Macro module wizard") +![Macro module wizard](images/tutorials/summary/Example2_2.png "Macro module wizard") Select the created package and click *Next*. -![Macro module wizard](/images/tutorials/summary/Example2_3.png "Macro module wizard") +![Macro module wizard](images/tutorials/summary/Example2_3.png "Macro module wizard") -Select your \*.mlab file from [Step 1](/tutorials/summary/summary1/) and check *Add Python file*. Click *Next*. +Select your \*.mlab file from [Step 1](tutorials/summary/summary1/) and check *Add Python file*. Click *Next*. -![Macro module wizard](/images/tutorials/summary/Example2_4.png "Macro module wizard") +![Macro module wizard](images/tutorials/summary/Example2_4.png "Macro module wizard") You do not have to define fields of your macro module now, we will do that later. Click *Create*. The Windows Explorer opens showing the directory of your macro module. It should be the same directory you selected for your Package. @@ -59,7 +59,7 @@ The directory structure for a macro module is as follows: * .py * .script -![Directory Structure](/images/tutorials/summary/Example2_6.png "Directory Structure") +![Directory Structure](images/tutorials/summary/Example2_6.png "Directory Structure") #### Definition (\*.def) file The initial \*.def file contains information you entered into the Wizard for the macro module. @@ -81,7 +81,7 @@ Macro module TutorialSummary { An *externalDefinition* to a script file is also added (see below for the \*.script file). #### MeVisLab Network (\*.mlab) file -The \*.mlab file is a copy of the \*.mlab file you developed in [Step 1](/tutorials/summary/summary1/) and re-used in the wizard. In the next chapters, this file will be used as *internal network*. +The \*.mlab file is a copy of the \*.mlab file you developed in [Step 1](tutorials/summary/summary1/) and re-used in the wizard. In the next chapters, this file will be used as *internal network*. #### Python (\*.py) file The initial \*.py file only contains the import of MeVisLab specific objects and functions. In the future steps, we will add functionalities to our application in Python. @@ -115,13 +115,13 @@ The source also defines your Python file to be used when calling functions and e ### Using your macro module As you created a global macro module, you can search for it in the MeVisLab *Module Search*. -![Module Search](/images/tutorials/summary/Example2_7.png "Module Search") +![Module Search](images/tutorials/summary/Example2_7.png "Module Search") We did not define inputs or outputs. You cannot connect your module to others. In addition to that, we did not develop a User Interface. Double-clicking your module {{< mousebutton "left" >}} only opens the Automatic Panel showing the *instanceName*. -![Automatic Panel](/images/tutorials/summary/Example2_8.png "Automatic Panel") +![Automatic Panel](images/tutorials/summary/Example2_8.png "Automatic Panel") -Right-click on your module allows you to open the internal network as developed in [Step 1](/tutorials/summary/summary1/). +Right-click on your module allows you to open the internal network as developed in [Step 1](tutorials/summary/summary1/). ## Summary * Macro modules encapsulate an entire MeVisLab network including all modules. diff --git a/mevislab.github.io/content/tutorials/summary/summary3.md b/mevislab.github.io/content/tutorials/summary/summary3.md index 435b8cacd..828379dfa 100644 --- a/mevislab.github.io/content/tutorials/summary/summary3.md +++ b/mevislab.github.io/content/tutorials/summary/summary3.md @@ -17,11 +17,11 @@ menu: {{< youtube "dOyncLUpclU" >}} ## Introduction -In this step, we will develop a user interface and add Python scripting to the macro module you created in [Step 2](/tutorials/summary/summary2). +In this step, we will develop a user interface and add Python scripting to the macro module you created in [Step 2](tutorials/summary/summary2). ## Steps to do ### Develop the User Interface -A mockup of the user interface you are going to develop is available [here](/tutorials/summary#UIDesign). The interface provides the possibility to load files and shows a 2D and a 3D viewer. In addition to that, some settings and information for our final application are available. +A mockup of the user interface you are going to develop is available [here](tutorials/summary#UIDesign). The interface provides the possibility to load files and shows a 2D and a 3D viewer. In addition to that, some settings and information for our final application are available. Search for your macro module and add it to your workspace. Right-click {{< mousebutton "right">}} and select {{< menuitem "Related Files" ".script" >}}. @@ -67,7 +67,7 @@ Window { You can preview your initial layout in MeVisLab by double-clicking your module {{< mousebutton "left" >}}. -![Initial Window Layout](/images/tutorials/summary/Example3_1.png "Initial Window Layout") +![Initial Window Layout](images/tutorials/summary/Example3_1.png "Initial Window Layout") You can see the 4 vertical aligned parts as defined in the \*.script file. Now we are going to add the content of the Boxes. @@ -127,7 +127,7 @@ Window { Again, you can preview your user interface in MeVisLab directly. You can already select a file to open. The image is available at the output of the `LocalImage` module in your internal network but the Viewers are missing in our interface. -![Source Box](/images/tutorials/summary/Example3_2.png "Source Box") +![Source Box](images/tutorials/summary/Example3_2.png "Source Box") ##### Viewing Add the 2 viewer modules to the *Viewing* section of your \*.script file and define their field as *View2D.self* and *SoExaminerViewer.self*. Set *expandX = Yes* and *expandY = Yes* for both viewing modules. We want them to resize in case the size of the Window changes. @@ -156,7 +156,7 @@ Set the 2D Viewer type to *SoRenderArea* and the 3D Viewer type to *SoExaminerVi ``` {{}} -![2D and 3D Viewer](/images/tutorials/summary/Example3_3.png "2D and 3D Viewer") +![2D and 3D Viewer](images/tutorials/summary/Example3_3.png "2D and 3D Viewer") The images selected in the *Source* section are shown in 2D and 3D. We simply re-used the existing fields and viewers from your internal network and are already able to interact with the images. As the `View2D` of your internal network itself provides the possibility to accept markers and starts the `RegionGrowing`, this is also already possible and the segmentations are shown in 2D and 3D. @@ -313,7 +313,7 @@ Window { Your user interface of the macro module should now look similar to this: -![User Interface without Python Scripting](/images/tutorials/summary/Example3_4.png "User Interface without Python Scripting") +![User Interface without Python Scripting](images/tutorials/summary/Example3_4.png "User Interface without Python Scripting") For the next elements, we require Python scripting. Nevertheless, you are already able to use your application and perform the basic functionalities without writing any line of code. @@ -519,12 +519,12 @@ Add the field to the Info section of your window. Opening the window of your macro module in MeVisLab now provides all functionalities we wanted to achieve. You can also play around in the window and define some additional Boxes or MDL controls but the basic application prototype is now done. -![Final Macro module](/images/tutorials/summary/Example3_5.png "Final Macro module") +![Final Macro module](images/tutorials/summary/Example3_5.png "Final Macro module") ### MeVisLab GUI Editor MATE provides a powerful GUI Editor showing a preview of your current user interface and allowing to re-order elements in the UI via drag and drop. In MATE open {{< menuitem "Extras" "Enable GUI Editor" >}}. -![MeVisLab GUI Editor](/images/tutorials/summary/Example3_4b.png "MeVisLab GUI Editor") +![MeVisLab GUI Editor](images/tutorials/summary/Example3_4b.png "MeVisLab GUI Editor") Changing the layout via drag and drop automatically adapts your *\*.script* file. Save and Reload the script and your changes are applied. diff --git a/mevislab.github.io/content/tutorials/summary/summary4.md b/mevislab.github.io/content/tutorials/summary/summary4.md index 151a13dfa..c8cb172ba 100644 --- a/mevislab.github.io/content/tutorials/summary/summary4.md +++ b/mevislab.github.io/content/tutorials/summary/summary4.md @@ -17,7 +17,7 @@ menu: {{< youtube "_wheDC8TBJQ" >}} ## Introduction -In the previous chapters you developed a macro module with User Interface and Python scripting. In this step you will see how to implement an automated test to verify and validate the Requirements defined in [Overview](/tutorials/summary). +In the previous chapters you developed a macro module with User Interface and Python scripting. In this step you will see how to implement an automated test to verify and validate the Requirements defined in [Overview](tutorials/summary). ## Steps to do ### Create a test network using your macro module @@ -25,11 +25,11 @@ Create a new and empty network and save it as \*.mlab file. Remember the locatio Use Module Search and add your macro module developed in previous steps to your Workspace. -![Macro module](/images/tutorials/summary/Example4_1.png "Macro module") +![Macro module](images/tutorials/summary/Example4_1.png "Macro module") You can see that the module does not have any inputs or outputs. You cannot connect it to other modules. For testing purposes it makes sense to provide the viewers and images as outputs so that you can use them for generating screenshots. -Open the \*.script file in MATE as already explained in [Step 3](/tutorials/summary/summary3). In the *Outputs* section, add the following: +Open the \*.script file in MATE as already explained in [Step 3](tutorials/summary/summary3). In the *Outputs* section, add the following: {{< highlight filename=".script" >}} ```Stan @@ -45,20 +45,20 @@ Interface { ``` {{}} -![Macro module with outputs](/images/tutorials/summary/Example4_2.png "Macro module with outputs") +![Macro module with outputs](images/tutorials/summary/Example4_2.png "Macro module with outputs") You can now add a viewer or any other module to your macro module and use them for testing. In our example, we add a `CalculateVolume` module to the segmentation mask and a `SoCameraInteraction` with two `OffscreenRenderer` modules to the 3D output. In the end, we need an `ImageCompare` module to compare expected and real image in our test. -![Test Network](/images/tutorials/summary/Example4_3.png "Test Network") +![Test Network](images/tutorials/summary/Example4_3.png "Test Network") ### Create test case Open MeVisLab TestCaseManager via {{< menuitem "File" "Run TestCaseManager..." >}}. On tab *Test Creation* define a name of your test case, for example *TutorialSummaryTest*. Select Type as *Macros*, define the package and use the same as for your macro module, select *Import Network* and Select your saved \*.mlab file from the step above. Click *Create*. -![Test Creation](/images/tutorials/summary/Example4_4.png "Test Creation") +![Test Creation](images/tutorials/summary/Example4_4.png "Test Creation") MATE automatically opens the Python file of your test case and it appears in MeVisLab TestCaseManager. -![Test Creation](/images/tutorials/summary/Example4_5.png "Test Creation") +![Test Creation](images/tutorials/summary/Example4_5.png "Test Creation") ### Write test functions in Python #### Preparations @@ -368,11 +368,11 @@ def TEST_Toggle3DVolumes(): ### Sorting order in TestCaseManager The MeVisLab TestCaseManager sorts your test cases alphabetically. Your test cases should look like this now: -![TestCaseManager Sorting](/images/tutorials/summary/Example4_6.png "TestCaseManager Sorting") +![TestCaseManager Sorting](images/tutorials/summary/Example4_6.png "TestCaseManager Sorting") Generally, test cases should not depend on each other and the order of their execution does not matter. Sometimes it makes sense though to execute tests in a certain order, for example for performance reasons. In this case you can add numeric prefixes to your test cases. This might look like this then: -![TestCaseManager Custom Sorting](/images/tutorials/summary/Example4_7.png "TestCaseManager Custom Sorting") +![TestCaseManager Custom Sorting](images/tutorials/summary/Example4_7.png "TestCaseManager Custom Sorting") ### Not testable requirements As already mentioned, some requirements can not be tested in an automated environment. Human eyesight cannot be replaced completely. @@ -387,7 +387,7 @@ In our application, the following tests have not been tested automatically: ### Test Reports The results of your tests are shown in a Report Viewer. You can also export the results to JUnit for usage in build environments like [Jenkins](https://www.jenkins.io/). -![ReportViewer](/images/tutorials/summary/Example4_8.png "ReportViewer") +![ReportViewer](images/tutorials/summary/Example4_8.png "ReportViewer") ### Screenshots You can also add screenshots of your inventor scene to the report. Add the following to your Python script wherever you want to capture the content of the `SoCameraInteraction` module and a Snapshot of your 3D scene is attached to your test report: diff --git a/mevislab.github.io/content/tutorials/summary/summary5.md b/mevislab.github.io/content/tutorials/summary/summary5.md index f51fc63b5..13c9d4b22 100644 --- a/mevislab.github.io/content/tutorials/summary/summary5.md +++ b/mevislab.github.io/content/tutorials/summary/summary5.md @@ -28,11 +28,11 @@ Free evaluation licenses of the **MeVisLab ApplicationBuilder**, time-limited to ### Install tools necessary for installer generation The MeVisLab Project Wizard for Standalone Applications {{}} provides a check for all necessary tools you need to install before generating an installer. -![MeVisLab Project Wizard](/images/tutorials/summary/Example5_1.png "MeVisLab Project Wizard") +![MeVisLab Project Wizard](images/tutorials/summary/Example5_1.png "MeVisLab Project Wizard") Click on *Check if required tools are installed*. The following dialog opens: -![Check required tools](/images/tutorials/summary/Example5_2.png "Check required tools") +![Check required tools](images/tutorials/summary/Example5_2.png "Check required tools") You can see that [NSIS](https://nsis.sourceforge.io/Download) and either [Dependency Walker](http://www.dependencywalker.com/) or [Dependencies](https://github.com/lucasg/Dependencies) are necessary to create an installable executable. MeVisLab provides information about the necessary version(s). @@ -43,31 +43,31 @@ Restart MeVisLab and open Project Wizard again. All required tools should now be ### Use MeVisLab Project Wizard to generate the installer Select your macro module and the package and click *Next*. -![Welcome](/images/tutorials/summary/Example5_3.png "Welcome") +![Welcome](images/tutorials/summary/Example5_3.png "Welcome") The general settings dialog allows you to define a name for your application. You can also define a version, in our case we decide not to be finished and have a version *0.5*. You can include debug files and decide to build a desktop or web application. We want to build an *Application Installer* for a desktop system. You can decide to precompile your Python files and you have to select your MeVisLab **MeVisLab ApplicationBuilder** license. -![General Settings](/images/tutorials/summary/Example5_4.png "General Settings") +![General Settings](images/tutorials/summary/Example5_4.png "General Settings") Define your license text which is shown during installation of your executable. You can decide to use our pre-defined text, select a custom file or do not include any license text. -![License Text](/images/tutorials/summary/Example5_5.png "License Text") +![License Text](images/tutorials/summary/Example5_5.png "License Text") The next dialog can be skipped for now, you can include additional files into your installer which are not automatically added by MeVisLab from the dependency analysis. -![Manual File Lists](/images/tutorials/summary/Example5_6.png "Manual File Lists") +![Manual File Lists](images/tutorials/summary/Example5_6.png "Manual File Lists") Define how the window of your application shall look. -![Application Options](/images/tutorials/summary/Example5_7.png "Application Options") +![Application Options](images/tutorials/summary/Example5_7.png "Application Options") Skip the next dialog, we do not need additional installer options. -![Installer Options](/images/tutorials/summary/Example5_8.png "Installer Options") +![Installer Options](images/tutorials/summary/Example5_8.png "Installer Options") The MeVisLab ToolRunner starts generating your installer. After finishing installer generation, you will find a link to the target directory. -![MeVisLab ToolRunner](/images/tutorials/summary/Example5_9.png "MeVisLab ToolRunner") +![MeVisLab ToolRunner](images/tutorials/summary/Example5_9.png "MeVisLab ToolRunner") The directory contains the following files (and some more maybe): * Batch (\*.bat) file @@ -81,7 +81,7 @@ The batch file allows you to generate the executable again via a Windows batch f #### Installer file The resulting installer file for your application is an executable #### MeVisLab Install file -The \*.mlinstall file provides all information you just entered into the wizard. We will need this in [Step 7: Refine - Re-Build Installer](/tutorials/summary/summary7/) again. +The \*.mlinstall file provides all information you just entered into the wizard. We will need this in [Step 7: Refine - Re-Build Installer](tutorials/summary/summary7/) again. The file is initially generated by the Project Wizard. Having a valid file already, you can create new versions by using the MeVisLab ToolRunner. #### Shell skript @@ -94,34 +94,34 @@ You can now execute the installer of your application. The installer initially shows a welcome screen showing the name and version of your application. -![Installer](/images/tutorials/summary/Example5_10.png "Installer") +![Installer](images/tutorials/summary/Example5_10.png "Installer") Next, you will see your selected license agreement from the project wizard and a selection to install for anyone or just for the current user. -![License Agreement](/images/tutorials/summary/Example5_11.png "License Agreement") +![License Agreement](images/tutorials/summary/Example5_11.png "License Agreement") You can also select to create shortcuts and desktop icons. -![Shortcuts and icons](/images/tutorials/summary/Example5_12.png "Shortcuts and icons") +![Shortcuts and icons](images/tutorials/summary/Example5_12.png "Shortcuts and icons") The last step is to select the target directory for your application. -![Target directory](/images/tutorials/summary/Example5_13.png "Target directory") +![Target directory](images/tutorials/summary/Example5_13.png "Target directory") After the installer finished the setup, you will find a desktop icon and a start menu entry for your application. -{{< imagegallery 2 "/images/tutorials/summary" "Startmenu" "Desktop" >}} +{{< imagegallery 2 "images/tutorials/summary" "Startmenu" "Desktop" >}} {{}} MeVisLab executables require an additional **MeVisLab Runtime** license. It makes sure that your resulting application needs to be licensed, too. Free evaluation licenses of the **MeVisLab ApplicationBuilder** and **MeVisLab Runtime** licenses for testing purposes can be requested at [sales(at)mevislab.de](mailto://sales@mevislab.de). {{}} -![Runtime License](/images/tutorials/summary/Example5_14.png "Runtime License") +![Runtime License](images/tutorials/summary/Example5_14.png "Runtime License") After entering your license file, the application runs and you can use it on a customer system. -![Installed Application](/images/tutorials/summary/Example5_15.png "Installed Application") +![Installed Application](images/tutorials/summary/Example5_15.png "Installed Application") {{}} By default, your user interface uses a standard stylesheet for colors and appearance of your user interface elements. The style can be customized easily. diff --git a/mevislab.github.io/content/tutorials/summary/summary6.md b/mevislab.github.io/content/tutorials/summary/summary6.md index 2991a9de5..57011d7cb 100644 --- a/mevislab.github.io/content/tutorials/summary/summary6.md +++ b/mevislab.github.io/content/tutorials/summary/summary6.md @@ -61,7 +61,7 @@ Window { Back in MeVisLab IDE, your user interface should now provide the possibility to define an alpha value of the overlay. Changes are applied automatically because you re-used the field of the `SoView2DOverlay` module directly. -![Updated User Interface](/images/tutorials/summary/Example6_1.png "Updated User Interface") +![Updated User Interface](images/tutorials/summary/Example6_1.png "Updated User Interface") You can also update your Python files for new or updated requirements. In this example we just want to show the basic principles, therefore we only add this new element to the Script file. diff --git a/mevislab.github.io/content/tutorials/summary/summary7.md b/mevislab.github.io/content/tutorials/summary/summary7.md index 55b7aff26..b3f6bd787 100644 --- a/mevislab.github.io/content/tutorials/summary/summary7.md +++ b/mevislab.github.io/content/tutorials/summary/summary7.md @@ -17,7 +17,7 @@ menu: {{< youtube "E0GnWPXT8Og" >}} ## Introduction -In this step you are re-creating your application installer after changing the UI in previous [Step 6: Refine - Update Application](/tutorials/summary/summary6/). +In this step you are re-creating your application installer after changing the UI in previous [Step 6: Refine - Update Application](tutorials/summary/summary6/). ## Steps to do ### Update the \*.mlinstall file @@ -30,22 +30,22 @@ You can also run the Project Wizard again but keep in mind that manual changes o ### Use MeVisLab ToolRunner Save the file and open *MeVisLab ToolRunner*. -![MeVisLab ToolRunner](/images/tutorials/summary/Example7_1.png "MeVisLab ToolRunner") +![MeVisLab ToolRunner](images/tutorials/summary/Example7_1.png "MeVisLab ToolRunner") Open the \*.mlinstall file in ToolRunner and select the file. Click *Run on Selection*. -![Run on Selection](/images/tutorials/summary/Example7_2.png "Run on Selection") +![Run on Selection](images/tutorials/summary/Example7_2.png "Run on Selection") The ToolRunner automatically builds your new installer using version 1.0. ### Install application again Execute your installable executable again. You do not have to uninstall previous version(s) of your application first. Already existing applications will be replaced by new installation - at least if you select the same target directory. -![Install new version](/images/tutorials/summary/Example7_3.png "Install new version") +![Install new version](images/tutorials/summary/Example7_3.png "Install new version") The installer already shows your updated version 1.0. It is not necessary to select your Runtime license again because it has not been touched during update. -![Application version 1.0](/images/tutorials/summary/Example7_4.png "Application version 1.0") +![Application version 1.0](images/tutorials/summary/Example7_4.png "Application version 1.0") The new installed application now provides your new UI element for defining the alpha value of the overlay. diff --git a/mevislab.github.io/content/tutorials/summary/summary8.md b/mevislab.github.io/content/tutorials/summary/summary8.md index 824de111a..62cf05455 100644 --- a/mevislab.github.io/content/tutorials/summary/summary8.md +++ b/mevislab.github.io/content/tutorials/summary/summary8.md @@ -25,47 +25,47 @@ Free evaluation licenses of the **MeVisLab Webtoolkit**, time-limited to 3 month {{}} ## Steps to do -Make sure to have your macro module from previous [Step 2](/tutorials/summary/summary2/) available. +Make sure to have your macro module from previous [Step 2](tutorials/summary/summary2/) available. ### Create a Web macro module Open Project Wizard via {{< menuitem "File" "Run Project Wizard..." >}} and select *Web Macro module*. Run the Wizard and enter details of your new macro module. -![Web macro module wizard](/images/tutorials/summary/Example8_1.png "Web macro module wizard") +![Web macro module wizard](images/tutorials/summary/Example8_1.png "Web macro module wizard") Run the wizard and enter details of your web macro module. -![Web macro module properties](/images/tutorials/summary/Example8_2.png "Web macro module properties") +![Web macro module properties](images/tutorials/summary/Example8_2.png "Web macro module properties") Click *Next* and select optional web plugin features. Click *Create*. -![Web macro module](/images/tutorials/summary/Example8_3.png "Web macro module") +![Web macro module](images/tutorials/summary/Example8_3.png "Web macro module") The folder of your project automatically opens in explorer window. ### Using your web macro module As you created a global web macro module, you can search for it in the MeVisLab *Module Search*. In case the module cannot be found, select {{< menuitem "Extras" "Reload Module Database (Clear Cache)" >}}. -![Web macro module](/images/tutorials/summary/Example8_4.png "Web macro module") +![Web macro module](images/tutorials/summary/Example8_4.png "Web macro module") -The internal network of your module is empty. We will re-use the internal network of your macro module developed in [Step 2](/tutorials/summary/summary2/). +The internal network of your module is empty. We will re-use the internal network of your macro module developed in [Step 2](tutorials/summary/summary2/). #### Add internal network of your application -Open the internal network of your previously created macro module from [Step 2](/tutorials/summary/summary2/). Select all and copy to your internal network of the *TutorialSummaryBrowser* module. Save the internal network and close the tab in MeVisLab. +Open the internal network of your previously created macro module from [Step 2](tutorials/summary/summary2/). Select all and copy to your internal network of the *TutorialSummaryBrowser* module. Save the internal network and close the tab in MeVisLab. -![Internal network](/images/tutorials/summary/Example8_5a.png "Internal network") +![Internal network](images/tutorials/summary/Example8_5a.png "Internal network") We are going to develop a web application, therefore we need special `RemoteRendering` modules for the viewer. Add 2 `RemoteRendering` modules and a `SoCameraInteraction` to your workspace and connect them to your existing modules as seen below. -![Remote Rendering](/images/tutorials/summary/Example8_5b.png "Remote Rendering") +![Remote Rendering](images/tutorials/summary/Example8_5b.png "Remote Rendering") {{}} We are using the hidden outputs of the `View2D` and the `SoExaminerViewer`. You can show them by pressing the *SPACE* key. {{}} #### Develop the user interface -Make sure to have both macro modules visible in MeVisLab SDK, we are re-using the *\*.script* and *\*.py* files developed in [Step 3](/tutorials/summary/summary3/). +Make sure to have both macro modules visible in MeVisLab SDK, we are re-using the *\*.script* and *\*.py* files developed in [Step 3](tutorials/summary/summary3/). -![Macro modules](/images/tutorials/summary/Example8_6.png "Macro modules") +![Macro modules](images/tutorials/summary/Example8_6.png "Macro modules") Right-click {{< mousebutton "right" >}} the module *TutorialSummaryBrowser* and select {{< menuitem "Related Files" "TutorialSummaryBrowser.script" >}}. @@ -92,7 +92,7 @@ Web { ``` {{}} -Open the script file of the *TutorialSummary* module from [Step 3](/tutorials/summary/summary3/). Copy the output section to your web macro and define *internalName* as the output of your `RemoteRendering` modules. +Open the script file of the *TutorialSummary* module from [Step 3](tutorials/summary/summary3/). Copy the output section to your web macro and define *internalName* as the output of your `RemoteRendering` modules. You can also copy all fields from *Parameters* section to your web macro module script. @@ -161,15 +161,15 @@ Interface { Reloading your web macro in MeVisLab SDK now shows the same outputs as the original macro module. The only difference is the type of your output. It changed from MLImage and Inventor Scene to MLBase from your `RemoteRendering` modules. -![Macro modules](/images/tutorials/summary/Example8_7.png "Macro modules") +![Macro modules](images/tutorials/summary/Example8_7.png "Macro modules") The internal network of your web macro should look like this: -![Macro modules](/images/tutorials/summary/Example8_8.png "Macro modules") +![Macro modules](images/tutorials/summary/Example8_8.png "Macro modules") You can emulate the final viewer by adding a `RemoteRenderingClient` module to the outputs of your web macro. -![RemoteRenderingClient](/images/tutorials/summary/Example8_9.png "RemoteRenderingClient") +![RemoteRenderingClient](images/tutorials/summary/Example8_9.png "RemoteRenderingClient") Open the *\*.script* files of your macro modules and copy the *FieldListeners* from *Commands* section of your *TutorialSummary.script* to *TutorialSummaryBrowser.script*. @@ -314,14 +314,14 @@ def applyPosition(): ### Run your application in browser MeVisLab provides a local webserver and you can preview your application in a browser by selecting the module and open {{< menuitem "Scripting" "Web" "Start Module Through Webservice" >}}. The integrated webserver starts and your default browser opens the local website showing your application. -![Webserver preview](/images/tutorials/summary/Example8_10.png "Webserver preview") +![Webserver preview](images/tutorials/summary/Example8_10.png "Webserver preview") Select your web macro *TutorialSummaryBrowser* and right-click {{< mousebutton "right" >}} to select {{< menuitem "Related Files" "Show Definition Folder" >}}. You can see the folder structure of your web macro and modify the stylesheet depending on your needs. ### Open current web instance in MeVisLab SDK If you want to inspect the internal state of the modules and your internal network, open the console of your browser and enter *MLAB.GUI.Application.module('TutorialSummaryBrowser').showIDE()*. MeVisLab opens and you can change your internal network while all modifications are applied on the website on-the-fly. -![MeVisLab SDK](/images/tutorials/summary/Example8_11.png "MeVisLab SDK") +![MeVisLab SDK](images/tutorials/summary/Example8_11.png "MeVisLab SDK") ## Summary * MeVisLab macro modules can easily be adapted to run in a browser window diff --git a/mevislab.github.io/content/tutorials/testing.md b/mevislab.github.io/content/tutorials/testing.md index 1b257696f..3b61c767e 100644 --- a/mevislab.github.io/content/tutorials/testing.md +++ b/mevislab.github.io/content/tutorials/testing.md @@ -22,10 +22,10 @@ All of these funtionalities will be addressed in this chapter. ### Testing The MeVisLab TestCenter is the starting point of your tests. Select {{}} to open the user interface of the TestCaseManager. -![MeVisLab TestCaseManager](/images/tutorials/testing/TestCaseManager.png "MeVisLab TestCaseManager") +![MeVisLab TestCaseManager](images/tutorials/testing/TestCaseManager.png "MeVisLab TestCaseManager") #### Test Selection -The Test Selection allows you to define a selection of test cases to be executed. The list can be configured by defining a filter, manually selecting the packages ([see Example 2.1: Package Creation](/tutorials/basicmechanisms/macromodules/package)) to be scanned for test cases. All test cases found in the selected packages are shown. +The Test Selection allows you to define a selection of test cases to be executed. The list can be configured by defining a filter, manually selecting the packages ([see Example 2.1: Package Creation](tutorials/basicmechanisms/macromodules/package)) to be scanned for test cases. All test cases found in the selected packages are shown. On the right side of the Test Selection tab, you can see a list of functions in the test case. Each list entry is related to a Python function. You can select the functions to be executed. If your test case contains a network, you can open the *.mlab* file or edit the Python file in MATE. @@ -44,11 +44,11 @@ If you have multiple versions installed, make sure to check and, if needed, alte ### Profiling Profiling allows you to get detailed information on the behavior of your modules and networks. You can add the profiling view via {{}}. The Profiling will be displayed in the Views area of the MeVisLab IDE. -![MeVisLab Profiling](/images/tutorials/testing/Profiling.png "MeVisLab Profiling") +![MeVisLab Profiling](images/tutorials/testing/Profiling.png "MeVisLab Profiling") With enabled profiling, your currently opened network will be inspected and the CPU and memory usage and many more details of each module and function are logged. ### Debugging Debugging can be enabled whenever the integrated text editor MATE is opened. Having a Python file opened, you can enable debugging via {{}}. You can define break points in Python, add variables to your watchlist, and walk through your break points just like in other editors and debuggers. -![MeVisLab Debugging](/images/tutorials/testing/MATE_debugging.png "MeVisLab Debugging") +![MeVisLab Debugging](images/tutorials/testing/MATE_debugging.png "MeVisLab Debugging") diff --git a/mevislab.github.io/content/tutorials/testing/testingexample1.md b/mevislab.github.io/content/tutorials/testing/testingexample1.md index 65c657a5c..2cf629a3a 100644 --- a/mevislab.github.io/content/tutorials/testing/testingexample1.md +++ b/mevislab.github.io/content/tutorials/testing/testingexample1.md @@ -23,14 +23,14 @@ In this example, you will learn how to write an automated test for a simple netw ### Creating the network to be used for testing Add the following modules to your workspace and connect them as seen below: -![Testcase network ](/images/tutorials/testing/testNetwork1.png "Testcase network ") +![Testcase network ](images/tutorials/testing/testNetwork1.png "Testcase network ") Save your network as *NetworkTestCase.mlab*. ## Test creation Open the MeVisLab TestCaseManager via menu {{}}. The following window will appear. -![TestCaseManager window ](/images/tutorials/testing/testCaseManagerWindow.png "TestCaseManager window ") +![TestCaseManager window ](images/tutorials/testing/testCaseManagerWindow.png "TestCaseManager window ") Change to the *Test Creation* tab and enter details of your test case as seen below. Make sure to have a package available already. @@ -40,7 +40,7 @@ Details on package creation can be found in [Example 2.1: Package creation](./tu Select your saved *NetworkTestCase.mlab* file. - ![Test Creation window ](/images/tutorials/testing/TestCreation.png "Test Creation window ") + ![Test Creation window ](images/tutorials/testing/TestCreation.png "Test Creation window ") Click *Create*. The MeVisLab text editor MATE will automatically open and display the Python file of your test. Add the below listed code to the Python file. @@ -89,11 +89,11 @@ The value of our `DicomImport`s *progress* field is saved as the *currentValue* Open the TestCase Manager und run your test by selecting your test case and clicking on the *Play* button in the bottom right corner. -![Run Test Case](/images/tutorials/testing/runTestCase.png "Run Test Case") +![Run Test Case](images/tutorials/testing/runTestCase.png "Run Test Case") After execution, the ReportViewer will open automatically displaying your test's results. -![ReportViewer](/images/tutorials/testing/successTestCase.png "ReportViewer") +![ReportViewer](images/tutorials/testing/successTestCase.png "ReportViewer") ### Writing a test for global macro modules @@ -112,7 +112,7 @@ Please observe that field access through Python scripting works differently for *Imagine unpeeled nuts in a bag as a concept - the field as a nut, their module as their nutshell and the bag as the global macro.* {{}} -[Example 2.2: Global macro modules](/tutorials/basicmechanisms/macromodules/globalmacromodules/) provides additional info on global macro modules and their creation. +[Example 2.2: Global macro modules](tutorials/basicmechanisms/macromodules/globalmacromodules/) provides additional info on global macro modules and their creation. {{}} ## Exercise diff --git a/mevislab.github.io/content/tutorials/testing/testingexample2.md b/mevislab.github.io/content/tutorials/testing/testingexample2.md index ad893ee51..36b265fe5 100644 --- a/mevislab.github.io/content/tutorials/testing/testingexample2.md +++ b/mevislab.github.io/content/tutorials/testing/testingexample2.md @@ -23,19 +23,19 @@ In this example, we are using the MeVisLab Profiler to inspect the memory and CP ### Creating the network to be used for profiling You can open any network you like, here we are using the example network of the module `MinMaxScan` for profiling. Add the module `MinMaxScan` to your workspace, open the example network via right-click {{}} and select {{}}. -![MinMaxScan Example Network](/images/tutorials/testing/profiling_network.png "MinMaxScan Example Network") +![MinMaxScan Example Network](images/tutorials/testing/profiling_network.png "MinMaxScan Example Network") ### Enable Profiling Next, enable the MeVisLab Profiler via menu item {{}}. The Profiler is opened in your Views Area but can be detached and dragged over the workspace holding the left mouse button {{}}. -![MeVisLab Profiling](/images/tutorials/testing/Profiling.png "MeVisLab Profiling") +![MeVisLab Profiling](images/tutorials/testing/Profiling.png "MeVisLab Profiling") Enable profiling by checking *Enable* in the top left corner of the Profiling window. ### Inspect your network Now open the `View2D` module's panel via double-click and scroll through the slices. Inspect the Profiler. -![MeVisLab Profiling Network](/images/tutorials/testing/Profiling_Network1.png "MeVisLab Profiling Network") +![MeVisLab Profiling Network](images/tutorials/testing/Profiling_Network1.png "MeVisLab Profiling Network") The Profiler shows detailed information about each module in your network. @@ -46,11 +46,11 @@ Also, filtering by module name is handy when you are working with larger network Field values and their changes for all modules in your network can be inspected in the *Fields* tab: -![MeVisLab Profiling Fields](/images/tutorials/testing/Profiling_Network2.png "MeVisLab Profiling Fields") +![MeVisLab Profiling Fields](images/tutorials/testing/Profiling_Network2.png "MeVisLab Profiling Fields") In addition to the Profiler window, your modules also provide a tiny bar indicating their current memory and time consumption. -![MeVisLab Profiling Module](/images/tutorials/testing/Module_Info.png "MeVisLab Profiling Module") +![MeVisLab Profiling Module](images/tutorials/testing/Module_Info.png "MeVisLab Profiling Module") {{}} More information about profiling in MeVisLab can be found {{< docuLinks "/Resources/Documentation/Publish/SDK/MeVisLabManual/ch17.html" "here">}} diff --git a/mevislab.github.io/content/tutorials/testing/testingexample3.md b/mevislab.github.io/content/tutorials/testing/testingexample3.md index 81598afd6..ab516007a 100644 --- a/mevislab.github.io/content/tutorials/testing/testingexample3.md +++ b/mevislab.github.io/content/tutorials/testing/testingexample3.md @@ -23,16 +23,16 @@ In this example, you are writing an iterative test. Iterative test functions run ### Creating the network to be used for testing Add a `LocalImage` and a `DicomTagViewer` module to your workspace and connect them. -![Example Network](/images/tutorials/testing/network_test3.png "Example Network") +![Example Network](images/tutorials/testing/network_test3.png "Example Network") ### Test case creation Open the panel of the `DicomTagViewer` and set *Tag Name* to *WindowCenter*. The value of the DICOM tag from the current input image is automatically set as value. Save the network. -Start MeVisLab TestCaseManager and create a new test case called *IterativeTestCase* as seen in [Example 1: Writing a simple testcase in MeVisLab](/tutorials/testing/testingexample1). +Start MeVisLab TestCaseManager and create a new test case called *IterativeTestCase* as seen in [Example 1: Writing a simple testcase in MeVisLab](tutorials/testing/testingexample1). -![DicomTagViewer](/images/tutorials/testing/DicomTagViewer.png "DicomTagViewer") +![DicomTagViewer](images/tutorials/testing/DicomTagViewer.png "DicomTagViewer") ### Defining the test data In TestCaseManager open the test case Python file via *Edit File*. @@ -77,7 +77,7 @@ def testPatient(path, windowCenter): {{}} 1. Initially, the path and filename for the module `LocalImage` are set. The data is loaded automatically, because the module has the *AutoLoad* flag enabled by default. -![LocalImage](/images/tutorials/testing/LocalImage.png "LocalImage") +![LocalImage](images/tutorials/testing/LocalImage.png "LocalImage") 2. Then, the DICOM tree of the loaded file is used to get the *WindowCenter* value (*importValue*). 3. The previously defined value of the `DicomTagViewer` is set as *dicomValue*. 4. The final test functions *ASSERT_EQ* evaluate if the given values are equal. @@ -89,7 +89,7 @@ You can use many other *ASSERT** possibilities, just try using the MATE auto com ### Run your iterative test Open MeVisLab TestCase Manager and select your package and test case. You will see 2 test functions on the right side. -![Iterative Test](/images/tutorials/testing/TestCaseManager_TestWindowCenter.png "Iterative Test") +![Iterative Test](images/tutorials/testing/TestCaseManager_TestWindowCenter.png "Iterative Test") The identifiers of your test functions are shown as defined in the list (*ProbandT1/2*). The *TestWindowCenter* now runs for each entry in the list and calls the function *testPatient* for each entry using the given values. @@ -108,7 +108,7 @@ def testPatient(path, windowCenter): Your ReportViewer now shows a screenshot of the image in the `View2D`. -![Screenshot in ReportViewer](/images/tutorials/testing/Screenshot.png "Screenshot in ReportViewer") +![Screenshot in ReportViewer](images/tutorials/testing/Screenshot.png "Screenshot in ReportViewer") ## Summary * Iterative tests allow you to run the same test function on multiple input entries. diff --git a/mevislab.github.io/content/tutorials/thirdparty/MONAI/monaiexample1.md b/mevislab.github.io/content/tutorials/thirdparty/MONAI/monaiexample1.md index 6d168c720..2de393a50 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/MONAI/monaiexample1.md +++ b/mevislab.github.io/content/tutorials/thirdparty/MONAI/monaiexample1.md @@ -20,14 +20,14 @@ With the `PythonPip` module, you can import additional Python libraries into MeV ### Steps to do #### Install PyTorch -As *MONAI* requires *PyTorch*, install it by using the `PythonPip` module as described [here](/tutorials/thirdparty/pytorch/pytorchexample1/). +As *MONAI* requires *PyTorch*, install it by using the `PythonPip` module as described [here](tutorials/thirdparty/pytorch/pytorchexample1/). #### Install MONAI After installing *torch* and *torchvision*, we install *MONAI*. For installing *MONAI* enter \"*monai*\" into the Command textbox and press *Install*. -![Install MONAI](/images/tutorials/thirdparty/monai_example1_1.png "Install MONAI") +![Install MONAI](images/tutorials/thirdparty/monai_example1_1.png "Install MONAI") After clicking *Install*, the pip console output opens and you can follow the process of the installation. @@ -37,11 +37,11 @@ If you are behind a proxy server, you may have to set the **HTTP_PROXY** and **H Alternatively you can also add a parameter to *pip install* command: *--proxy https://proxy:port* {{}} -![PythonPip MONAI](/images/tutorials/thirdparty/monai_example1_2.png "PythonPip MONAI") +![PythonPip MONAI](images/tutorials/thirdparty/monai_example1_2.png "PythonPip MONAI") After the installation was finished with exit code 0, you should see the new packages in the `PythonPip` module. -![MONAI installed](/images/tutorials/thirdparty/monai_example1_3.png "MONAI installed") +![MONAI installed](images/tutorials/thirdparty/monai_example1_3.png "MONAI installed") ## Summary * *MONAI* can be installed and directly used in MeVisLab by using the `PythonPip` module. diff --git a/mevislab.github.io/content/tutorials/thirdparty/MONAI/monaiexample2.md b/mevislab.github.io/content/tutorials/thirdparty/MONAI/monaiexample2.md index b2b3161b5..a810ad6de 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/MONAI/monaiexample2.md +++ b/mevislab.github.io/content/tutorials/thirdparty/MONAI/monaiexample2.md @@ -24,7 +24,7 @@ This example shows how to use the model for **Spleen CT Segmentation** directly Create a folder named *spleen_ct_segmentation* somewhere on your system. Inside this folder, create two subfolders, one named *configs* and another named *models* and remember their paths. -![Directory Structure](/images/tutorials/thirdparty/monai_example2_1.png "Directory Structure"). +![Directory Structure](images/tutorials/thirdparty/monai_example2_1.png "Directory Structure"). Download all *config* files from [MONAI-Model-Zoo](https://github.com/Project-MONAI/model-zoo/tree/dev/models/spleen_ct_segmentation/configs "MONAI Model-Zoo") and save them in your local *configs* directory. @@ -41,7 +41,7 @@ The recommended CT images used for training the algorithm, can be found [here](h ### Create a macro module and add inputs and outputs Add a `PythonImage` module and save the network as *MONAISpleenSegmentation.mlab*. -![PythonImage module](/images/tutorials/thirdparty/monai_example2_1a.png "PythonImage module"). +![PythonImage module](images/tutorials/thirdparty/monai_example2_1a.png "PythonImage module"). Now, right-click {{< mousebutton "right" >}} on the `PythonImage` module, select {{< menuitem "“Grouping”" "Add to new Group">}}, and name the group *MONAIDemo*. @@ -49,7 +49,7 @@ Right-click {{< mousebutton "right" >}} on the group's name and choose *Convert Our new module does not provide an input or output. -![Local Macro Module MONAIDemo](/images/tutorials/thirdparty/monai_example2_2.png "Local Macro Module MONAIDemo") +![Local Macro Module MONAIDemo](images/tutorials/thirdparty/monai_example2_2.png "Local Macro Module MONAIDemo") Right-click {{< mousebutton "right" >}} on the Macro Module and select {{< menuitem "Related Files" "MONAIDemo.script">}}. @@ -73,7 +73,7 @@ Interface { If you now reload your module in MeVisLab, you can see the new input and output. -![MONAIDemo with input and output](/images/tutorials/thirdparty/monai_example2_3.png "MONAIDemo with input and output") +![MONAIDemo with input and output](images/tutorials/thirdparty/monai_example2_3.png "MONAIDemo with input and output") Add a *Commands* section to your \**.script*-file. @@ -92,7 +92,7 @@ Right-click {{< mousebutton "right" >}} on the MONAIDemo.py and select {{< menui ### Create the network for the segmentation Right-click {{< mousebutton "right" >}} on the Macro Module and select {{< menuitem "Related Files" "MONAIDemo.mlab">}}. Create the network seen below. -![MONAIDemo Network](/images/tutorials/thirdparty/monai_example2_3a.png "MonaiDemo Network") +![MONAIDemo Network](images/tutorials/thirdparty/monai_example2_3a.png "MonaiDemo Network") Fields of the internal network can be left with default values, we will change them later. @@ -115,7 +115,7 @@ Interface { If you now open the internal network of your macro module, you can see that the input image is connected to the input of the `Resample3D` module. -![MONAIDemo Internal Network](/images/tutorials/thirdparty/monai_example2_3b.png "MonaiDemo Internal Network") +![MONAIDemo Internal Network](images/tutorials/thirdparty/monai_example2_3b.png "MonaiDemo Internal Network") Again open the *\*.script* file and change the internal name of your *outImage* field to re-use the field *Resample3D1.output0*. @@ -134,22 +134,22 @@ Interface { If you now open the internal network of your macro module, you can see that the output image is connected to the output of the `Resample3D1` module. -![MONAIDemo Internal Network](/images/tutorials/thirdparty/monai_example2_3c.png "MonaiDemo Internal Network") +![MONAIDemo Internal Network](images/tutorials/thirdparty/monai_example2_3c.png "MonaiDemo Internal Network") ### Adapt input image to *MONAI* parameters from training The model has been trained for strictly defined assumptions for the input image. All values can normally be found in the *inference.json* file in your *configs* directory. -Use the `itkImageFileReader` module to load the file *Task09_Spleen/Task09_Spleen/imagesTr/spleen_7.nii.gz* from dowloaded example patients. The *Output Inspector* shows the image and additional information about the size. +Use the `itkImageFileReader` module to load the file *Task09_Spleen/Task09_SpleenimagesTr/spleen_7.nii.gz* from dowloaded example patients. The *Output Inspector* shows the image and additional information about the size. We can see that the image size is 512 x 512 x 114 and the voxel size is 0.9766 x 0.9766 x 2.5. -![Output Inspector](/images/tutorials/thirdparty/monai_example2_3d.png "Output Inspector") +![Output Inspector](images/tutorials/thirdparty/monai_example2_3d.png "Output Inspector") Connect the module to your local macro module `MonaiDemo`. The result of the segmentation shall be visualized as a semi-transparent overlay on your original image. Add a `SoView2DOverlay` and a `View2D` module and connect them to your local macro module `MonaiDemo`. -![Final network](/images/tutorials/thirdparty/monai_example2_4.png "Final network") +![Final network](images/tutorials/thirdparty/monai_example2_4.png "Final network") The **Spleen CT Segmentation** network expects images having a defined voxel size of 1.5 x 1.5 x 2. We want to define these values via fields in the Module inspector. @@ -170,11 +170,11 @@ Interface { If you reload your module now, we can set the voxel size to use for the segmentation directly in our macro module `MonaiDemo`. Additionally we can trigger a start function for running the segmentation. This is implemented later. -![Voxel Size](/images/tutorials/thirdparty/monai_example2_4a.png "Voxel Size") +![Voxel Size](images/tutorials/thirdparty/monai_example2_4a.png "Voxel Size") If you select the output field of the `Resample3D` module in the internal network, you can see the dimensions of the currently opened image after changing the voxel size to 1.5 x 1.5 x 2. It shows 333 x 333 x 143. -![Original Image Size](/images/tutorials/thirdparty/monai_example2_5.png "Original Image Size") +![Original Image Size](images/tutorials/thirdparty/monai_example2_5.png "Original Image Size") The algorithm expects image sizes of 160 x 160 x 160. We add this expected size of the image to our macro module in the same way. @@ -251,7 +251,7 @@ The algorithm expects NumPy images. NumPy uses the order Z, Y, X, other than MeV Open the panel of the `SwapFlipDimensions` module and select X as *Axis 1* and Z as *Axis 2*. -![SwapFlipDimensions](/images/tutorials/thirdparty/monai_example2_11.png "SwapFlipDimensions") +![SwapFlipDimensions](images/tutorials/thirdparty/monai_example2_11.png "SwapFlipDimensions") After the algorithm has been executed, we have to flip the images back to the original order. Open the panel of the `SwapFlipDimensions1` module and select X as *Axis 1* and Z as *Axis 2*. @@ -260,7 +260,7 @@ Finally we want to show the results of the algorithm as a semi-transparent overl * Alpha Factor: 0.5 * Base Color: red -![View2DOverlay](/images/tutorials/thirdparty/monai_example2_12.png "View2DOverlay") +![View2DOverlay](images/tutorials/thirdparty/monai_example2_12.png "View2DOverlay") ### Field Listeners We add some Field Listeners to our Commands section of the *\*.script* file. They are necessary to react on changes the user makes on the fields of our module. @@ -463,7 +463,7 @@ Window { If you now open the panel of our `MONAIDemo` module, we can manually move the box in all three dimensions. -![MONAIDemo panel](/images/tutorials/thirdparty/monai_example2_5.png "MONAIDemo panel"). +![MONAIDemo panel](images/tutorials/thirdparty/monai_example2_5.png "MONAIDemo panel"). Back to Python, we now need to reset our module to default, in case the input image changes. This also removes previous segmentations from the `PythonImage` module. @@ -491,7 +491,7 @@ If you now load an image using the `itkImageFileReader` module, you can manually The results are shown as a semi-transparent overlay. -![Segmentation result](/images/tutorials/thirdparty/monai_example2_6.png "Segmentation result"). +![Segmentation result](images/tutorials/thirdparty/monai_example2_6.png "Segmentation result"). You can also use the other examples from *MONAI Model Zoo* the same way, just make sure to apply the necessary changes on the input images like size, voxel size and other parameters defined in the *inference.json* file of the model. diff --git a/mevislab.github.io/content/tutorials/thirdparty/assimp.md b/mevislab.github.io/content/tutorials/thirdparty/assimp.md index 621c031d7..e61519cc0 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/assimp.md +++ b/mevislab.github.io/content/tutorials/thirdparty/assimp.md @@ -18,7 +18,7 @@ menu: This chapter provides some examples of how 3D formats can be imported into MeVisLab. In general, you always need a `SoSceneLoader` module. The `SoSceneLoader` allows to load meshes as Open Inventor points/lines/triangles/faces using the Open Asset Import Library. -![SoSceneLoader](/images/tutorials/thirdparty/SoSceneLoader.png "SoSceneLoader") +![SoSceneLoader](images/tutorials/thirdparty/SoSceneLoader.png "SoSceneLoader") You can also use the `SoSceneWriter` module to export your 3D scenes from MeVisLab in a number of output formats. diff --git a/mevislab.github.io/content/tutorials/thirdparty/assimp/assimpexample1.md b/mevislab.github.io/content/tutorials/thirdparty/assimp/assimpexample1.md index 0c05d12f2..c952ad633 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/assimp/assimpexample1.md +++ b/mevislab.github.io/content/tutorials/thirdparty/assimp/assimpexample1.md @@ -23,7 +23,7 @@ This example uses the assimp library to load a 3D file and save the file as \*.s ### Develop your network Add the modules `SoSceneLoader`, `SoBackground` and `SoExaminerViewer` to your workspace and connect them as seen below. -![Example Network](/images/tutorials/thirdparty/assimp_example1.png "Example Network") +![Example Network](images/tutorials/thirdparty/assimp_example1.png "Example Network") ### Open the 3D file Select the file *vtkCow.obj* from MeVisLab demo data directory. Open `SoExaminerViewer` and inspect the scene. You will see a 3D cow. @@ -32,22 +32,22 @@ Select the file *vtkCow.obj* from MeVisLab demo data directory. Open `SoExaminer In case you cannot see the cow, it might be located outside your current camera location. Trigger the field *rescanScene* in case the cow is not visible. {{}} -![Cow in SoExaminerViewer](/images/tutorials/thirdparty/vtkCow.png "Cow in SoExaminerViewer") +![Cow in SoExaminerViewer](images/tutorials/thirdparty/vtkCow.png "Cow in SoExaminerViewer") Add a `SoSphere` to the workspace and connect it to your viewer. Define the *Radius* of your sphere to 2 and inspect your viewer. -![Cow and Sphere in SoExaminerViewer](/images/tutorials/thirdparty/CowAndSphere.png "Cow and Sphere in SoExaminerViewer") +![Cow and Sphere in SoExaminerViewer](images/tutorials/thirdparty/CowAndSphere.png "Cow and Sphere in SoExaminerViewer") You can also define a material for your sphere but what we wanted to show is: You can use the loaded 3D files in MeVisLab Open Inventor Scenes. -![Cow and red Sphere in SoExaminerViewer](/images/tutorials/thirdparty/CowAndSphere_red.png "Cow and red Sphere in SoExaminerViewer") +![Cow and red Sphere in SoExaminerViewer](images/tutorials/thirdparty/CowAndSphere_red.png "Cow and red Sphere in SoExaminerViewer") ### Save your scene as \*.stl file for 3D Printing Add a `SoSceneWriter` module to your workspace. The `SoExaminerViewer` has a hidden output which can be shown on pressing {{}}. Connect the `SoSceneWriter` to the output. Name your output \*.stl file and select *Stl Ascii* as output format so that we can inspect the result afterwards. -![SoSceneWriter](/images/tutorials/thirdparty/SoSceneWriter.png "SoSceneWriter") +![SoSceneWriter](images/tutorials/thirdparty/SoSceneWriter.png "SoSceneWriter") {{}} The `SoSceneWriter` can save node color information when saving in Inventor (ASCII or binary) or in VRML format. The `SoSceneWriter` needs to be attached to a `SoWEMRenderer` that renders in *ColorMode:NodeColor*. @@ -57,7 +57,7 @@ There are [tools](https://www.patrickmin.com/meshconv/) to convert from at least Write your Scene and open the resulting file in your preferred editor. As an alternative, you can also open the file in an \*.stl file reader like Microsoft 3D-Viewer. -![Microsoft 3D-Viewer](/images/tutorials/thirdparty/Microsoft_3D_Viewer.png "Microsoft 3D-Viewer") +![Microsoft 3D-Viewer](images/tutorials/thirdparty/Microsoft_3D_Viewer.png "Microsoft 3D-Viewer") ### Load the file again For loading your \*.stl file, you can use a `SoSceneLoader` and a `SoExaminerViewer`. @@ -66,7 +66,7 @@ For loading your \*.stl file, you can use a `SoSceneLoader` and a `SoExaminerVie More information about the \*.stl format can be found [here](https://en.wikipedia.org/wiki/STL_(file_format)) {{}} -![SoSceneLoader](/images/tutorials/thirdparty/SoSceneLoader_2.png "SoSceneLoader") +![SoSceneLoader](images/tutorials/thirdparty/SoSceneLoader_2.png "SoSceneLoader") ## Summary * MeVisLab is able to load and write many different 3D file formats including *.stl format for 3D Printing. diff --git a/mevislab.github.io/content/tutorials/thirdparty/matplotlib.md b/mevislab.github.io/content/tutorials/thirdparty/matplotlib.md index 0d360693d..532e159c1 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/matplotlib.md +++ b/mevislab.github.io/content/tutorials/thirdparty/matplotlib.md @@ -24,10 +24,10 @@ As MeVisLab supports the integration of Python scripts, e.g., for test automatio In the following tutorial pages on Matplotlib, you will be shown how to create a module in MeVisLab that helps you plot greyscale distributions of single slices or defined sequences of slices of a DICOM image and layer the grayscale distributions of two chosen slices for comparison. -+ The module that is adapted during the tutorials is set up in the [Example 1: Module Setup](/tutorials/thirdparty/matplotlib/modulesetup) tutorial. -+ The panel and two dimensional plotting functionality is added in [Example 2: 2D Plotting](/tutorials/thirdparty/matplotlib/2dplotting). -+ In [Example 3: Slice Comparison](/tutorials/thirdparty/matplotlib/slicecomparison), the comparison between two chosen slices is enabled by overlaying their grayscale distributions. -+ [Example 4: 3D Plotting](/tutorials/thirdparty/matplotlib/3dplotting) adds an additional three-dimensional plotting functionality to the panel. ++ The module that is adapted during the tutorials is set up in the [Example 1: Module Setup](tutorials/thirdparty/matplotlib/modulesetup) tutorial. ++ The panel and two dimensional plotting functionality is added in [Example 2: 2D Plotting](tutorials/thirdparty/matplotlib/2dplotting). ++ In [Example 3: Slice Comparison](tutorials/thirdparty/matplotlib/slicecomparison), the comparison between two chosen slices is enabled by overlaying their grayscale distributions. ++ [Example 4: 3D Plotting](tutorials/thirdparty/matplotlib/3dplotting) adds an additional three-dimensional plotting functionality to the panel. {{}} Notice that for the Matplotlib tutorials, the previous tutorial always works as a foundation for the following one. diff --git a/mevislab.github.io/content/tutorials/thirdparty/matplotlib/2Dplotting.md b/mevislab.github.io/content/tutorials/thirdparty/matplotlib/2Dplotting.md index bd2850193..80a58c604 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/matplotlib/2Dplotting.md +++ b/mevislab.github.io/content/tutorials/thirdparty/matplotlib/2Dplotting.md @@ -16,13 +16,13 @@ menu: ## Introduction -In this tutorial, we will equip the macro module we created in the [previous tutorial](/tutorials/thirdparty/matplotlib/modulesetup) with a responsive and interactable panel to plot grayscale distributions of single slices as well as defined sequences of slices in 2D. +In this tutorial, we will equip the macro module we created in the [previous tutorial](tutorials/thirdparty/matplotlib/modulesetup) with a responsive and interactable panel to plot grayscale distributions of single slices as well as defined sequences of slices in 2D. ## Steps to do Open the module definition folder of your macro module and the related .script file in MATE. Then activate the Preview as shown below: -![MATE Preview](/images/tutorials/thirdparty/Matplotlib7.png) +![MATE Preview](images/tutorials/thirdparty/Matplotlib7.png) Drag the small Preview window to the bottom right corner of your window where it does not bother you. We will now be adding contents to be displayed there. @@ -73,8 +73,8 @@ You can click and hold onto a box to move it within the Preview. Your code will To plot a slice or a defined sequence of slices, we need to be able to set a start and an end. Go back into your MeVisLab workspace, right click your `BaseNetwork` module and choose "Show Internal Network". -![SubImage module info](/images/tutorials/thirdparty/Matplotlib8.png "The `SubImage` module provides the option to set sequences of slices.") -![SubImage module panel](/images/tutorials/thirdparty/Matplotlib9.PNG "The starting and ending slices of the sequence can be set in the module panel.") +![SubImage module info](images/tutorials/thirdparty/Matplotlib8.png "The `SubImage` module provides the option to set sequences of slices.") +![SubImage module panel](images/tutorials/thirdparty/Matplotlib9.PNG "The starting and ending slices of the sequence can be set in the module panel.") {{}} To find out what the parameters are called, what type of values they contain and receive and what they refer to, you can right-click on them within the panel. @@ -212,7 +212,7 @@ Lastly, put this under your two boxes, but above the empty element in the vertic ``` {{}} If you followed all of the listed steps, your panel preview should look like this and display all the current parameter values. -![Adapted macro panel](/images/tutorials/thirdparty/Matplotlib10.PNG) +![Adapted macro panel](images/tutorials/thirdparty/Matplotlib10.PNG) We can now work on the functions that visualize the data as plots on the Matplotlib canvas. You will have noticed how all of the buttons in the .script file have a command. Whenever that button is clicked, its designated command is executed. @@ -293,9 +293,9 @@ def click2D(): You should now be able to reproduce results like these: -![Single Slice 2D](/images/tutorials/thirdparty/Matplotlib13.PNG "2D plot of slice 28") -![Small Sequence 2D](/images/tutorials/thirdparty/Matplotlib112.PNG "Smaller sequences are displayed as multiple single slice plots.") -![Sequence in 2D](/images/tutorials/thirdparty/Matplotlib122.PNG "Sequence in 2D") +![Single Slice 2D](images/tutorials/thirdparty/Matplotlib13.PNG "2D plot of slice 28") +![Small Sequence 2D](images/tutorials/thirdparty/Matplotlib112.PNG "Smaller sequences are displayed as multiple single slice plots.") +![Sequence in 2D](images/tutorials/thirdparty/Matplotlib122.PNG "Sequence in 2D") {{}} Notice how the bin size affects the plots appearance. diff --git a/mevislab.github.io/content/tutorials/thirdparty/matplotlib/3Dplotting.md b/mevislab.github.io/content/tutorials/thirdparty/matplotlib/3Dplotting.md index a8e1f133c..9b93cfe07 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/matplotlib/3Dplotting.md +++ b/mevislab.github.io/content/tutorials/thirdparty/matplotlib/3Dplotting.md @@ -16,7 +16,7 @@ menu: ## Introduction -In this tutorial, we will equip the macro module we created in the [Example 1: Module Setup](/tutorials/thirdparty/matplotlib/modulesetup) and later on adapted by enabling it to plot grayscale distributions of single slices and sequences in 2D in [Example 2: 2D Plotting](/tutorials/thirdparty/matplotlib/2dplotting) with a three-dimensional plotting functionality. +In this tutorial, we will equip the macro module we created in the [Example 1: Module Setup](tutorials/thirdparty/matplotlib/modulesetup) and later on adapted by enabling it to plot grayscale distributions of single slices and sequences in 2D in [Example 2: 2D Plotting](tutorials/thirdparty/matplotlib/2dplotting) with a three-dimensional plotting functionality. ## Steps to do @@ -56,8 +56,8 @@ After saving, you should be able to reproduce results like these: You cannot zoom into 3D plots on a Matplotlib canvas. Try changing the viewing angle instead. {{}} -![Single Slice 3D](/images/tutorials/thirdparty/Matplotlib27.PNG) -![Single Slice 3D](/images/tutorials/thirdparty/Matplotlib29.PNG) +![Single Slice 3D](images/tutorials/thirdparty/Matplotlib27.PNG) +![Single Slice 3D](images/tutorials/thirdparty/Matplotlib29.PNG) You can download the .py file below if you want. {{< networkfile "/tutorials/thirdparty/matplotlib/BaseNetwork3D.py" >}} diff --git a/mevislab.github.io/content/tutorials/thirdparty/matplotlib/modulesetup.md b/mevislab.github.io/content/tutorials/thirdparty/matplotlib/modulesetup.md index 0bad6d6f5..07a8e8f05 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/matplotlib/modulesetup.md +++ b/mevislab.github.io/content/tutorials/thirdparty/matplotlib/modulesetup.md @@ -27,7 +27,7 @@ If you feel like using a shortcut, you can also download the base network below Your finished network should look like this: -![Base network](/images/tutorials/thirdparty/Matplotlib1.PNG) +![Base network](images/tutorials/thirdparty/Matplotlib1.PNG) {{< networkfile "/tutorials/thirdparty/matplotlib/MatplotlibBaseNetwork.mlab" >}} @@ -38,7 +38,7 @@ You will have noticed how, for every module, a panel will pop up if you double-c But where and how is a module panel created? To answer this question, please close the module panel and right-click on the module. A context menu will open, click on "Related Files". -![Context menu of the "SubImage" module](/images/tutorials/thirdparty/Matplotlib2.png) +![Context menu of the "SubImage" module](images/tutorials/thirdparty/Matplotlib2.png) As you can see, each module has a .script and a .py file, named like the module itself: + The .script file is, where the appearance and structure of the module panel as well as their commands are declared. @@ -50,9 +50,9 @@ Some modules also reference a .mlab file which usually contains their internal n If your network is ready, group it by right-clicking on your group's title and select "Grouping", then "Add To A New Group". After, convert your grouped network into a macro module. -![Converting to a macro](/images/tutorials/thirdparty/Matplotlib3.png) +![Converting to a macro](images/tutorials/thirdparty/Matplotlib3.png) {{}} -Information on how to convert groups into macros can be found [here](/tutorials/basicmechanisms#TutorialMacroModules). +Information on how to convert groups into macros can be found [here](tutorials/basicmechanisms#TutorialMacroModules). {{}} Depending on whether you like to reuse your projects in other workspaces, it can make sense to convert them. We'd recommend to do so. @@ -68,7 +68,7 @@ Now open the .script file of your newly created macro through the context menu. Click the "Reload" button that is located above the script for the .py file to be added into the module definition folder, then open it using the "Files" button on the same bar as demonstrated below: -![MATE](/images/tutorials/thirdparty/Matplotlib5.png) +![MATE](images/tutorials/thirdparty/Matplotlib5.png) {{}} The [MDL Reference](https://mevislabdownloads.mevis.de/docs/current/MeVisLab/Resources/Documentation/Publish/SDK/MDLReference/index.html) is a very handy tool for this and certainly also for following projects. diff --git a/mevislab.github.io/content/tutorials/thirdparty/matplotlib/slicecomparison.md b/mevislab.github.io/content/tutorials/thirdparty/matplotlib/slicecomparison.md index f7500b888..3e94558f2 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/matplotlib/slicecomparison.md +++ b/mevislab.github.io/content/tutorials/thirdparty/matplotlib/slicecomparison.md @@ -17,9 +17,9 @@ menu: ## Introduction We will adapt the previously created macro module to be able to overlay two defined slices to compare their grayscale distributions. -+ The module we are adapting has been set up in the [Example 1: Module Setup](/tutorials/thirdparty/matplotlib/modulesetup) tutorial. ++ The module we are adapting has been set up in the [Example 1: Module Setup](tutorials/thirdparty/matplotlib/modulesetup) tutorial. + The panel and two-dimensional plotting functionality has been added in [Example 2: 2D Plotting] - (/tutorials/thirdparty/matplotlib/2dplotting). + (tutorials/thirdparty/matplotlib/2dplotting). ## Steps to do At first, we will extend the panel: Open your `BaseNetwork` macro module within an empty MeVisLab workspace and select the .script file from its related files. @@ -45,7 +45,7 @@ Add the following code into your .script file, between the "Single Slice" and th Your panel should now be altered to look like this: -![MATE Preview](/images/tutorials/thirdparty/Matplotlib14.PNG) +![MATE Preview](images/tutorials/thirdparty/Matplotlib14.PNG) We will now add the "comparison" function, to give the "Plot" button in our "Comparison" box a purpose. To do so, change into your modules .py file and choose a cosy place for the following piece of code: @@ -80,8 +80,8 @@ def comparison(): You should now be able to reproduce results like these: -![Comparison](/images/tutorials/thirdparty/Matplotlib16.PNG) -![Comparison](/images/tutorials/thirdparty/Matplotlib17.PNG) +![Comparison](images/tutorials/thirdparty/Matplotlib16.PNG) +![Comparison](images/tutorials/thirdparty/Matplotlib17.PNG) ### Summary + Grayscale distributions of two slices can be layered to compare them and make deviations noticeable diff --git a/mevislab.github.io/content/tutorials/thirdparty/monai.md b/mevislab.github.io/content/tutorials/thirdparty/monai.md index bf98b389a..7d18bf734 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/monai.md +++ b/mevislab.github.io/content/tutorials/thirdparty/monai.md @@ -21,5 +21,5 @@ Created by [NVIDIA](https://docs.nvidia.com/monai/index.html "NVIDIA") and the L MONAI includes ready-to-use deep learning models (such as UNet and SegResNet) and utilities for segmentation, classification, and image registration. It supports distributed GPU training and ensures reproducible research workflows. ## Available Tutorials -* [Example 1: Install MONAI using PythonPip module](/tutorials/thirdparty/monai/monaiexample1/) -* [Example 2: Applying a spleen segmentation model from MONAI in MeVisLab](/tutorials/thirdparty/monai/monaiexample2/) +* [Example 1: Install MONAI using PythonPip module](tutorials/thirdparty/monai/monaiexample1/) +* [Example 2: Applying a spleen segmentation model from MONAI in MeVisLab](tutorials/thirdparty/monai/monaiexample2/) diff --git a/mevislab.github.io/content/tutorials/thirdparty/opencv/thirdpartyexample1.md b/mevislab.github.io/content/tutorials/thirdparty/opencv/thirdpartyexample1.md index 9d565c2fa..615ae8148 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/opencv/thirdpartyexample1.md +++ b/mevislab.github.io/content/tutorials/thirdparty/opencv/thirdpartyexample1.md @@ -21,7 +21,7 @@ In this example, we are using the `PythonImage` module and access your WebCam to ### Creating the network to be used for testing Add the modules to your workspace and connect them as seen below. -![Example Network ](/images/tutorials/thirdparty/network_example1.png "Example Network ") +![Example Network ](images/tutorials/thirdparty/network_example1.png "Example Network ") The viewer is empty because the image needs to be set via Python scripting. @@ -33,7 +33,7 @@ More information about the `PythonImage` module can be found {{< docuLinks "/Sta Now you need to create a macro module from your network. You can either group your modules, create a local macro and convert it to a global macro module, or you use the Project Wizard and load your \*.mlab file. {{}} -A tutorial how to create your own macro modules can be found in [Example 2.2: Global macro modules](/tutorials/basicmechanisms/macromodules/globalmacromodules "Example 2.2: Global macro modules"). Make sure to add a Python file to your macro module. +A tutorial how to create your own macro modules can be found in [Example 2.2: Global macro modules](tutorials/basicmechanisms/macromodules/globalmacromodules "Example 2.2: Global macro modules"). Make sure to add a Python file to your macro module. {{}} ### Add the View2D to your UI diff --git a/mevislab.github.io/content/tutorials/thirdparty/opencv/thirdpartyexample2.md b/mevislab.github.io/content/tutorials/thirdparty/opencv/thirdpartyexample2.md index d9e60708d..835ef010d 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/opencv/thirdpartyexample2.md +++ b/mevislab.github.io/content/tutorials/thirdparty/opencv/thirdpartyexample2.md @@ -23,7 +23,7 @@ The Python code used in this example has been taken from [Towards Data Science]( ## Steps to do ### Open Example 1 -Add the macro module developed in [Example 1](/tutorials/thirdparty/opencv/thirdpartyexample1) to your workspace. +Add the macro module developed in [Example 1](tutorials/thirdparty/opencv/thirdpartyexample1) to your workspace. ### Download trained classifier XML file Initially you need to download the trained classifier XML file. It is available in the [OpenCV GitHub repository](https://github.com/opencv/opencv/blob/master/data/haarcascades/haarcascade_frontalface_default.xml). Save the file somewhere and remember the path for later usage in Python. @@ -75,11 +75,11 @@ def releaseCamera(_): Opening your macro module and pressing *Start* should now open your WebCam stream and an additional OpenCV window which shows a blue rectangle around a detected face. -![Face Detection in MeVisLab using OpenCV](/images/tutorials/thirdparty/bigbang.png "Face Detection in MeVisLab using OpenCV") +![Face Detection in MeVisLab using OpenCV](images/tutorials/thirdparty/bigbang.png "Face Detection in MeVisLab using OpenCV") ## Summary This is just one example for using OpenCV in MeVisLab. You will find lots of other examples and tutorials online, we just wanted to show one possibility. {{}} -You can download the Python file [here](/examples/thirdparty/example2/FaceDetection.py) +You can download the Python file [here](examples/thirdparty/example2/FaceDetection.py) {{}} diff --git a/mevislab.github.io/content/tutorials/thirdparty/pytorch.md b/mevislab.github.io/content/tutorials/thirdparty/pytorch.md index fcf08e18b..8cbe07768 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/pytorch.md +++ b/mevislab.github.io/content/tutorials/thirdparty/pytorch.md @@ -35,5 +35,5 @@ The first example shows how to install *torch* and *torchvision* by using the Me In this example, we are using a pre-trained network from [torch.hub](https://pytorch.org/hub/) to generate an AI based image overlay of a brain parcellation map. ### Segment Persons in Webcam Videos -The second tutorial adapts the [Example 2: Face Detection with OpenCV](/tutorials/thirdparty/opencv/thirdpartyexample2/ "Example 2: Face Detection with OpenCV") to segment a person shown in a webcam stream. The network has been taken from [torchvision](https://pytorch.org/vision/stable/index.html). +The second tutorial adapts the [Example 2: Face Detection with OpenCV](tutorials/thirdparty/opencv/thirdpartyexample2/ "Example 2: Face Detection with OpenCV") to segment a person shown in a webcam stream. The network has been taken from [torchvision](https://pytorch.org/vision/stable/index.html). diff --git a/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample1.md b/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample1.md index ce65e9f02..46de8467a 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample1.md +++ b/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample1.md @@ -31,18 +31,18 @@ Installing additional Python packages into MeVisLab by using the `PythonPip` mod #### The PythonPip module Add a `PythonPip` module to your workspace. -![PythonPip module](/images/tutorials/thirdparty/pytorch_example1_1.png "PythonPip module") +![PythonPip module](images/tutorials/thirdparty/pytorch_example1_1.png "PythonPip module") Double-click {{< mousebutton "left" >}} the module and inspect the panel. -![PythonPip panel](/images/tutorials/thirdparty/pytorch_example1_2.png "PythonPip panel") +![PythonPip panel](images/tutorials/thirdparty/pytorch_example1_2.png "PythonPip panel") -The panel shows all currently installed Python packages including their version and the MeVisLab package they are saved in. You can see a warning that the target package is set to read-only in case you are selecting a MeVisLab package. Changing to one of your user packages (see [Example 2.1: Package creation](/tutorials/basicmechanisms/macromodules/package/) for details) makes the warning disappear. +The panel shows all currently installed Python packages including their version and the MeVisLab package they are saved in. You can see a warning that the target package is set to read-only in case you are selecting a MeVisLab package. Changing to one of your user packages (see [Example 2.1: Package creation](tutorials/basicmechanisms/macromodules/package/) for details) makes the warning disappear. -![Select user package](/images/tutorials/thirdparty/pytorch_example1_3.png "Select user package") +![Select user package](images/tutorials/thirdparty/pytorch_example1_3.png "Select user package") {{}} -Additional Information on the `PythonPip` module can be found in [Example 4: Install additional Python packages via PythonPip module](/tutorials/basicmechanisms/macromodules/pythonpip "PythonPip module"). +Additional Information on the `PythonPip` module can be found in [Example 4: Install additional Python packages via PythonPip module](tutorials/basicmechanisms/macromodules/pythonpip "PythonPip module"). {{}} #### Install torch and torchvision @@ -66,15 +66,15 @@ If you are behind a proxy server, you may have to set the **HTTP_PROXY** and **H Alternatively you can also add a parameter to *pip install* command: *--proxy https://proxy:port* {{}} -![Install torch and torchvision](/images/tutorials/thirdparty/pytorch_example1_4.png "Install torch and torchvision") +![Install torch and torchvision](images/tutorials/thirdparty/pytorch_example1_4.png "Install torch and torchvision") After clicking *Install*, the pip console output opens and you can follow the process of the installation. -![Python pip output](/images/tutorials/thirdparty/pytorch_example1_5.png "Python pip output") +![Python pip output](images/tutorials/thirdparty/pytorch_example1_5.png "Python pip output") After the installation was finished with exit code 0, you should see the new packages in the `PythonPip` module. -![PyTorch installed](/images/tutorials/thirdparty/pytorch_example1_6.png "PyTorch installed") +![PyTorch installed](images/tutorials/thirdparty/pytorch_example1_6.png "PyTorch installed") ## Summary * *PyTorch* can be installed using the `PythonPip` module. diff --git a/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample2.md b/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample2.md index 23083bb07..5a15afe01 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample2.md +++ b/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample2.md @@ -20,11 +20,11 @@ In this example, you are using a pre-trained PyTorch deep learning model (HighRe ## Steps to do Add a `LocalImage` module to your workspace and select the file *MRI_Head.dcm*. For PyTorch it is necessary to resample the data to a defined size. Add a `Resample3D` module to the `LocalImage` and open the panel. Change *Keep Constant* to *Voxel Size* and define *Image Size* as 176, 217, 160. -![Resample3D module](/images/tutorials/thirdparty/pytorch_example2_1.png "Resample3D module"). +![Resample3D module](images/tutorials/thirdparty/pytorch_example2_1.png "Resample3D module"). The coordinates in PyTorch are also a little different than in MeVisLab, therefore you have to rotate the image. Add an `OrthoSwapFlip` module and connect it to the `Resample3D` module. Change *View* to *Other* and set *Orientation* to *YXZ*. Also check *Flip horizontal*, *Flip vertical* and *Flip depth*. *Apply* your changes. -![OrthoSwapFlip module](/images/tutorials/thirdparty/pytorch_example2_2.png "OrthoSwapFlip module"). +![OrthoSwapFlip module](images/tutorials/thirdparty/pytorch_example2_2.png "OrthoSwapFlip module"). You can use the Output Inspector to see the changes on the images after applying the resample and a swap or flip. @@ -32,14 +32,14 @@ You can use the Output Inspector to see the changes on the images after applying Add an `OrthoView2D` module to your network and save the *\*.mlab* file. -![OrthoView2D module](/images/tutorials/thirdparty/pytorch_example2_3.png "OrthoView2D module"). +![OrthoView2D module](images/tutorials/thirdparty/pytorch_example2_3.png "OrthoView2D module"). ## Integrate PyTorch and scripting For integrating PyTorch and Python scripting, we need a `PythonImage` module. Add it to your workspace. Right-click {{< mousebutton "right" >}} on the `PythonImage` module and select {{< menuitem "Grouping" "Add to new Group...">}}. Right-click {{< mousebutton "right" >}} your new group and select {{< menuitem "Grouping" "Add to new Group...">}}. Name your new local macro *DemoAI*, select a directory for your project and leave all settings as default. Our new module does not provide an input or output. -![DemoAI local macro](/images/tutorials/thirdparty/pytorch_example2_4.png "DemoAI local macro"). +![DemoAI local macro](images/tutorials/thirdparty/pytorch_example2_4.png "DemoAI local macro"). ### Adding an interface to the local macro Right-click {{< mousebutton "right" >}} the local macro and select {{< menuitem "Related Files" "DemoAI.script">}}. MATE opens showing the *\*.script* file of our module. Add an input *Field* of type *Image*, an output *Field* using the *internalName* of the output of our `PythonImage` and a *Trigger* to start the segmentation. @@ -68,29 +68,29 @@ Commands { In MATE, right-click {{< mousebutton "right" >}} the Project Workspace and add a new file *DemoAI.py* to your project. The workspace now contains an empty Python file. -![Project Workspace](/images/tutorials/thirdparty/pytorch_example2_5.png "Project Workspace"). +![Project Workspace](images/tutorials/thirdparty/pytorch_example2_5.png "Project Workspace"). Change to MeVisLab IDE, right-click {{< mousebutton "right" >}} the local macro and select {{< menuitem "Reload Definition">}}. Your new input and output interface are now available and you can connect images to your module. -![DemoAI local macro with interfaces](/images/tutorials/thirdparty/pytorch_example2_6.png "DemoAI local macro with interfaces"). +![DemoAI local macro with interfaces](images/tutorials/thirdparty/pytorch_example2_6.png "DemoAI local macro with interfaces"). ### Extend your network -We want to show the segmentation results as an overlay on the original image. Add a `SoView2DOverlayMPR` module and connect it to your `DemoAI` macro. Connect the output of the `SoView2DOverlayMPR` to a `SoGroup`. We also need a lookup table for the colors to be used for the overlay. We already prepared a *\*.xml* file you can simply use. Download the [lut.xml](/examples/thirdparty/pytorch2/lut.xml) file and save it in your current working directory of the project. +We want to show the segmentation results as an overlay on the original image. Add a `SoView2DOverlayMPR` module and connect it to your `DemoAI` macro. Connect the output of the `SoView2DOverlayMPR` to a `SoGroup`. We also need a lookup table for the colors to be used for the overlay. We already prepared a *\*.xml* file you can simply use. Download the [lut.xml](examples/thirdparty/pytorch2/lut.xml) file and save it in your current working directory of the project. Add a `LoadBase` module and connect it to a `SoMLLUT` module. The `SoMLLUT` needs to be connected to the `SoGroup` so that it is applied to our segmentation results. -![Final network](/images/tutorials/thirdparty/pytorch_example2_7.png "Final network"). +![Final network](images/tutorials/thirdparty/pytorch_example2_7.png "Final network"). {{}} If your PC is equipped with less than 16GBs of RAM/working memory we recommend to add a `SubImage` module between the `OrthoSwapFlip` and the `Resample3D` module. You should configure less slices in z-direction to prevent your system from running out of memory. -![SubImage module](/images/tutorials/thirdparty/pytorch_example2_7b.png "SubImage module"). +![SubImage module](images/tutorials/thirdparty/pytorch_example2_7b.png "SubImage module"). {{}} Inspect the output of the `LoadBase` module in the Output Inspector to see if the lookup table has been loaded correctly. -![LUT in LoadBase](/images/tutorials/thirdparty/pytorch_example2_8.png "LUT in LoadBase"). +![LUT in LoadBase](images/tutorials/thirdparty/pytorch_example2_8.png "LUT in LoadBase"). ### Write Python script You can now execute the pre-trained PyTorch network on your image. Right-click {{< mousebutton "right" >}} the local macro and select {{< menuitem "Related Files" "DemoAI.script">}}. The Python function is supposed to be called whenever the *Trigger* is touched. @@ -164,11 +164,11 @@ Change alpha value of your `SoView2DOverlayMPR` to have a better visualization o Change to MeVisLab IDE and select your module `DemoAI`. In *Module Inspector* click *Trigger* for *start* and wait a little until you can see the results. -![Final result](/images/tutorials/thirdparty/pytorch_example2_9.png "Final result"). +![Final result](images/tutorials/thirdparty/pytorch_example2_9.png "Final result"). Without adding a `SubImage` the segmentation results should look like this: -![Results](/images/tutorials/thirdparty/pytorch_example2_10.png "Results"). +![Results](images/tutorials/thirdparty/pytorch_example2_10.png "Results"). ## Summary * Pre-trained PyTorch networks can be used directly in MeVisLab via `PythonImage` module diff --git a/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample3.md b/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample3.md index 2cfd97af0..3ace5ec63 100644 --- a/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample3.md +++ b/mevislab.github.io/content/tutorials/thirdparty/pytorch/pytorchexample3.md @@ -15,31 +15,31 @@ menu: # Example 3: Segment persons in webcam videos ## Introduction -This tutorial is based on [Example 2: Face Detection with OpenCV](/tutorials/thirdparty/opencv/thirdpartyexample2 "Example 2: Face Detection with OpenCV"). You can re-use some of the scripts already developed in the other tutorial. +This tutorial is based on [Example 2: Face Detection with OpenCV](tutorials/thirdparty/opencv/thirdpartyexample2 "Example 2: Face Detection with OpenCV"). You can re-use some of the scripts already developed in the other tutorial. ## Steps to do Add the macro module developed in the previous example to your workspace. -![WebCamTest module](/images/tutorials/thirdparty/pytorch_example3_1.png "WebCamTest module") +![WebCamTest module](images/tutorials/thirdparty/pytorch_example3_1.png "WebCamTest module") Open the internal network of the module via middle mouse button {{< mousebutton "middle" >}} and right click {{< mousebutton "right" >}} on the tab of the workspace showing the internal network. Select *Show Enclosing Folder*. -![Show Enclosing Folder](/images/tutorials/thirdparty/pytorch_example3_2.png "Show Enclosing Folder") +![Show Enclosing Folder](images/tutorials/thirdparty/pytorch_example3_2.png "Show Enclosing Folder") The file browser opens showing the files of your macro module. Copy the *\*.mlab* file somewhere you can remember. ### Create the macro module Open the the Project Wizard via {{< menuitem "File" "Run Project Wizard">}} and select *Macro Module*. Click *Run Wizard*. -![Project Wizard](/images/tutorials/thirdparty/pytorch_example3_3.png "Project Wizard") +![Project Wizard](images/tutorials/thirdparty/pytorch_example3_3.png "Project Wizard") Define the module properties as shown below, though you can chose your own name. Click *Next*. -![Module Properties](/images/tutorials/thirdparty/pytorch_example3_4.png "Module Properties") +![Module Properties](images/tutorials/thirdparty/pytorch_example3_4.png "Module Properties") Define the module properties and select the copied *\*.mlab* file. Make sure to add a Python file and click *Next*. -![Macro Module Properties](/images/tutorials/thirdparty/pytorch_example3_5.png "Macro Module Properties") +![Macro Module Properties](images/tutorials/thirdparty/pytorch_example3_5.png "Macro Module Properties") Leave the module field reference as is and click *Create*. Close Project Wizard and select {{< menuitem "Extras" "Reload Module Database (Clear Cache)">}}. @@ -146,22 +146,22 @@ def releaseCamera(_): ``` {{}} -You should now have the complete functionality of the [Example 2: Face Detection with OpenCV](/tutorials/thirdparty/opencv/thirdpartyexample2 "Example 2: Face Detection with OpenCV"). +You should now have the complete functionality of the [Example 2: Face Detection with OpenCV](tutorials/thirdparty/opencv/thirdpartyexample2 "Example 2: Face Detection with OpenCV"). ### Adapt the network For *PyTorch*, we require some additional modules in our network. Open the internal network of your module and add another `PythonImage` module. Connect a `Resample3D` and an `ImagePropertyConvert` module. In `Resample3D` module, define the *Image Size* 693, 520, 1. Change *VoxelSize* for all dimensions to 1. -![Resample3D](/images/tutorials/thirdparty/pytorch_example3_7.png "Resample3D") +![Resample3D](images/tutorials/thirdparty/pytorch_example3_7.png "Resample3D") Open the Panel of the `ImagePropertyConvert` module and check *World Matrix*. -![ImagePropertyConvert](/images/tutorials/thirdparty/pytorch_example3_9.png "ImagePropertyConvert") +![ImagePropertyConvert](images/tutorials/thirdparty/pytorch_example3_9.png "ImagePropertyConvert") Then add a `SoView2DOverlayMPR` module and connect it to the `ImagePropertyConvert` and the `View2D`. Change *Blend Mode* to *Blend*, *Alpha* to something between 0 and 1 and define a color for the overlay. -![SoView2DOverlayMPR](/images/tutorials/thirdparty/pytorch_example3_8.png "SoView2DOverlayMPR") +![SoView2DOverlayMPR](images/tutorials/thirdparty/pytorch_example3_8.png "SoView2DOverlayMPR") Save the internal network. @@ -317,7 +317,7 @@ The following classes are available: The final result of the segmentation should be a semi-transparent red overlay of the persons segmented in your webcam stream. -![Final Segmentation result](/images/tutorials/thirdparty/pytorch_example3_10.png "Final Segmentation result") +![Final Segmentation result](images/tutorials/thirdparty/pytorch_example3_10.png "Final Segmentation result") ## Summary * You can install additional Python AI packages by using the `PythonPip` module. diff --git a/mevislab.github.io/content/tutorials/visualization.md b/mevislab.github.io/content/tutorials/visualization.md index c08ddb608..7b34d346f 100644 --- a/mevislab.github.io/content/tutorials/visualization.md +++ b/mevislab.github.io/content/tutorials/visualization.md @@ -19,14 +19,14 @@ Images and data objects can be rendered in 2D and 3D and interacted with in seve In this chapter in particular, we will focus on simple image interaction with two- and three-dimensional visualizations. {{}} -Not only pixel- and voxel-based data, but also scene objects and 3D scenes can be visualized. See our tutorial on [OpenInventorModules](/tutorials/openinventor#TutorialOpenInventorModules) for further information. +Not only pixel- and voxel-based data, but also scene objects and 3D scenes can be visualized. See our tutorial on [OpenInventorModules](tutorials/openinventor#TutorialOpenInventorModules) for further information. {{}} ## View2D and View3D An easy way to display data and images in 2D and 3D is by using the Modules `View2D` and `View3D`. What can be done with these viewers? -![View2D and View3D](/images/tutorials/visualization/V0.png "View2D and View3D") +![View2D and View3D](images/tutorials/visualization/V0.png "View2D and View3D") ### View2D @@ -41,7 +41,7 @@ An easy way to display data and images in 2D and 3D is by using the Modules `Vie 5. More features can be found on the help page. {{}} -The `View2DExtensions` module provides additional ways to interact with an image. ![View2DExtensions](/images/tutorials/visualization/V0a.png "View2DExtensions") +The `View2DExtensions` module provides additional ways to interact with an image. ![View2DExtensions](images/tutorials/visualization/V0a.png "View2DExtensions") {{}} ### View3D diff --git a/mevislab.github.io/content/tutorials/visualization/pathtracer/pathtracerexample1.md b/mevislab.github.io/content/tutorials/visualization/pathtracer/pathtracerexample1.md index 2a7ae84f2..8b1646148 100644 --- a/mevislab.github.io/content/tutorials/visualization/pathtracer/pathtracerexample1.md +++ b/mevislab.github.io/content/tutorials/visualization/pathtracer/pathtracerexample1.md @@ -37,46 +37,46 @@ For *RenderSphere1*, define a *Diffuse Color* *yellow* and set *Face Alpha* to * Group your modules and name the group *Initialization*. Your network should now look like this: -![Example Initialization](/images/tutorials/visualization/pathtracer/Example1_1.png "Example Initialization") +![Example Initialization](images/tutorials/visualization/pathtracer/Example1_1.png "Example Initialization") Use the Output Inspector for your `SoWEMRenderer` outputs and inspect the 3D rendering. You should have a yellow and a red sphere, and a grey cube. -{{< imagegallery 3 "/images/tutorials/visualization/pathtracer" "Sphere1" "Sphere2" "Cube" >}} +{{< imagegallery 3 "images/tutorials/visualization/pathtracer" "Sphere1" "Sphere2" "Cube" >}} #### Rendering Add 2 `SoGroup` modules and a `SoBackground` to your network. Connect the modules as seen below. -![Example Group](/images/tutorials/visualization/pathtracer/Example1_2.png "Example Group") +![Example Group](images/tutorials/visualization/pathtracer/Example1_2.png "Example Group") If you now inspect the output of the `SoGroup`, you will see an orange sphere. -![Missing Translation](/images/tutorials/visualization/pathtracer/Example1_3.png "Missing Translation") +![Missing Translation](images/tutorials/visualization/pathtracer/Example1_3.png "Missing Translation") You did not translate the locations of the three objects; they are all located at the same place in world coordinates. Open the `WEMInitialize` panels of your 3D objects and define the following translations and scalings: -{{< imagegallery 3 "/images/tutorials/visualization/pathtracer" "WEMInitializeSphere1" "WEMInitializeSphere2" "WEMInitializeCube" >}} +{{< imagegallery 3 "images/tutorials/visualization/pathtracer" "WEMInitializeSphere1" "WEMInitializeSphere2" "WEMInitializeCube" >}} The result of the `SoGroup` now shows two spheres on a rectangular cube. -![Objects Translated and Scaled](/images/tutorials/visualization/pathtracer/Example1_4.png "Objects Translated and Scaled") +![Objects Translated and Scaled](images/tutorials/visualization/pathtracer/Example1_4.png "Objects Translated and Scaled") For the viewer, you now add a `SoCameraInteraction`, a `SoDepthPeelRenderer`, and a `SoRenderArea` module to your network and connect them. -![Network with Viewer](/images/tutorials/visualization/pathtracer/Example1_5.png "Network with Viewer") +![Network with Viewer](images/tutorials/visualization/pathtracer/Example1_5.png "Network with Viewer") You now have a 3D volume rendering of our three objects. In order to distinguish between the two viewers, you now add a label to the `SoRenderArea` describing that this is the *Volume Rendering*. Add a `SoMenuItem`, a `SoBorderMenu`, and a `SoSeparator` to your `SoRenderArea`. -![SoMenuItem](/images/tutorials/visualization/pathtracer/Example1_6.png "SoMenuItem") +![SoMenuItem](images/tutorials/visualization/pathtracer/Example1_6.png "SoMenuItem") Define the *Label* of the `SoMenuItem` as *Volume Rendering* and set *Border Alignment* to *Top Right* and *Menu Direction* to *Horizontal* for the `SoBorderMenu`. -![Label in SoRenderArea](/images/tutorials/visualization/pathtracer/Example1_7.png "Label in SoRenderArea") +![Label in SoRenderArea](images/tutorials/visualization/pathtracer/Example1_7.png "Label in SoRenderArea") Finally, you should group all modules belonging to your volume rendering. -![Volume Rendering Network](/images/tutorials/visualization/pathtracer/Example1_8.png "Volume Rendering Network") +![Volume Rendering Network](images/tutorials/visualization/pathtracer/Example1_8.png "Volume Rendering Network") ### Path Tracing For the Path Tracer, you can just re-use our 3D objects from volume rendering. This helps us to compare the rendering results. @@ -84,42 +84,42 @@ For the Path Tracer, you can just re-use our 3D objects from volume rendering. T #### Rendering Path Tracer modules fully integrate into MeVisLab Open Inventor, therefore the general principles and the necessary modules are not completely different. Add a `SoGroup` module to your workspace and connect it to your 3D objects from `SoWEMRenderer`. A `SoBackground` as in volume rendering network is not necessary but you add a `SoPathTracerMaterial` and connect it to the `SoGroup`. You can leave all settings as default for now. -![Path Tracer Material](/images/tutorials/visualization/pathtracer/Example1_9.png "Path Tracer Material") +![Path Tracer Material](images/tutorials/visualization/pathtracer/Example1_9.png "Path Tracer Material") Add a `SoPathTracerAreaLight`, a `SoPathTracerMesh`, and a `SoPathTracer` to a `SoSeparator` and connect the `SoPathTracerMesh` to your `SoGroup`. This adds your 3D objects to a Path Tracer Scene. -![Path Tracer](/images/tutorials/visualization/pathtracer/Example1_10.png "Path Tracer") +![Path Tracer](images/tutorials/visualization/pathtracer/Example1_10.png "Path Tracer") Selecting the `SoSeparator` output already shows a preview of the same scene rendered via Path Tracing. -![Path Tracer Preview](/images/tutorials/visualization/pathtracer/Example1_11.png "Path Tracer Preview") +![Path Tracer Preview](images/tutorials/visualization/pathtracer/Example1_11.png "Path Tracer Preview") Add a `SoCameraInteraction` and a `SoRenderArea` to your network and connect them as seen below. -![SoCameraInteraction](/images/tutorials/visualization/pathtracer/Example1_12.png "SoCameraInteraction") +![SoCameraInteraction](images/tutorials/visualization/pathtracer/Example1_12.png "SoCameraInteraction") You can now use both `SoRenderArea` modules to visualize the differences side by side. You should also add the `SoMenuItem`, a `SoBorderMenu`, and a `SoSeparator` to your `SoRenderArea` in order to have a label for Path Tracing inside the viewer. Define the *Label* of the `SoMenuItem` as *Path Tracing* and set *Border Alignment* to *Top Right* and *Menu Direction* to *Horizontal* for the `SoBorderMenu`. -![Label in SoRenderArea](/images/tutorials/visualization/pathtracer/Example1_13.png "Label in SoRenderArea") +![Label in SoRenderArea](images/tutorials/visualization/pathtracer/Example1_13.png "Label in SoRenderArea") Finally, group your Path Tracer modules to another group named *Path Tracing*. -![New Group for Path Tracing](/images/tutorials/visualization/pathtracer/Example1_14.png "New Group for Path Tracing") +![New Group for Path Tracing](images/tutorials/visualization/pathtracer/Example1_14.png "New Group for Path Tracing") -![Side by Side](/images/tutorials/visualization/pathtracer/Example1_15.png "Side by Side") +![Side by Side](images/tutorials/visualization/pathtracer/Example1_15.png "Side by Side") ### Share the Same Camera Finally, you want to have the same camera perspective in both viewers so that you can see the differences. Add a `SoPerspectiveCamera` module to your workspace and connect it to the volume rendering and the Path Tracer network. The Path Tracer network additionally needs a SoGroup, see below for connection details. You have to toggle *detectCamera* in both of your `SoCameraInteraction` modules in order to synchronize the view for both `SoRenderArea` viewers. -![Camera Synchronization](/images/tutorials/visualization/pathtracer/Example1_16.png "Camera Synchronization") +![Camera Synchronization](images/tutorials/visualization/pathtracer/Example1_16.png "Camera Synchronization") {{}} Path Tracing requires a lot of iterations before reaching the best possible result. You can see the maximum number of iterations defined and the current iteration in the `SoPathTracer` panel. The more iterations, the better the result but the more time it takes to finalize your image. {{}} -{{< imagegallery 3 "/images/tutorials/visualization/pathtracer" "PathTracer_1_Iteration" "PathTracer_100_Iterations" "PathTracer_1000_Iterations" >}} +{{< imagegallery 3 "images/tutorials/visualization/pathtracer" "PathTracer_1_Iteration" "PathTracer_100_Iterations" "PathTracer_1000_Iterations" >}} ## Results Path Tracing provides a much more realistic way to visualize the behavior of light in a scene. It simulates the scattering and absorption of light within the volume. diff --git a/mevislab.github.io/content/tutorials/visualization/pathtracer/pathtracerexample2.md b/mevislab.github.io/content/tutorials/visualization/pathtracer/pathtracerexample2.md index 9539ca0d4..def5d9119 100644 --- a/mevislab.github.io/content/tutorials/visualization/pathtracer/pathtracerexample2.md +++ b/mevislab.github.io/content/tutorials/visualization/pathtracer/pathtracerexample2.md @@ -26,9 +26,9 @@ The MeVis Path Tracer requires an NVIDIA graphics card with CUDA support. In ord ## Steps to Do ### Develop Your Network -Download and open the [images](/examples/visualization/example6/Volume_1.mlimage) by using a `LocalImage` module. Connect it to a `View2D` to visually inspect its contents. +Download and open the [images](examples/visualization/example6/Volume_1.mlimage) by using a `LocalImage` module. Connect it to a `View2D` to visually inspect its contents. -![MR Image of Knee](/images/tutorials/visualization/pathtracer/V6.2_1.png "MR Image of Knee in 2D") +![MR Image of Knee](images/tutorials/visualization/pathtracer/V6.2_1.png "MR Image of Knee in 2D") Replace the `View2D` module by a `SoExaminerViewer`. Add the modules `SoPathTracerVolume` and `SoPathTracer` to your workspace and connect them as seen below. @@ -38,21 +38,21 @@ The `SoPathTracerVolume` enables the loading and transforming the data into rend It's essential to consistently position the `SoPathTracer `module on the right side of the scene. This strategic placement ensures that the module can render all objects located in the scene before it accurately. {{}} -![SoPathTracerVolume & SoPathTracer](/images/tutorials/visualization/pathtracer/V6.2_2.png "SoPathTracerVolume & SoPathTracer") +![SoPathTracerVolume & SoPathTracer](images/tutorials/visualization/pathtracer/V6.2_2.png "SoPathTracerVolume & SoPathTracer") If you check your `SoExaminerViewer` you will see a black box. We need to define a LUT for the gray values first. -![SoExaminerViewer](/images/tutorials/visualization/pathtracer/V6.2_3.png "SoExaminerViewer") +![SoExaminerViewer](images/tutorials/visualization/pathtracer/V6.2_3.png "SoExaminerViewer") Now connect the `SoLUTEditor` module to your `SoPathTracerVolume` as illustrated down below and you will be able to see the knee. -![SoLUTEditor](/images/tutorials/visualization/pathtracer/SoLUTEditor1.png "SoLUTEditor") +![SoLUTEditor](images/tutorials/visualization/pathtracer/SoLUTEditor1.png "SoLUTEditor") Add a `MinMaxScan` module to the `LocalImage` module and open the panel. The module shows the minimal and maximal gray values of the volume. Open the panel of the `SoLUTEditor` module and define Range between *0* and *2047* as calculated by the `MinMaxScan`. -![SoLUTEditor](/images/tutorials/visualization/pathtracer/Range_MinMaxScan.png "MinMaxScan") +![SoLUTEditor](images/tutorials/visualization/pathtracer/Range_MinMaxScan.png "MinMaxScan") Next, add lights to your scene. Connect a `SoPathTracerAreaLight` and a `SoPathTracerBackgroundLight` module to your `SoExaminerViewer` to improve scene lighting. @@ -60,27 +60,27 @@ The `SoPathTracerAreaLight` module provides a physically based area light that i The `SoPathTracerBackgroundLight` module provides a background light for the `SoPathTracer`. It supports setting a top, middle, and bottom color or alternatively, it support image based lighting (IBL) using a sphere or cube map. Only one background light can be active for a given `SoPathTracer`. -![Lights](/images/tutorials/visualization/pathtracer/Lights2.png "Lights") +![Lights](images/tutorials/visualization/pathtracer/Lights2.png "Lights") Open the panel of the `SoPathTracerBackgroundLight` module and choose your three colors. -![SoPathTracerBackgroundLight](/images/tutorials/visualization/pathtracer/BackgroundLight.png "SoPathTracerBackgroundLight") +![SoPathTracerBackgroundLight](images/tutorials/visualization/pathtracer/BackgroundLight.png "SoPathTracerBackgroundLight") #### Manually Define LUT Either define your desired colors for your LUT in the *Editor* tab manually as shown down below. -![LUT](/images/tutorials/visualization/pathtracer/V6.2_LUTandSoExaminerViewer.png "LUT") +![LUT](images/tutorials/visualization/pathtracer/V6.2_LUTandSoExaminerViewer.png "LUT") #### Load Example LUT from File -As an alternative, you can replace the `SoLUTEditor` with a `LUTLoad` and load this [XML file](/examples/visualization/example6/LUT_Original.xml) to use a pre-defined LUT. +As an alternative, you can replace the `SoLUTEditor` with a `LUTLoad` and load this [XML file](examples/visualization/example6/LUT_Original.xml) to use a pre-defined LUT. -![LUTLoad](/images/tutorials/visualization/pathtracer/LUTLoad.png "LUTLoad") +![LUTLoad](images/tutorials/visualization/pathtracer/LUTLoad.png "LUTLoad") Now, let's enhance your rendering further by using the `SoPathTracerMaterial` module. This module provides essential material properties for geometry and volumes within the `SoPathTracer` scene. Add a `SoPathTracerMaterial` module to your `SoPathTracerVolume`. Open it’s panel and navigate to the tab *Surface Brdf*. Change the *Diffuse* color for altering the visual appearance of surfaces. The *Diffuse* color determines how light interacts with the surface, influencing its overall color and brightness. Set *Specular* to *0.5*, *Shininess* to *1.0*, and *Specular Intensity* to *0.5*. -![SoPathTracerMaterial](/images/tutorials/visualization/pathtracer/SoPathTracerMaterial_Knee.png "SoPathTracerMaterial") +![SoPathTracerMaterial](images/tutorials/visualization/pathtracer/SoPathTracerMaterial_Knee.png "SoPathTracerMaterial") {{}} The resulting rendering in `SoExaminerViewer` might look different depending on your defined LUT. @@ -93,54 +93,54 @@ As the LUT of the second volume also differs, add another `SoLUTEditor` module o For later usage, you can also already add a `SoPathTracerMaterial` module to the `SoPathTracerVolume` module. -Load the [Bones mask](/examples/visualization/example6/edited_Bones.mlimage) by using the new `LocalImage` module and preview it in a `View2D`. +Load the [Bones mask](examples/visualization/example6/edited_Bones.mlimage) by using the new `LocalImage` module and preview it in a `View2D`. -![Bones mask](/images/tutorials/visualization/pathtracer/View2D_Bones.png "Bones mask") +![Bones mask](images/tutorials/visualization/pathtracer/View2D_Bones.png "Bones mask") Start by disabling the visibility of your first volume by toggeling `SoPathTracerVolume` *Enabled* field to off. This helps improve the rendering of the bones itself and makes it easier to define colors for your LUT. #### Load Example LUT from File -Once again, you can decide to define the LUT yourself in `SoLUTEditor` module, or load a prepared XML File in a `LUTLoad` module as provided [here](/examples/visualization/example6/LUT_Bones.xml). +Once again, you can decide to define the LUT yourself in `SoLUTEditor` module, or load a prepared XML File in a `LUTLoad` module as provided [here](examples/visualization/example6/LUT_Bones.xml). #### Manually Define LUT If you want to define your own LUT, connect a `MinMaxScan` module to your `LocalImage1` and define Range for the `SoLUTEditor` as already done before. -![MinMaxScan of Bones mask](/images/tutorials/visualization/pathtracer/MinMaxScan_Bones.png "MinMaxScan of Bones mask") +![MinMaxScan of Bones mask](images/tutorials/visualization/pathtracer/MinMaxScan_Bones.png "MinMaxScan of Bones mask") Open the panel of `SoLUTEditor1` for the bones and go to tab *Range* and set *New Range Min* to *0* and *New Range Max* to *127*. Define the following colors in the tab *Editor*. -![SoLUTEditor1](/images/tutorials/visualization/pathtracer/V6.2_11_LUT_Bones.png "SoLUTEditor1") +![SoLUTEditor1](images/tutorials/visualization/pathtracer/V6.2_11_LUT_Bones.png "SoLUTEditor1") You can increase the *Shininess* of the bones and change the *Diffuse* color in the *Surface Brdf* tab within the `SoPathTracerMaterial1`. Also set *Specular* to *0.5*, *Shininess* to *0.904*, and *Specular Intensity* to *0.466*. -![SoPathTracerMaterial1](/images/tutorials/visualization/pathtracer/V6.2_SoPathTracerMaterial.png "SoPathTracerMaterial1") +![SoPathTracerMaterial1](images/tutorials/visualization/pathtracer/V6.2_SoPathTracerMaterial.png "SoPathTracerMaterial1") ## Visualize Vessels -Repeat the process for the vessels. Add another `LocalImage`, `SoPathTracerVolume`, `SoLUTEditor` (or `LUTLoad`), and `View2D` module as seen below. Load this [Vessels mask](/examples/visualization/example6/edited_Vessels.mlimage) and check it using `View2D`. +Repeat the process for the vessels. Add another `LocalImage`, `SoPathTracerVolume`, `SoLUTEditor` (or `LUTLoad`), and `View2D` module as seen below. Load this [Vessels mask](examples/visualization/example6/edited_Vessels.mlimage) and check it using `View2D`. -![Vessels mask](/images/tutorials/visualization/pathtracer/View2D_Vessels.png "Vessels mask") +![Vessels mask](images/tutorials/visualization/pathtracer/View2D_Vessels.png "Vessels mask") #### Load Example LUT from File -Load a prepared XML File in a `LUTLoad` module as provided [here](/examples/visualization/example6/LUT_Vessels.xml) +Load a prepared XML File in a `LUTLoad` module as provided [here](examples/visualization/example6/LUT_Vessels.xml) #### Manually Define LUT Connect the `MinMaxScan` to your `LocalImage2`. Access the `SoLUTEditor2` panel in the tab *Range* and set the *New Range Min* to *0* and the *New Range Max* to *255*. Additionally, modify the illustrated color settings within the *Editor* tab. -![Vessels](/images/tutorials/visualization/pathtracer/MinMaxScan_Vessels.png "MinMaxScan of Vessels mask") +![Vessels](images/tutorials/visualization/pathtracer/MinMaxScan_Vessels.png "MinMaxScan of Vessels mask") -![SoLUTEditor2](/images/tutorials/visualization/pathtracer/V6.2_SoLUTEditor1_Vessels.png "SoLUTEditor2") +![SoLUTEditor2](images/tutorials/visualization/pathtracer/V6.2_SoLUTEditor1_Vessels.png "SoLUTEditor2") Now you should set your first volume visible again by toggling `SoPathTracerVolume` *Enabled* field to on. -![Final Resul](/images/tutorials/visualization/pathtracer/FinalResult.png "Final Result") +![Final Resul](images/tutorials/visualization/pathtracer/FinalResult.png "Final Result") {{}} The resulting rendering in `SoExaminerViewer` might look different depending on your defined LUTs. {{}} -![Final Resul](/images/tutorials/visualization/pathtracer/FinalResult2.png "Final Result with Enhanced Visualization") +![Final Resul](images/tutorials/visualization/pathtracer/FinalResult2.png "Final Result with Enhanced Visualization") ## Summary: * You can achieve photorealistic renderings using `SoPathTracer` and associated modules. diff --git a/mevislab.github.io/content/tutorials/visualization/visualizationexample1.md b/mevislab.github.io/content/tutorials/visualization/visualizationexample1.md index 537f056e1..fe42918e9 100644 --- a/mevislab.github.io/content/tutorials/visualization/visualizationexample1.md +++ b/mevislab.github.io/content/tutorials/visualization/visualizationexample1.md @@ -18,7 +18,7 @@ In this example we like to use the module `SynchroView2D` to be able to inspect The module `SynchroView2D` provides two 2D viewers that are synchronized. -As in Tutorial [Chapter 1 - Basic Mechanics of MeVisLab](/tutorials/basicmechanisms/#TutorialParameterConnection), the processed and the unprocessed image can be displayed simultaneously. Scrolling through one image automatically changes the slices of both viewers, so slices with the same slice number are shown in both images. +As in Tutorial [Chapter 1 - Basic Mechanics of MeVisLab](tutorials/basicmechanisms/#TutorialParameterConnection), the processed and the unprocessed image can be displayed simultaneously. Scrolling through one image automatically changes the slices of both viewers, so slices with the same slice number are shown in both images. The difference is that we are now using an already existing module named `SynchroView2D`. @@ -32,7 +32,7 @@ The `SynchroView2D` module is explained {{< docuLinks "/Standard/Documentation/P ### Develop Your Network Start the example by adding the module `LocalImage` to your workspace to load the example image *Tumor1_Head_t1.small.tif*. Next, add and connect the following modules as shown. -![SynchroView2D](/images/tutorials/visualization/V1_01.png "SynchroView2D Viewer") +![SynchroView2D](images/tutorials/visualization/V1_01.png "SynchroView2D Viewer") ## Summary * Multiple images can be synchronized by the `SynchroView2D` module diff --git a/mevislab.github.io/content/tutorials/visualization/visualizationexample2.md b/mevislab.github.io/content/tutorials/visualization/visualizationexample2.md index 887840147..e27b5ceaa 100644 --- a/mevislab.github.io/content/tutorials/visualization/visualizationexample2.md +++ b/mevislab.github.io/content/tutorials/visualization/visualizationexample2.md @@ -21,7 +21,7 @@ Medical images are typically displayed in three different viewing directions (se Using the viewer `OrthoView2D` you are able to decide which viewing direction you like to use. In addition to that, you have the opportunity to display all three orthogonal viewing directions simultaneously. Here, we like to display an image of the head in all three viewing directions and mark positions in the image. -![Body Planes](/images/tutorials/visualization/V2_00.png "Body Planes") +![Body Planes](images/tutorials/visualization/V2_00.png "Body Planes") ## Steps to Do ### Develop Your Network @@ -32,35 +32,35 @@ In this example, use the module `LocalImage` to load the example *image MRI_Head In the case your image is black, change the *Window* and *Center* values by moving the mouse with right mouse button {{< mousebutton "right" >}} pressed. {{}} -![OrthoView2D](/images/tutorials/visualization/V2_01.png "OrthoView2D") +![OrthoView2D](images/tutorials/visualization/V2_01.png "OrthoView2D") ### SoView2DPosition Next, we add the module `SoView2DPosition` (an Open Inventor module). The module enables the selection of an image position via mouse click {{< mousebutton "left" >}}. The last clicked location in the viewer is marked in white. If you now scroll through the slices, both, the last clicked location and the current image location are shown. -![SoView2DPosition](/images/tutorials/visualization/V2_02.png "SoView2DPosition") +![SoView2DPosition](images/tutorials/visualization/V2_02.png "SoView2DPosition") ### SoView2DRectangle Instead of points, we like to mark areas. In order to do that, replace the module `SoView2DPosition` with the module `SoView2DRectangle`. The module allows to add a rectangle to the image. Left-click {{< mousebutton "left" >}} on the image and draw a rectangle. In the `OthoView2D`, the rectangle is displayed in every viewing direction. -![SoView2DRectangle](/images/tutorials/visualization/V2_03.png "SoView2DRectangle") +![SoView2DRectangle](images/tutorials/visualization/V2_03.png "SoView2DRectangle") ### Using a rectangle to build a magnifier We like to use the module `SoView2DRectangle` to create a magnifier. In order to do that add the following modules to your workspace and connect them as shown below. We need to connect the module `SoView2DRectangle` to a hidden input connector of the module `SynchroView2D`. To be able to do this, click on your workspace and afterwards press {{< keyboard "SPACE" >}}. You can see that `SynchroView2D` possesses Open Inventor input connectors. You can connect your module `SoView2DRectangle` to one of these connectors. -![Hidden Inputs of SynchroView2D](/images/tutorials/visualization/V2_05.png "Hidden Inputs of SynchroView2D") +![Hidden Inputs of SynchroView2D](images/tutorials/visualization/V2_05.png "Hidden Inputs of SynchroView2D") -![Connect Hidden Inputs of SynchroView2D](/images/tutorials/visualization/V2_06.png "Connect Hidden Inputs of SynchroView2D") +![Connect Hidden Inputs of SynchroView2D](images/tutorials/visualization/V2_06.png "Connect Hidden Inputs of SynchroView2D") In addition to that, add two types of the module `DecomposeVector3` to your network. In MeVisLab, different data types exist, for example, vectors, or single variables, which contain the data type float or integer. This module can be used to convert field values of type vector (in this case a vector consisting of three entries) into three single coordinates. You will see in the next step why this module can be useful. -![DecomposeVector3](/images/tutorials/visualization/V2_07.png "DecomposeVector3") +![DecomposeVector3](images/tutorials/visualization/V2_07.png "DecomposeVector3") We like to use the module `SubImage` to select a section of a slice, which is then displayed in the viewer. The idea is to display a magnified section of one slice next to the whole slice in the module `SynchroView2D`. In order to do that, we need to tell the module `SubImage` which section to display in the viewer. The section is selected using the module `SoView2DRectangle`. As a last step, we need to transmit the coordinates of the chosen rectangle to the module `SubImage`. To do that, we will build some parameter connections. -![SubImage](/images/tutorials/visualization/V2_08.png "SubImage") +![SubImage](images/tutorials/visualization/V2_08.png "SubImage") Now, open the panels of the modules `SoView2DRectangle`, `DecomposeVector3`, and `DecomposeVector31`. @@ -70,7 +70,7 @@ In the panel of the module `Rectangle` in the box Position you can see the posit We like to use the modules `DecomposeVector3` to extract the single x, y, and z values of the vector. For that, create a parameter connection from the field *Start Wold Pos* to the vector of the module we named `StartWorldPos_Rectangle` and create a connection from the field *End World Pos* to the vector of module `EndWorldPos_Rectangle`. The decomposed coordinates can be now used for further parameter connections. -![Parameter Connections](/images/tutorials/visualization/V2_09.png "Parameter Connections") +![Parameter Connections](images/tutorials/visualization/V2_09.png "Parameter Connections") Open the panel of the module `SubImage`. Select the *Mode World Start & End* (*Image Axis Aligned*). Enable the function *Auto apply*. @@ -78,15 +78,15 @@ Open the panel of the module `SubImage`. Select the *Mode World Start & End* (*I Make sure to also check *Auto-correct for negative subimage extents* so that you can draw rectangles from left to right and from right to left. {{}} -![World Coordinates](/images/tutorials/visualization/V2_10.png "World Coordinates") +![World Coordinates](images/tutorials/visualization/V2_10.png "World Coordinates") Now, create parameter connections from the fields *X*, *Y*, *Z* of the module `StartWorldPos_Rectangle` to the field *Start X*, *Start Y*, *Start Z* in the panel of the module `SubImage`. Similarly, connect the parameter fields *X*, *Y*, *Z* of the module `EndWorldPos_Rectangle` to the field *End X*, *End Y*, *End Z* in the panel of the module `SubImage`. -![Another Parameter Connection](/images/tutorials/visualization/V2_11.png "Another Parameter Connection") +![Another Parameter Connection](images/tutorials/visualization/V2_11.png "Another Parameter Connection") With this, you finished your magnifier. Open the viewer and draw a rectangle on one slice to see the result. -![Final Magnifier with SubImage](/images/tutorials/visualization/V2_12.png "Final Magnifier with SubImage") +![Final Magnifier with SubImage](images/tutorials/visualization/V2_12.png "Final Magnifier with SubImage") ## Exercises Invert the image inside your magnified `SubImage` without changing the original image. You can use `Arithmetic*` modules for inverting. diff --git a/mevislab.github.io/content/tutorials/visualization/visualizationexample3.md b/mevislab.github.io/content/tutorials/visualization/visualizationexample3.md index c06cd3354..1280e7d99 100644 --- a/mevislab.github.io/content/tutorials/visualization/visualizationexample3.md +++ b/mevislab.github.io/content/tutorials/visualization/visualizationexample3.md @@ -37,12 +37,12 @@ The module `Threshold` compares the value of each voxel of the image with a cust Select output of the `Threshold` module to see the binary image in Output Inspector. -![Image Threshold](/images/tutorials/visualization/V3_01.png "Image Threshold") +![Image Threshold](images/tutorials/visualization/V3_01.png "Image Threshold") ### Overlays The module `SoView2DOverlay` blends a 2D image over another one in a 2D viewer. In this case, all voxels with a value above the `Threshold` are colored and therefore highlighted. The colored voxels are then blended over the original image. Using the panel of `SoView2DOverlay`, you can select the color of the overlay. -![SoView2DOverlay](/images/tutorials/visualization/V3_02.png "SoView2DOverlay") +![SoView2DOverlay](images/tutorials/visualization/V3_02.png "SoView2DOverlay") {{}} @@ -59,7 +59,7 @@ The `SoView2DOverlay` module is explained {{< docuLinks "/Standard/Documentation ## Summary * The module `Threshold` applies a relative or an absolute threshold to a voxel image. * The module `SoView2DOverlay` blends an 2D image over another one in a 2D viewer. -* You can also use a 3D `SoRenderArea` for the same visualizations. An example can be seen in the next [Example 4](/tutorials/visualization/visualizationexample4 "Display images converted to Open Inventor scene objects"). +* You can also use a 3D `SoRenderArea` for the same visualizations. An example can be seen in the next [Example 4](tutorials/visualization/visualizationexample4 "Display images converted to Open Inventor scene objects"). {{}} The `SoView2DOverlay` module is not intended to work with `OrthoView2D`; in this case, use a `GVROrthoOverlay`. diff --git a/mevislab.github.io/content/tutorials/visualization/visualizationexample4.md b/mevislab.github.io/content/tutorials/visualization/visualizationexample4.md index c80e4a391..c1bb03cfc 100644 --- a/mevislab.github.io/content/tutorials/visualization/visualizationexample4.md +++ b/mevislab.github.io/content/tutorials/visualization/visualizationexample4.md @@ -31,22 +31,22 @@ More information about the SoView2D family can be found {{< docuLinks "/Resource ### Develop Your Network We will start the example by creating an overlay again. Add the following modules and connect them as shown. Select a *Threshold* and a *Comparison Operator* for the module `Threshold` as in the previous example. The module `SoView2D` converts the image into a scene object. The image as well as the overlay is rendered and displayed by the module `SoRenderArea`. -![SoRenderArea](/images/tutorials/visualization/V4_01.png "SoRenderArea") +![SoRenderArea](images/tutorials/visualization/V4_01.png "SoRenderArea") ### Add Extension You may have noticed that you are not able to scroll through the slices. This functionality is not implemented in the viewer `SoRenderArea`. To add a set of functionalities and viewer extensions, which are commonly used in conjunction with a 2D viewer, add the module `View2DExtensions` to the workspace and connect it as shown below. Now, additional information of the image can be displayed in the viewer and you can navigate and scroll through the slices. -![View2DExtensions](/images/tutorials/visualization/V4_02.png "View2DExtensions") +![View2DExtensions](images/tutorials/visualization/V4_02.png "View2DExtensions") ### Add Screenshot Gallery to Viewing Area With the help of the module `SoRenderArea` you can record screenshots and movies. Before we do that, open {{< menuitem "View" "Views" "Screenshot Gallery" >}}, to add the Screenshot Gallery to your viewing area. -![Screenshot Gallery](/images/tutorials/visualization/V4_03.png "Screenshot Gallery") +![Screenshot Gallery](images/tutorials/visualization/V4_03.png "Screenshot Gallery") ### Create Screenshots and Movies If you now select your favorite slice of the bone in the Viewer `SoRenderArea` and press {{< keyboard "F11" >}}, a screenshot is taken and displayed in the Screenshot Gallery. For recording a movie, press {{< keyboard "F9" >}} to start the movie and {{< keyboard "F10" >}} to stop recording. You can find the movie in the Screenshot Gallery. -![Record Movies and Snapshots](/images/tutorials/visualization/V4_05.png "Record Movies and Snapshots") +![Record Movies and Snapshots](images/tutorials/visualization/V4_05.png "Record Movies and Snapshots") ## Exercises 1. Create movies of a 3D scene. diff --git a/mevislab.github.io/content/tutorials/visualization/visualizationexample5.md b/mevislab.github.io/content/tutorials/visualization/visualizationexample5.md index 55b3f9391..8e37af46b 100644 --- a/mevislab.github.io/content/tutorials/visualization/visualizationexample5.md +++ b/mevislab.github.io/content/tutorials/visualization/visualizationexample5.md @@ -23,7 +23,7 @@ In this example we like to convert a scan of a head into a 3D scene object. The ### Develop Your Network Implement the following network and open the image *$(DemoDataPath)/BrainMultiModal/ProbandT1.tif*. -![SoGVRVolumeRenderer](/images/tutorials/visualization/V6_01.png "SoGVRVolumeRenderer") +![SoGVRVolumeRenderer](images/tutorials/visualization/V6_01.png "SoGVRVolumeRenderer") The module `SoGVRVolumeRenderer` allows volume rendering of 3D and 4D images. @@ -36,24 +36,24 @@ Additional information about Volume Rendering can be found here: {{< docuLinks " ### Change LUT We like to add a surface color to the head. In order to do that, we add the module `SoLUTEditor`, which adds an RGBA lookup table (LUT) to the scene. Connecting this module to `SoExaminerViewer` left to the connection between `SoGVRRenderer` and `SoExaminerViewer` (remember the order in which Open Inventor modules are executed) allows you to set the surface color of the head. -![SoLUTEditor](/images/tutorials/visualization/V6_02.png "SoLUTEditor") +![SoLUTEditor](images/tutorials/visualization/V6_02.png "SoLUTEditor") To change the color, open the panel of `SoLUTEditor`. In this editor we can change color and transparency interactively (for more information, see the {{< docuLinks "/Standard/Documentation/Publish/ModuleReference/SoLUTEditor.html" "help page">}}). Here, we have a range from black to white and from complete transparency to full opacity. -![SoLUTEditor change colors](/images/tutorials/visualization/V6_03.png "SoLUTEditor change colors") +![SoLUTEditor change colors](images/tutorials/visualization/V6_03.png "SoLUTEditor change colors") We now like to add color. New color points can be added by clicking on the color bar at the bottom side of the graph and existing points can be moved by dragging. You can change the color of each point under *Color*. -![SoLUTEditor add colors](/images/tutorials/visualization/V6_04.png "SoLUTEditor add colors") +![SoLUTEditor add colors](images/tutorials/visualization/V6_04.png "SoLUTEditor add colors") ### Interactions As a next step, we add some dynamics to the 3D scene: We like to rotate the head. In order to do this, add the modules `SoRotationXYZ` and `SoElapsedTime` to the workspace and connect the modules as shown. -![SoRotationXYZ](/images/tutorials/visualization/V6_05.png "SoRotationXYZ") +![SoRotationXYZ](images/tutorials/visualization/V6_05.png "SoRotationXYZ") Open the panels of both modules and select the axis the image should rotate around. In this case, the z-axis was selected. Now, build a parameter connection from the parameter *Time* out of the module `SoElapsedTime` to the parameter *Angle* of the module `SoRotationXYZ`. The angle changes with time and the head starts turning. -![Time and Angle](/images/tutorials/visualization/V6_06.png "Time and Angle") +![Time and Angle](images/tutorials/visualization/V6_06.png "Time and Angle") ## Exercises 1. Change rotation speed diff --git a/mevislab.github.io/content/tutorials/visualization/visualizationexample6.md b/mevislab.github.io/content/tutorials/visualization/visualizationexample6.md index ee526ab5c..bdf359e3a 100644 --- a/mevislab.github.io/content/tutorials/visualization/visualizationexample6.md +++ b/mevislab.github.io/content/tutorials/visualization/visualizationexample6.md @@ -16,7 +16,7 @@ menu: @@ -27,7 +27,7 @@ The MeVis Path Tracer offers a Monte Carlo Path Tracing framework running on CUD CUDA is a parallel computing platform and programming model created by NVIDIA. For further information, see [NVIDIA website](https://blogs.nvidia.com/blog/2012/09/10/what-is-cuda-2/). {{}} -{{< imagegallery 5 "/images/tutorials/visualization/pathtracer" "PathTracer1" "PathTracer2" "PathTracer3" "PathTracer4" "PathTracer5" >}} +{{< imagegallery 5 "images/tutorials/visualization/pathtracer" "PathTracer1" "PathTracer2" "PathTracer3" "PathTracer4" "PathTracer5" >}} The `SoPathTracer` module implements the main renderer (like the `SoGVRVolumeRenderer`). It collects all `SoPathTracer*` extensions (on its left side) in the scene and renders them. Picking is also supported, but currently only the first hit position. It supports an arbitrary number of objects with different orientation and bounding boxes. diff --git a/mevislab.github.io/content/tutorials/visualization/visualizationexample7.md b/mevislab.github.io/content/tutorials/visualization/visualizationexample7.md index 03479d303..5a15b671d 100644 --- a/mevislab.github.io/content/tutorials/visualization/visualizationexample7.md +++ b/mevislab.github.io/content/tutorials/visualization/visualizationexample7.md @@ -23,39 +23,39 @@ In this example we will use the `OrthoView2D` module and add a 3D viewer to the ### Develop your network Add the modules `LocalImage` and `OrthoView2D` to your workspace and connect them. -![Network](/images/tutorials/image_processing/network_example7.png "Network") +![Network](images/tutorials/image_processing/network_example7.png "Network") The `OrthoView2D` module allows you to select multiple layouts. Select layout *Cube Equal*. The layout shows your image in three orthogonal viewing directions. The top left segment remains empty. -![OrthoView2D Layouts](/images/tutorials/image_processing/network_example7_2.png "OrthoView2D Layouts") +![OrthoView2D Layouts](images/tutorials/image_processing/network_example7_2.png "OrthoView2D Layouts") We now want to use a 3D rendering in the top left segment, whenever the layout *Cube Equal* is chosen. Add a `View3D` and a `SoViewportRegion` module to your workspace. Connect the `LocalImage` with your `View3D`. The image is rendered in 3D. Hit {{< keyboard "SPACE" >}} on your keyboard to make the hidden output of the `View3D` module visible. Connect it with your `SoViewportRegion` and connect the `SoViewportRegion` with the *inInvPreLUT* input of the `OrthoView2D`. -![Network with SoViewportRegion](/images/tutorials/image_processing/network_example7_3.png "Network with SoViewportRegion") +![Network with SoViewportRegion](images/tutorials/image_processing/network_example7_3.png "Network with SoViewportRegion") Open the `OrthoView2D` and inspect your layout. -![OrthoView2D with 3D](/images/tutorials/image_processing/network_example7_4.png "OrthoView2D with 3D") +![OrthoView2D with 3D](images/tutorials/image_processing/network_example7_4.png "OrthoView2D with 3D") You can see your `View3D` being visible in the bottom right segment of the layout behind the coronal view of the image. Open the panel of the `SoViewportRegion` module. In section *X-Position and Width*, set *Left Border* to *0* and *Right Border* to *0.5*. In section *Y-Position and Height*, set *Lower Border* to *0* and *Upper Border* to *0.5*. Also check *Render delayed paths*. -![Define viewport region](/images/tutorials/image_processing/network_example7_5.png "Define viewport region") +![Define viewport region](images/tutorials/image_processing/network_example7_5.png "Define viewport region") The `View3D` image is now rendered to the top left segment of the `OrthoView2D`, because the module `SoViewportRegion` renders a sub graph into a specified viewport region (VPR). The problem is: We cannot rotate and pan the 3D object, because there is no camera interaction available after adding the `SoViewportRegion`. The camera interaction is consumed by the `View3D` module before it can be used by the viewport. Add a `SoCameraInteraction` module between the `View3D` and the `SoViewportRegion`. You can now interact with your 3D scene but the rotation is not executed on the center of the object. Trigger *ViewAll* on your `SoCameraInteraction` module. -![SoCameraInteraction](/images/tutorials/image_processing/network_example7_6.png "SoCameraInteraction") +![SoCameraInteraction](images/tutorials/image_processing/network_example7_6.png "SoCameraInteraction") You have now successfully added the `View3D` to the `OrthoView2D`, but there is still a problem remaining: If you change the layout to something different than *LAYOUT_CUBE_EQUAL*, the 3D content remains visible. We can use a `StringUtils` module to resolve that. Set *Operation* to *Compare* and draw a parameter connection from the field *OrthoView2D.layout* to the field *StringUtils.string1*. The currently selected layout is displayed as *String A*. Enter *LAYOUT_CUBE_EQUAL* as *String B*. Now, draw a parameter connection from the field *StringUtils.boolResult* to the field *SoViewportRegion.on*. -![StringUtils](/images/tutorials/image_processing/network_example7_7.png "StringUtils") +![StringUtils](images/tutorials/image_processing/network_example7_7.png "StringUtils") If the selected layout in `OrthoView2D` now matches the string *LAYOUT_CUBE_EQUAL* (the field *boolResult* of the `StringUtils` module is *TRUE*), the `SoViewportRegion` is turned *on*. In any other case, the 3D segment is not visible. -![Final Network](/images/tutorials/image_processing/network_example7_8.png "Final Network") +![Final Network](images/tutorials/image_processing/network_example7_8.png "Final Network") ## Summary * The module `SoViewportRegion` renders a sub graph into a specified viewport region (VPR) diff --git a/mevislab.github.io/content/tutorials/visualization/visualizationexample8.md b/mevislab.github.io/content/tutorials/visualization/visualizationexample8.md index 1ea4f1a96..9484e1021 100644 --- a/mevislab.github.io/content/tutorials/visualization/visualizationexample8.md +++ b/mevislab.github.io/content/tutorials/visualization/visualizationexample8.md @@ -22,47 +22,47 @@ In this tutorial, we are using an input mask to create a vessel centerline using ## Steps to Do ### Develop Your Network -Load the example [tree mask](/examples/visualization/example8/EditedImage.mlimage) by using the `LocalImage` module. Connect the output to a `DtfSkeletonization` module as seen below. The initial output of the `DtfSkeletonization` module is empty. Press the *Update* button to calculate the skeleton and the erosion distances. +Load the example [tree mask](examples/visualization/example8/EditedImage.mlimage) by using the `LocalImage` module. Connect the output to a `DtfSkeletonization` module as seen below. The initial output of the `DtfSkeletonization` module is empty. Press the *Update* button to calculate the skeleton and the erosion distances. -![Network](/images/tutorials/visualization/V8_1.png "Network") +![Network](images/tutorials/visualization/V8_1.png "Network") Below you can see the output of the original image taken from the `LocalImage` module (left) compared to the output after calculating the skeleton via `DtfSkeletonization` module (right). -![Output comparison](/images/tutorials/visualization/V8_1b.png "Output comparison") +![Output comparison](images/tutorials/visualization/V8_1b.png "Output comparison") The output *DtfSkeletonization.outBase1* shows nothing. Here you can find the three-dimensional graph of the vascular structures. To generate it, open the panel of the `DtfSkeletonization` module, set *Update Mode* to *Auto Update*, and select *Update skeleton graph*. Now the output additionally provides a 3D graph. Additionally, enable the *Compile Graph Voxels* to provide all object voxels at the output. -![DtfSkeletonization](/images/tutorials/visualization/V8_02.png "DtfSkeletonization") +![DtfSkeletonization](images/tutorials/visualization/V8_02.png "DtfSkeletonization") You can use the *Output Inspector* to see the 3D graph. -![Graph output of DtfSkeletonization](/images/tutorials/visualization/V8_MLImage.png "Graph output of DtfSkeletonization") +![Graph output of DtfSkeletonization](images/tutorials/visualization/V8_MLImage.png "Graph output of DtfSkeletonization") If you want to visualize your graph, you should connect a `GraphToVolume` module to the `DtfSkeletonization` module. The result is a 2D or 3D volume of your graph that you can connect to any 2D or 3D viewer. Add a `View2D` and a `View3D` module to the `GraphToVolume` module and update the volume. -![GraphToVolume](/images/tutorials/visualization/V8_03.png "GraphToVolume") +![GraphToVolume](images/tutorials/visualization/V8_03.png "GraphToVolume") For coloring the vessels depending on their distances to the centerline, we need a `SoLUTEditor` module. Change your network to use a `SoExaminerViewer` module, a `SoLUTEditor` module and a `SoBackground` module instead of a `View3D` module. Use the `SoLUTEditor` for the `View2D`, too. -![Network](/images/tutorials/visualization/V8_04.png "Network") +![Network](images/tutorials/visualization/V8_04.png "Network") Open the output of the `GraphToVolume` module and inspect the images in Output Inspector. You will see that the HU value of the black background is defined as *-1* while the vessel tree is defined as *0*. -![Output Inspector](/images/tutorials/visualization/V8_04_OutputInspector.png "Output Inspector") +![Output Inspector](images/tutorials/visualization/V8_04_OutputInspector.png "Output Inspector") Open the Panel of the `SoLUTEditor` and select tab *Range*. Define *New Range Min* as *-1* and *New Range Max* as *0*. -![SoLUTEditor Range](/images/tutorials/visualization/V8_04_Range.png "SoLUTEditor Range") +![SoLUTEditor Range](images/tutorials/visualization/V8_04_Range.png "SoLUTEditor Range") Change to *Editor* tab and define the following LUT: -![SoLUTEditor Editor](/images/tutorials/visualization/V8_04_Editor.png "SoLUTEditor Editor") +![SoLUTEditor Editor](images/tutorials/visualization/V8_04_Editor.png "SoLUTEditor Editor") The viewers now show your vessel graph. -![View2D and SoExaminerViewer](/images/tutorials/visualization/V8_04_Viewer.png "View2D and SoExaminerViewer") +![View2D and SoExaminerViewer](images/tutorials/visualization/V8_04_Viewer.png "View2D and SoExaminerViewer") ### Store Edge IDs in Skeletons with RunPythonScript Each edge of the calculated skeleton gets a unique ID defined by the `DtfSkeletonization` module. We now want to use this ID to define a different color for each edge of the skeleton. You can use the **Label** property of each skeleton to store the ID of the edge. @@ -86,15 +86,15 @@ First, we always want a fresh skeleton. We touch the *update* trigger of the mod The Debug Output of the MeVisLab IDE shows a numbered list of edge IDs from 1 to 153. -![RunPythonScript](/images/tutorials/visualization/V8_05.png "RunPythonScript") +![RunPythonScript](images/tutorials/visualization/V8_05.png "RunPythonScript") We now want the edge ID to be used for coloring each of the skeletons differently. Open the Panel of the `SoLUTEditor` and select tab *Range*. Define *New Range Min* as *0* and *New Range Max* as *153*. Define different colors for your LUT. -![SoLUTEditor](/images/tutorials/visualization/V8_05_LUT.png "SoLUTEditor") +![SoLUTEditor](images/tutorials/visualization/V8_05_LUT.png "SoLUTEditor") The `SoGVRVolumeRenderer` module also needs a different setting. Open its panel in the *Main* tab, select *Illuminated* as the *Render Mode*. Adjust the *Quality* setting to *0.10*. On tab *Advanced*, set *Filter Volume Data* to *Nearest*. Change to the *Illumination* tab and define below parameters: -{{}} +{{}} Change your Python script as follows: {{< highlight >}} @@ -118,7 +118,7 @@ In the case the graph is valid, we now define a static text for the label. Inste Your viewers now show a different color for each skeleton, based on our LUT. -![View2D and SoExaminerViewer](/images/tutorials/visualization/V8_05_Viewer.png "View2D and SoExaminerViewer") +![View2D and SoExaminerViewer](images/tutorials/visualization/V8_05_Viewer.png "View2D and SoExaminerViewer") ### Render Vascular System Using SoVascularSystem The `SoVascularSystem` module is optimized for rendering vascular structures. In comparison to the `SoGVRVolumeRenderer` module, it allows to render the surface, the skeleton or points of the structure in an open inventor scene graph. Interactions with edges of the graph are also already implemented. @@ -127,7 +127,7 @@ Add a `SoVascularSystem` module to your workspace. Connect it to your `DtfSkelet Uncheck *Use skeleton colors* and *Use integer LUT* on *Appearance* tab of the `SoVascularSystem` module panel. -![ EditedNetwork](/images/tutorials/visualization/V8_SoVascularSystem.png " EditedNetwork") +![ EditedNetwork](images/tutorials/visualization/V8_SoVascularSystem.png " EditedNetwork") {{}} More information about the `SoVascularSystem` module can be found in the {{< docuLinks "/Standard/Documentation/Publish/ModuleReference/SoVascularSystem.html" "help page" >}} of the module. @@ -135,7 +135,7 @@ More information about the `SoVascularSystem` module can be found in the {{< doc Draw parameter connections from one `SoExaminerViewer` to the other. Use the fields seen below to synchronize your camera interaction. -![ Camera positions](/images/tutorials/visualization/V8_SyncFloat.png " Camera positions") +![ Camera positions](images/tutorials/visualization/V8_SyncFloat.png " Camera positions") Connect the backwards direction of the two `SoExaminerViewer` by using multiple `SyncFloat` modules and two `SyncVector` modules for *position* and *orientation* fields. @@ -143,21 +143,21 @@ Connect the backwards direction of the two `SoExaminerViewer` by using multiple To establish connections between fields with the type *Float*, you can use the *SyncFloat* module. For fields containing vector, the appropriate connection can be achieved using the *SyncVector* module. {{}} -![ SyncFloat & SyncVector](/images/tutorials/visualization/V8_SyncFloat_Network.png " SyncFloat & SyncVector") +![ SyncFloat & SyncVector](images/tutorials/visualization/V8_SyncFloat_Network.png " SyncFloat & SyncVector") Camera interactions are now synchronized between both `SoExaminerViewer` modules. Now you can notice the difference between the two modules. We use `SoVascularSystem` for a smoother visualization of the vascular structures by using the graph as reference. The `SoGVRVolumeRenderer` renders the volume from the `GraphToVolume` module, including the visible stairs from voxel representations in the volume. -![ SoVascularSystem & SoGVRVolumeRenderer](/images/tutorials/visualization/V8_Difference1.png " SoVascularSystem & SoGVRVolumeRenderer") +![ SoVascularSystem & SoGVRVolumeRenderer](images/tutorials/visualization/V8_Difference1.png " SoVascularSystem & SoGVRVolumeRenderer") The `SoVascularSystem` module has additional visualization examples unlike `SoGVRVolumeRenderer`. Open the panel of the `SoVascularSystem` module and select *Random Points* for *Display Mode* in the *Main* tab to see the difference. -![ Random Points](/images/tutorials/visualization/V8_SoVasularSystem_DisplayMode1.png " Random Points") +![ Random Points](images/tutorials/visualization/V8_SoVasularSystem_DisplayMode1.png " Random Points") Change it to *Skeleton* to only show the centerlines/skeletons of the vessels. -![ Skeleton](/images/tutorials/visualization/V8_SoVasularSystem_DisplayMode2.png " Skeleton") +![ Skeleton](images/tutorials/visualization/V8_SoVasularSystem_DisplayMode2.png " Skeleton") {{}} For volume calculations, use the original image mask instead of the result from `GraphToVolume`. @@ -168,7 +168,7 @@ Now that you've successfully obtained the vessel skeleton graph using `DtfSkelet The values for the provided vascular tree vary between 0 and 10mm. Therefore define the range of the `SoLUTEditor` to *New Range Min* as *1* and *New Range Max* as *10*. On *Editor* tab, define the following LUT: -![SoLUTEditor](/images/tutorials/visualization/V8_SoLUTEditor2.png "SoLUTEditor") +![SoLUTEditor](images/tutorials/visualization/V8_SoLUTEditor2.png "SoLUTEditor") In the `RunPythonScript` module, change the existing code to the following: {{< highlight >}} @@ -198,18 +198,18 @@ Be aware that the *MinDistance* and *MaxDistance* values are algorithm-specific Instead of using the ID of each edge for the label property, we are now using the *MinDistance* property of the skeleton. The result is a color coded 3D visualization depending on the radius of the vessels. Small vessels are red, large vessels are green. -![Radius based Visualization](/images/tutorials/visualization/V8_010new.png "Radius based Visualization") +![Radius based Visualization](images/tutorials/visualization/V8_010new.png "Radius based Visualization") {{}} If you have a NIfTI file, convert it into an ML image. Load your tree mask NIfTI file using the `itkImageFileReader` module. Connect the output to a `BoundingBox` module, which removes black pixels and creates a volume without unmasked parts. In the end, add a `MLImageFormatSave` module to save it as *.mlimage* file. They are much smaller than a NIfTI file. -![NIfTI file conversion](/images/tutorials/visualization/V8_ConvertToMlImage.png "NIfTI file conversion") +![NIFTI file conversion](images/tutorials/visualization/V8_ConvertToMlImage.png "NIFTI file conversion") {{}} ### Mouse Clicks on Vessel Graph Open the *Interaction* tab of the `SoVascularSystem` module. In `SoExaminerViewer` module, change to *Pick Mode* and click into your vessel structure. The panel of the `SoVascularSystem` module shows all information about the hit of your click in the vessel tree. -![Getting the click point in a vascular tree](/images/tutorials/visualization/V8_Interactions.png "Getting the click point in a vascular tree") +![Getting the click point in a vascular tree](images/tutorials/visualization/V8_Interactions.png "Getting the click point in a vascular tree") ## Summary * Vessel centerlines can be created using a `DtfSkeletonization` module. diff --git a/mevislab.github.io/content/tutorials/visualization/visualizationexample9.md b/mevislab.github.io/content/tutorials/visualization/visualizationexample9.md index ae5996d8c..3e8024b59 100644 --- a/mevislab.github.io/content/tutorials/visualization/visualizationexample9.md +++ b/mevislab.github.io/content/tutorials/visualization/visualizationexample9.md @@ -21,17 +21,17 @@ In this tutorial, we are using the `AnimationRecorder` module to generate dynami ## Steps to do -Open the network and files of [Example 6.2](/tutorials/visualization/pathtracer/pathtracerexample2/), add a `SoSeparator` module and an `AnimationRecorder` module to your workspace and connect them as shown below. +Open the network and files of [Example 6.2](tutorials/visualization/pathtracer/pathtracerexample2/), add a `SoSeparator` module and an `AnimationRecorder` module to your workspace and connect them as shown below. The `SoSeparator` module collects all components of our scene and provides one output to be used for the `AnimationRecorder`. The `AnimationRecorder` module allows to create animations and record them as video streams. It provides an editor to create key frames for animating field values. -![AnimationRecorder](/images/tutorials/visualization//pathtracer/Example9_1.png " AnimationRecorder") +![AnimationRecorder](images/tutorials/visualization//pathtracer/Example9_1.png " AnimationRecorder") -Define the following LUTs in `SoLUTEditor` of the knee or load this [XML file](/examples/visualization/example6/LUT_AnimationRecorder.xml) with `LUTLoad1` to use a pre-defined LUT. +Define the following LUTs in `SoLUTEditor` of the knee or load this [XML file](examples/visualization/example6/LUT_AnimationRecorder.xml) with `LUTLoad1` to use a pre-defined LUT. -![ SoLUTEditor](/images/tutorials/visualization//pathtracer/V9_LUT.png " SoLUTEditor") +![ SoLUTEditor](images/tutorials/visualization//pathtracer/V9_LUT.png " SoLUTEditor") Open the `AnimationRecorder` module and click on *New* to initiate a new animation, selecting a filename for the recorded key frames (*.mlmov*). @@ -41,7 +41,7 @@ At the bottom of the `AnimationRecorder` panel, you'll find the key frame editor Close the SoExaminerViewer while using the AnimationRecorder to prevent duplicate renderings and save resources. {{}} -![AnimationRecorder](/images/tutorials/visualization//pathtracer/V9_AnimationRecorder.png " AnimationRecorder") +![AnimationRecorder](images/tutorials/visualization//pathtracer/V9_AnimationRecorder.png " AnimationRecorder") Key frames in the `AnimationRecorder` mark specific field values at defined timepoints. You can add key frames on the timeline by double-clicking at the chosen timepoint or right-clicking and selecting *Insert Key Frame*. Between these key frames, values of the field are interpolated (linear or spline) or not. Selecting a key frame, a dialog *Edit Camera Key Frame* will open. @@ -59,13 +59,13 @@ Before proceeding further, use the playback options situated at the base of the Decrease the number of iterations in the SoPathTracer module for a quicker preview if you like. Make sure to increase again before recording the final video. {{}} -![ AnimationRecorder](/images/tutorials/visualization//pathtracer/V9_AnimationRecorder1.png " AnimationRecorder") +![ AnimationRecorder](images/tutorials/visualization//pathtracer/V9_AnimationRecorder1.png " AnimationRecorder") ## Modulating Knee Visibility with LUTRescale in Animation We want to show and hide the single segmentations during camera movements. Add two `LUTRescale` modules to your workspace and connect them as illustrated down below. The rationale behind using `LUTRescale` is to control the transparency and by that the visibility of elements in the scene at different timepoints. -![ LUTRescale](/images/tutorials/visualization//pathtracer/V9_3.png " LUTRescale") +![ LUTRescale](images/tutorials/visualization//pathtracer/V9_3.png " LUTRescale") ## Animate Bones and Vessels @@ -73,7 +73,7 @@ Now, let's shift our focus to highlighting bones and vessels within the animatio By linking the *targetMax* field of the `LUTRescale` module to the `AnimationRecorder`, you establish a connection that allows you to define different values of the field for specific timepoints. The values between these timepoints can be interpolated as described above. -![ LUTRescale & AnimationRecorder](/images/tutorials/visualization//pathtracer/LUTRescale_AnimationRecorder2.png " LUTRescale & AnimationRecorder") +![ LUTRescale & AnimationRecorder](images/tutorials/visualization//pathtracer/LUTRescale_AnimationRecorder2.png " LUTRescale & AnimationRecorder") To initiate the animation sequence, start by adding a key frame at position *0* for the *targetMax* field. Set the *Target Max* value in the *Edit Key Frame – [LUTRescale.targetMax]* window to *1*, and click on the *Store Current Field Value* button to save it. @@ -81,20 +81,20 @@ Next, proceed to add key frames at the same timepoints as the desired key frames To seamlessly incorporate the new key frame at the same timepoints as the *Perspective Camera* field, you have two efficient options. Simply click on the key frame of the first sequence, and the line will automatically appear in the middle of the key frame. A double-click will effortlessly insert a key frame at precisely the same position. If you prefer more accurate adjustments, you can also set your frame manually using the *Edit Key Frame - [LUTRescale.targetMax]* window. This flexibility allows for precise control over the animation timeline, ensuring key frames align precisely with your intended moments. -![ LUTRescale & AnimationRecorder](/images/tutorials/visualization//pathtracer/V9_7.png " LUTRescale & AnimationRecorder") +![ LUTRescale & AnimationRecorder](images/tutorials/visualization//pathtracer/V9_7.png " LUTRescale & AnimationRecorder") ## Showcasing only Bones To control the visibility of the vessels, right-click on the ` LUTRescale1` module connected to the vessels. Open the *Show Window* and select *Automatic Panel*. Drag and drop the *targetMax* field into the `AnimationRecorder` module's fields section. -![ LUTRescale1 & AnimationRecorder](/images/tutorials/visualization//pathtracer/V9_8.png " LUTRescale1 & AnimationRecorder") +![ LUTRescale1 & AnimationRecorder](images/tutorials/visualization//pathtracer/V9_8.png " LUTRescale1 & AnimationRecorder") Add key frames for both the *Perspective Camera* field and the *targetMax* in `LUTRescale1` at the same timepoints. Access the *Edit Camera Key Frame* window for the added key frame in the *Perspective Camera* field and save the *current camera state*. To exclusively highlight only bones, adjust the *Target Max* values from *1* to *10000* in *Edit Key Frame - [LUTRescale1.targetMax]*. -![ LUTRescale1 & AnimationRecorder](/images/tutorials/visualization//pathtracer/V9_9.png " LUTRescale1 & AnimationRecorder") +![ LUTRescale1 & AnimationRecorder](images/tutorials/visualization//pathtracer/V9_9.png " LUTRescale1 & AnimationRecorder") To feature everything again at the end, copy the initial key frame of each field and paste it at the end of the timeline. This ensures a comprehensive display of all elements in the closing frames of your animation. -![ Final Animation Sequence Key Frames](/images/tutorials/visualization//pathtracer/V9_10.png " Final Animation Sequence Key Frames") +![ Final Animation Sequence Key Frames](images/tutorials/visualization//pathtracer/V9_10.png " Final Animation Sequence Key Frames") Finally, use the playback and recording buttons at the bottom of the key frame editor to preview and record your animation. diff --git a/mevislab.github.io/hugo.toml b/mevislab.github.io/hugo.toml index 098dfe893..a2f843f53 100644 --- a/mevislab.github.io/hugo.toml +++ b/mevislab.github.io/hugo.toml @@ -4,7 +4,6 @@ languageCode = "en-us" title = "MeVisLab Examples" theme = "MeVisLab" relativeURLs = false -canonifyURLs = true [markup] [markup.goldmark] diff --git a/mevislab.github.io/layouts/index.html b/mevislab.github.io/layouts/index.html index f9e9bb85d..6b5950773 100644 --- a/mevislab.github.io/layouts/index.html +++ b/mevislab.github.io/layouts/index.html @@ -11,9 +11,9 @@

Learn to use MeVisLab

Find some interesting links below if you feel like you are ready for a quick start:

diff --git a/mevislab.github.io/themes/MeVisLab/layouts/partials/header.html b/mevislab.github.io/themes/MeVisLab/layouts/partials/header.html index ea9dadb89..664c7ac83 100644 --- a/mevislab.github.io/themes/MeVisLab/layouts/partials/header.html +++ b/mevislab.github.io/themes/MeVisLab/layouts/partials/header.html @@ -8,13 +8,13 @@ diff --git a/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/mousebutton.html b/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/mousebutton.html index a97ebd8fd..c6c70ff1f 100644 --- a/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/mousebutton.html +++ b/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/mousebutton.html @@ -1,10 +1,10 @@ {{ $button := .Get 0 }} {{ if eq $button "left" }} -Left Mouse Button +Left Mouse Button {{ end }} {{ if eq $button "right" }} -Right Mouse Button +Right Mouse Button {{ end }} {{ if eq $button "middle" }} -Middle Mouse Button / Mouse Wheel +Middle Mouse Button / Mouse Wheel {{ end }} \ No newline at end of file diff --git a/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/networkfile.html b/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/networkfile.html index 26e3b40c2..42146bd89 100644 --- a/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/networkfile.html +++ b/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/networkfile.html @@ -4,11 +4,11 @@
{{ if strings.HasSuffix $filename "mlab" }} {{ $src := "/favicon.ico" }} -    Download .mlab file here. +    Download .mlab file here. {{ else if strings.HasSuffix $filename "py" }} -    Download Python file here. +    Download Python file here. {{ else if strings.HasSuffix $filename "zip" }} -    Download Archive here. +    Download Archive here. {{ end }}
\ No newline at end of file diff --git a/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/youtube.html b/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/youtube.html index 037a84ccb..76c7bd1ba 100644 --- a/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/youtube.html +++ b/mevislab.github.io/themes/MeVisLab/layouts/shortcodes/youtube.html @@ -1,5 +1,5 @@ \ No newline at end of file