I have a DICOM image series generated from Micro CT scanning. How does one read the series, store the intensity values in a 3D matrix so that data manipulation is possible?
var = dcmdir_parse(“/path/to/dicom/folder/”);
The above command reads the series and stores in the variable var.
What functions are available to process the data further?
You can search the tag you want with var[tag"TagName"]
Several examples with a RT dose DICOM file:
using DICOM
rt_dose = dcm_parse(rt_dose_path)
slice_thickness = rt_dose[tag"SliceThickness"]
pixel_spacing = rt_dose[tag"PixelSpacing"]
image_position = rt_dose[tag"ImagePositionPatient"]
dose_grid_scaling = rt_dose[tag"DoseGridScaling"]
pixel_array = float.(rt_dose[tag"PixelData"])
and for sub-tag :
beam_number = rt_dose[tag"ReferencedRTPlanSequence"][1][tag"ReferencedFractionGroupSequence"][1][tag"ReferencedBeamSequence"][1][tag"ReferencedBeamNumber"]
1 Like