[Gate-users] Position Voxel PET Source on top of DICOM CT
BAKER, Mark (THE CLATTERBRIDGE CANCER CENTRE NHS FOUNDATION TRUST)
mark.baker23 at nhs.net
Fri Apr 8 15:01:03 CEST 2022
Hi Julia
Thank you very much for your prompt and thorough reply. I'm using my simulations for dosimetry also at the moment, although as you say, it probably doesn't matter much. On the plus side, my understanding matches your description of what I think *should* be happening.
I have been using ImageJ to review the images, and whilst the slices appear in a different order between the two components, the mm position of each slice aligns fine (one just counts up and the other counts down). I will check with 3D slicer (and maybe amide which is a new one for me) as independent check.
Thank you
Mark Baker
Principal Clinical Scientist
Imaging Physics (Ionising)
The Clatterbridge Cancer Centre NHS Foundation Trust
(he, him)
CCCW Tel: 0151 556 5030
CCCL Tel: 0151 318 8438
Email: mark.baker23 at nhs.net<mailto:mark.baker23 at nhs.net>
Microsoft Teams (click here)<https://teams.microsoft.com/l/chat/0/0?users=mark.baker23@nhs.net>
From: Julia Franziska Brosch-Lenz <jbrosch at bccrc.ca>
Sent: 07 April 2022 17:23
To: BAKER, Mark (THE CLATTERBRIDGE CANCER CENTRE NHS FOUNDATION TRUST) <mark.baker23 at nhs.net>
Cc: gate-users at lists.opengatecollaboration.org
Subject: RE: Position Voxel PET Source on top of DICOM CT
Hi Mark,
I am not sure if you want to simulate absorbed dose (because you mention you use a F18 PET image as source input) or whether you would like to simulate a F18 PET image of a patient/phantom. Anyways, that doesn't matter. In can only share my experience with dose simulations using voxelized input:
In my dosimetry simulations, I have usually used the mhd format and ensured beforehand that the CT and source are registered by loading them in an imaging viewing software (I am a big fan of 'amide', but 3DSlicer is also popular), but also by comparing the mhd header files. With that, I don't have to bother about any translation or offset between CT and source image later.
Next, the voxelized source has to be shifted by half of it's size in x,y,z.
Here an example from one of my simulations: my image matrix is 256x256x1000. My voxel size is 0.145x0.145x0.145 mm^3. That makes a total image size of 37.12 37.12 145 mm^3. That means the command line for my source is:
# Source has always to be shifted to -1/2 of its total length in x,y,z
/gate/source/YOURSOURCE/setPosition -18.56 -18.56 -72.5 mm
Lastly, here is a snippet from the GATE manual:
7.3.2. Position<https://opengate.readthedocs.io/en/latest/voxelized_source_and_phantom.html#id20>
By default the activity image is placed in the "first quarter", i.e. the image is placed starting at 0 0 0 mm (x, y, z). This is different from the placing of volumes in Geant4 and GATE where volumes are centered on their geometrical center. In order to align the activity image with a phantom volume, a translation is needed which in the simplest case (where the activity image has the same size and position as the volume) is a translation of half the size of the volume in the negative direction.
Hope that helps you for the source positioning. Unfortunately, I have not enough experience with the GATE visualization to help you there.
Cheers,
Julia
From: Gate-users <gate-users-bounces at lists.opengatecollaboration.org<mailto:gate-users-bounces at lists.opengatecollaboration.org>> On Behalf Of BAKER, Mark (THE CLATTERBRIDGE CANCER CENTRE NHS FOUNDATION TRUST)
Sent: April 7, 2022 7:18 AM
To: gate-users at lists.opengatecollaboration.org<mailto:gate-users at lists.opengatecollaboration.org>
Subject: [Gate-users] Position Voxel PET Source on top of DICOM CT
This email came from an EXTERNAL SENDER. If you think this message is suspicious, please do not open any attached files or links, and forward it as an attachment to spammail at bccrc.ca<mailto:spammail at bccrc.ca>
Hi all
I'm really struggling with my current macro, in which I am aiming to position a F18 PET image as a voxelised source on top of a CT image. I have two sets of data at the moment, a patient image and a NEMA phantom image. With the NEMA phantom image, when observing the geometry using OGL, my trajectories appear to come from what I think is too far a negative z-direction (assuming the axis from the visualisation is pointing in a positive direction) i.e. almost the edge of the world and definitely outside of the CT phantom image. With the patient image, the source distribution does overlay the CT information, but it is flipped such that the head is in the pelvis region and vice versa.
My best guess is that the orientation or offset of either setup is incorrect. The CT dataset originally started as set as 0 translation in all directions, with no rotation axis or angle, and the source position set as negative half of the PET image size (e.g. -400 -400 -170 mm) - this is what I understand as to how the images should be arranged. However, I have tried all sorts of combinations of rotations, translations and source positions (including some wild numbers just to see if they make any impact) but they don't change what I'm seeing. I get the same effect whether the images are DCM or MHD (albeit converted from DCM to MHD using ImageJ).
I've attached all three relevant macs to this email. To actually run Gate, I use a script to pass variables into 8 instances of Gate in order to utilise the 8 cores on the machine. Only main1.mac contains instructions to open the visualisation (as main2-8 are exact copies, there is no need to duplicate resource demand).
I'm sure I am just missing something really obvious, but I'd appreciate if anyone could help me out.
Additionally, whether this is related or not, but when I first open the terminal and run my macro, I can almost guarantee that the process will hang on deleting the visualisation manager the first time it is run. I can CTRL-C and then re-run the exact same script, and it proceeds fine. It only started doing this pretty recently, and I'm not sure what I have done differently to cause this. It might possibly be linked, or might be a total red herring.
Thank you
Mark Baker
Principal Clinical Scientist
Imaging Physics (Ionising)
The Clatterbridge Cancer Centre NHS Foundation Trust
(he, him)
CCCW Tel: 0151 556 5030
CCCL Tel: 0151 318 8438
Email: mark.baker23 at nhs.net<mailto:mark.baker23 at nhs.net>
Microsoft Teams (click here)<https://teams.microsoft.com/l/chat/0/0?users=mark.baker23@nhs.net>
Honorary Lecturer, Dept. of Physics
University of Liverpool
[CCC email footer April 2021]
************************************************************************************** ******************************
This message may contain confidential information. If you are not the intended recipient please:
i) inform the sender that you have received the message in error before deleting it; and
ii) do not disclose, copy or distribute information in this e-mail or take any action in relation to its content (to do so is strictly prohibited and may be unlawful).
Thank you for your co-operation.
NHSmail is the secure email, collaboration and directory service available for all NHS staff in England. NHSmail is approved for exchanging patient data and other sensitive information with NHSmail and other accredited email services.
For more information and to find out how you can switch visit Joining NHSmail - NHSmail Support<https://support.nhs.net/article-categories/joining-nhsmail/>
This message originated from outside of NHSmail. Please do not click links or open attachments unless you recognise the sender and know the content is safe.
************************************************************************************** ******************************
This message may contain confidential information. If you are not the intended recipient please:
i) inform the sender that you have received the message in error before deleting it; and
ii) do not disclose, copy or distribute information in this e-mail or take any action in relation to its content (to do so is strictly prohibited and may be unlawful).
Thank you for your co-operation.
NHSmail is the secure email, collaboration and directory service available for all NHS staff in England. NHSmail is approved for exchanging patient data and other sensitive information with NHSmail and other accredited email services.
For more information and to find out how you can switch visit Joining NHSmail - NHSmail Support<https://support.nhs.net/article-categories/joining-nhsmail/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opengatecollaboration.org/pipermail/gate-users/attachments/20220408/cb37a1da/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.jpg
Type: image/jpeg
Size: 13489 bytes
Desc: image001.jpg
URL: <http://lists.opengatecollaboration.org/pipermail/gate-users/attachments/20220408/cb37a1da/attachment-0001.jpg>
More information about the Gate-users
mailing list