From beb588780e59e78271b3adc9aa255fe7a2e07bf1 Mon Sep 17 00:00:00 2001 From: Danica Sugic Date: Thu, 30 May 2024 15:28:21 +0100 Subject: [PATCH 1/2] Edit documentation on registration in dvc steps and edit changelog --- CHANGES.md | 1 + docs/source/dvc_steps.rst | 36 ++++++++++++++++++++++-------------- 2 files changed, 23 insertions(+), 14 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index cc74126f..679a9492 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,6 +1,7 @@ # ChangeLog ## vx.x.x +* Edit documentation on registration in dvc steps #265 * fix some missing pip dependencies & update workflows & fix tests #233 * Edit registration-tab name from "Manual" to "Initial" #241 * Add automatic registration functionality #304 diff --git a/docs/source/dvc_steps.rst b/docs/source/dvc_steps.rst index e7073c74..eba0f3cf 100644 --- a/docs/source/dvc_steps.rst +++ b/docs/source/dvc_steps.rst @@ -4,10 +4,10 @@ DVC Configuration Steps Each panel contains a different step in the DVC configuration process. When moving between each panel, the Help section is updated. Additional help can be viewed by hovering the mouse over some of the buttons and labels on the interface. -Manual Registration -=================== +Initial Registration +==================== -The first step of the DVC analysis is to line up the reference and correlate images. The rigid body translation between the images will be input to the DVC analysis code. Go to the **Manual Registration** tab to get started with this. +The first step of the DVC analysis is to line up the reference and correlate images. The rigid body translation between the images will be input to the DVC analysis code. Go to the **Initial Registration** tab to get started with this. The Point 0 Location ~~~~~~~~~~~~~~~~~~~~ @@ -20,16 +20,19 @@ Otherwise, a random point in the cloud will be selected to begin with. Registering the Images ~~~~~~~~~~~~~~~~~~~~~~ -You can set an initial translation if you already know some information about how the images are translated relative to each other. +After selecting point 0 and the registration box size, the registration process is initialised by clicking on **Start Registration**. +This runs an automatic registration procedure and the results are displayed in the widgets **Translate X**, **Translate Y**, and **Translate Z**, as well as in the label widget **Automatic registration [...]**. +The viewer shows an image representing the difference between the reference volume and the correlate volume. +This is shown in a square with side equal to the chosen "registration box size". +The image can be spanned in 3D and it is initially centred on the slice embedding point 0. +This view can be retrieved by clicking on the button **Centre on Point 0**. +The difference image is calculated from the full-resolution volumes, not their down-sampled versions. +If two volumes were identical, their difference volume would result in pixels of value 0 and the viewer would show a black square. +Two images are registered optimally when their difference volume is as uniform as possible, and shown with large numbers of grey pixels in the viewer. +The registration procedure can be manually adjusted by clicking on the difference image and moving the two volumes with respect to each other by using the keys: "j", "n", "b", and "m". +The image orientation cab be changed using the "x", "y" and "z" keys, and scroll through the image slices. -When you click **Start Registration** this will crop the image to the size of the reference box you chose, centred on the point 0. It will do the same for the correlate image, and then it will subtract one image from the other, and display that on the viewer. It does this for the original images, not the down-sampled versions. -If you were to load two identical images, then the subtraction would result in nothing, so you would just see a black square. The idea is that to register the images, you need to align them such that the subtraction results in as uniform an image as possible. -If you have set an initial translation then the images will start off being translated relative to each other accordingly. - -You can then move the two images relative to each other by using the keys: j, n, b and m. -You can also still change the orientation using the x, y and z keys, and scroll through the image slices. - -Here is an example of what an image registration would look like as you begin to align the images – you can see it becomes more grey where you have a good overlap. +An example of an optimal registration is shown below, where the difference image is largely grey. .. image:: images/registration_example_0.png :width: 49% @@ -42,8 +45,13 @@ Here is an example of what an image registration would look like as you begin to :raw-html:`
` -Once you are satisfied with the registration, click **Confirm Registration** to save the translation. This will be provided to the DVC analysis code later on. -Then move on to the **Mask** tab. +Click on the button **Reset** to set the translation to [0, 0, 0]. +Click on the button **Set to Automatic Registration** to reset the translation the value of the automatic registration. +Click on the button **Confirm Registration** when satisfied with the registration and store the translation value for the DVC analysis in the next tabs. +Click on the button **Cancel** to terminate the registration procedure and retrieve the previous translation value. +Click on the button **Restart registration** to restart the regitration process again. + +Move to the **Mask** tab only when the registration has been confirmed at least once. Mask Creation ============= From 6a89e3f8b89b96feabfc0a5f7bdd4e6210c8c3f1 Mon Sep 17 00:00:00 2001 From: Danica Sugic Date: Thu, 30 May 2024 15:30:43 +0100 Subject: [PATCH 2/2] Fix PR number --- CHANGES.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGES.md b/CHANGES.md index 679a9492..f18dd81d 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,7 +1,7 @@ # ChangeLog ## vx.x.x -* Edit documentation on registration in dvc steps #265 +* Edit documentation on registration in dvc steps #268 * fix some missing pip dependencies & update workflows & fix tests #233 * Edit registration-tab name from "Manual" to "Initial" #241 * Add automatic registration functionality #304