Python tool to generate test DICOMS that follow the BAD AI Dermatology standard
This tool was build to allow the generation of DICOM data for use as part of the MELODY project.
The dicomiser takes a metadata CSV and any number of images (JPGs, PNGs etc) and generates a single multi-frame DICOM.
- Python3
- DCMTK
- Set an environment variable called
img2dcmthat points to the img2dcm DCMTK tool e.g.$img2dcm=~/jfriel/dmctk/bin/img2dcm - install dependencies
pip install -r requirements.txt
python dicomiser.py OUTPUT_DIRECTORY METADATA_FILE IMAGE...
A template metadata CSV is provided within this repository.
It contains entries for all values that may be populated within the generated DICOM.
All values are optional.
Test Data can be generated by running the testDataGenerator.py script
- Multi-Frame images are currently very restricted, and require all images to be the same type and size
- Currently only works with JPGs