Best method for importing CT datasets

Hello all,
I am currently writing a geant4 application to calculate the dose imparted to a sample during a CT scan. Until now I had thought the only way to import data into geant for was to first convert it to a surface mesh (such as stl) and then import that using CADMesh or something similar. However, while I’ve made a lot of progress using that method, I have just found there is another way to import data using DICOM files instead. I do not know anything more about it except that it exists and there is a example of it in the extended session, in hope of saving time would anyone be able to share their experiences on the pros vs cons of each method and whether it is worth switching over?

The dataset i want to import is 8Gb in size (1900x2150x500 pixels) and consists of at minimum three different materials. The main thing I am after right now is which is easier to work with and which will produce the most optimised solid for running x-ray scattering with. For using the stl files I have been imported them and then nesting the inner regions into the outer ones by assigning daughter volumes.

Thanks in advance for the help,

Hi James,

I have made efforts in importing dicom images in geant4. I do not know about the dataset you talking. Are they CT images (RT)? If so you can switch dcmtk to turn on (1) and you can make changes in data new file to check your material and geometry. First line in data new file is responsible for size of voxels (pixels).


Thank you drvijayraj,
I ended up looking through the DICOM code and found they typically constructed the dataset using a G4PVParameterised volume which places a cube at each voxel position of the dataset in a memory efficient manner. Running with this parameterisation is much more efficient and I would recommend it to anyone starting out.

Exactly, and I also would like to add a statement if someone wants to speed up the simulation;
one can turn ON the → SetSkipEqualMaterials to TRUE ; This is very helpful when we down compression to 1 else there is an error over the navigation problem.
Best Regards