How to run a single slice basic reconstruction#
Raw data for this example#
Raw data for this example can be found in /scisoft/tomo_training/part1_basic_reco
You must copy them, and you can also remove the .nx file contained here (they will be created during step 1
).
Step 0: Launch tomwer canvas#
When you are on the cluster node after sourcing the Python virtual environment, launch the canvas:
tomwer canvas
[1]:
from IPython.display import Video
Video("video/start_tomwer_canvas.mp4", embed=True, height=500)
[1]:
There are two use cases for now:
From a Bliss acquisition. Then we will convert on step 1 from Bliss acquisition to NXtomo.
From EDF. In this case, you can use the native EDF folder as a NXtomo or convert it to NXtomo first (looking at XXX for example) and then proceed to step 2.
Step 1: From Bliss acquisition to NXtomo#
For this, we need to use the bliss(HDF5) - nxtomomill
alias h52nx-nxtomomill
widget.
Add the widget from the left panel with a click on the left panel item or by copy/pasting.
Open the widget dialog by double-clicking on the canvas widget freshly created.
Then add the Bliss file from the select button or copy/paste to the dedicated dialog.
You should see one line added to the dialog per NXtomo that will be created.
(Optional: Connect it with another widget like
data list
ordata selector
to see the output and make sure all the conversion went well.)Press ‘Send All’ / ‘Send Selected’ to trigger the conversion to Bliss file (some other dialog might appear if the NXtomo already exists).
Note 1: Keep in mind that this can also be done manually using the command line interface (CLI) of nxtomomill. For more details, please seeh52nx nxtomomill tutorial.
Note 2: For converting from EDF to NXtomo, you can do the same operation but using the ``edf2nx-nxtomomill`` widget. Have a look atEDF to NXtomo CLI tutorialfor CLI or advanced usage.
Note 3: If no configuration file is provided, then the default parameters will be used. Otherwise, you can provide a configuration file. For details, see theedf2nx widget video tutorialwhich explains how to provide a file (GUI mechanism is the same for EDF and HDF5).
[2]:
from IPython.display import Video
Video("video/h52nx_example.mp4", embed=True, height=500)
[2]:
Hands-on Exercise A#
Copy data from `
to a local workspace (like
/tmp_14_days/{your_name}`) or reuse them if they already exist.Launch
tomwer canvas
.Convert the Bliss
.h5
file to a NXtomo (.nx
) using the appropriate widget.
Step 2: Define a Basic Workflow#
From raw data we will need:
Reduced dark/flat widget
NXtomo is expected to contain dark and flat frames. In order to compute the flat field, we need to compute
reduced
darks and flats.Center of rotation (see ‘cor_search’ notebook for more information).
For the training, we will use the ‘sino-coarse-to-fine’ algorithm which provides a good estimation of the center of rotation. In the video, we will do it manually, but we could lock the algorithm to avoid validating the value found.
Nabu ‘slice’
To reconstruct one slice. In the example, we will also request a Paganin phase to have a better reconstruction.
Data viewer
To display the reconstructed slice (and browse the dataset).
Note: The widget can be created from the left panel (with a left mouse click on the widget) or by creating a link from a left click on the node output and releasing it downstream).
[3]:
from IPython.display import Video
Video("video/create_dummy_workflow.mp4", embed=True, height=500)
[3]:
Step 3: Run the Workflow#
Now that you have an input and a basic workflow, we can process it.
For this, simply ‘select’ the NXtomo from the scan selector that was created during step 1. Processing should start; you have to wait until all processes are finished.
[4]:
from IPython.display import Video
Video("video/execute_dummy_workflow.mp4", embed=True, height=500)
[4]:
Note: You can control advancement from the ‘Object Supervisor’ on the bottom of the window. If it is not visible, you can display/hide it from the view/object supervisor option as shown in the video.
[5]:
from IPython.display import Video
Video("video/object_supervisor_display.mp4", embed=True, height=500)
[5]:
Hands-on Exercise B#
Reconstruct a slice of the NXtomo created during Exercise A.