DICOM CT Data
Table of Contents
Hounsfield units
CT images used in GATE voxelized simulations normally come from DICOM CT series, where each image slice is stored as a separate DICOM file. The pixel values in these CT images represent X‑ray attenuation in the form of Hounsfield units, often abbreviated as HU. Understanding HU is essential, because later steps such as material mapping and density assignment rely on them.
Hounsfield units measure how much a material attenuates X‑rays compared with water and air. By definition, water has HU equal to 0 and air has HU equal to −1000. Dense materials such as bone and metal have positive HU values, while low‑density tissues and air have negative values. The relation between HU and the linear attenuation coefficient $\mu$ is
$$
HU = 1000 \cdot \frac{\mu - \mu_{\text{water}}}{\mu_{\text{water}} - \mu_{\text{air}}}.
$$
In practice, you do not compute HU yourself inside GATE. Instead, the CT scanner stores the raw reconstructed values and the DICOM headers describe how to convert them to HU. Two important DICOM tags control this conversion: RescaleSlope and RescaleIntercept. The raw stored integer value $v$ for each pixel is converted to HU as
$$
HU = \text{RescaleSlope} \cdot v + \text{RescaleIntercept}.
$$
In most clinical CT data, RescaleSlope is 1, but this is not guaranteed, so you must not assume it. When you read DICOM CT images in a preprocessing step with Python or another tool, you should always apply this linear transform before you treat the image as an HU map.
Always convert raw DICOM pixel values to Hounsfield units using
$HU = \text{RescaleSlope} \cdot v + \text{RescaleIntercept}$
before performing CT‑to‑material or CT‑to‑density mapping for GATE simulations.
Different tissue types occupy different HU ranges. A very rough overview is given in the table below. Exact ranges depend on scanner protocol and reconstruction settings and are typically defined more precisely in CT‑to‑material conversion tables.
| Tissue / Material | Typical HU range (approximate) |
|---|---|
| Air | −1000 |
| Lung | −900 to −500 |
| Fat | −150 to −50 |
| Water | 0 |
| Soft tissue / muscle | 20 to 80 |
| Cancellous bone | 150 to 400 |
| Cortical bone | > 400, often > 1000 |
| Metal / implants | Very high, often > 2000 |
When preparing CT data for GATE, it is common to keep the image in HU and then apply a CT‑to‑material table that groups HU ranges into discrete tissue classes, each with its own material and density. That process is described in detail in the CT‑to‑Material Conversion chapter, so here you only need to understand that HU values are the starting point for that mapping.
If you use an external tool to convert from DICOM to another image format such as MHD or NIfTI, you must check whether the conversion has already applied the RescaleSlope and RescaleIntercept. Some tools export images in HU directly. Others preserve the raw stored values and you must apply the HU conversion yourself. Mixing these two cases is a common source of error, because material mapping tables usually assume that the input is already in HU.
For robust simulations, it is helpful to verify HU values by measuring some regions of interest in the image. For example, you can draw a small cylindrical region in lung, in soft tissue, and in bone and check that the mean HU values are within reasonable ranges. If they are not, verify the rescaling parameters and the export settings of your DICOM to image conversion step.
Patient geometry
DICOM CT data describe the patient anatomy in image coordinates and physical coordinates. To build a correct patient geometry in GATE, you must understand how DICOM encodes slice positions, in‑plane orientation, and image spacing, and how that maps to the 3D volume that GATE uses.
A CT study typically consists of a series of axial slices. Each slice is a 2D grid of pixels with a certain number of rows and columns. DICOM stores the physical size of each pixel through the PixelSpacing tag, which contains two values: the spacing between pixel centers in the row and column directions, usually in millimeters. The spacing between slices is often given by SliceThickness and the relative positions by ImagePositionPatient. These values define the voxel size and the distance between slices.
From GATE’s perspective, you need a 3D voxel grid with three key properties: the number of voxels in each direction, the voxel dimensions in millimeters, and the physical location and orientation of the grid in the patient coordinate system. The process that converts a stack of DICOM slices into a voxelized volume must read the tags PixelSpacing, SliceThickness, ImagePositionPatient, and ImageOrientationPatient to determine these properties.
DICOM uses a patient‑based coordinate system. By convention, the axes are labeled as left‑right, posterior‑anterior, and inferior‑superior. The ImageOrientationPatient tag provides two direction vectors that describe the orientation of the image rows and columns in this coordinate system. Combined with ImagePositionPatient, which gives the 3D coordinates of the first pixel in the slice, you can compute the position of every voxel center in the volume. When you construct a voxelized geometry in GATE, you usually do not specify each voxel position individually. Instead, you give the overall image size, spacing, and origin, and GATE uses this to place the voxel grid.
Because GATE has its own world coordinate system, there must be a consistent mapping between the DICOM patient coordinates and the GATE coordinates. In many workflows, you choose the GATE world axes to be aligned with the DICOM patient axes. In that case, the only remaining task is to decide where the origin is placed, for example at the center of the image volume. Alternatively, you can place the patient so that a specific anatomical point, such as the isocenter of a treatment plan, coincides with the origin of the world volume. In either case, you should document clearly how this mapping is done.
Always check that the voxel grid created from DICOM CT data has the correct size, spacing, and orientation in the GATE world. Misaligned or flipped axes can cause large errors in dose and imaging simulations.
When building patient geometry from DICOM CT, you often also have associated DICOM RT Structure Sets or RT Plans. These define regions of interest such as organs or targets, and treatment beam parameters. The detailed use of RT data is covered elsewhere, but for DICOM CT data it is important to realize that all these files share the same frame of reference. The DICOM FrameOfReferenceUID ties together CT images, structures, and plans. Your geometry creation workflow must preserve this shared frame so that contours and beams line up correctly with the CT.
In practical terms, a typical patient geometry creation workflow starts by reading the DICOM CT series and sorting the slices by position. Then it determines the 3D array shape and voxel spacing from the DICOM headers, constructs an HU image volume, and defines an origin and orientation for this volume in the GATE world. Finally, the image is provided to GATE as a voxelized volume, and later steps map HU to materials and densities. Visualization tools in GATE are very useful here, because they allow you to check that the patient is positioned correctly, not mirrored, not rotated by 90 degrees, and centered where you expect.
Any transformation that you apply to the CT data, such as cropping, resampling, or reorienting from one axis convention to another, must be reflected consistently in the geometry description. If you crop the image, the physical coordinates of the new image origin change. If you resample to isotropic voxels, the voxel spacing changes. Careful bookkeeping of these operations is essential, because later CT‑to‑material conversion and dose scoring depend on the final voxel geometry, not on the original DICOM slices.
Views: 12
KAHIBARO