Gear is under active development and current Release Candidate is subject to change. At present, running the Presidio-Image-Redactor as a Gear Rule is not supported, but will be added in a future release.
PLEASE NOTE: The methodologies used in this gear for identifying text & PHI entities in medical images relies heavily on statistics-based models and algorithms. These methodologies are not fullproof and it is highly recommended that human-in-the-loop workflows are implemented to verify the identification of PHI or text entities.
This gear builds upon Microsoft's open source Presidio SDK to scan DICOM images for potential Personal Identifiable Information (PII), report on PII findings, generate example images with bounding boxes embedded, generate ReaderTasks with annotated PHI entities, and the option to redact PII stored within DICOM pixel data.
Additional information on Microsoft's Presidio SDK can be found on their website and through their GitHub Page.
MIT
Category: Converter
Gear Level:
DICOM image or series to be scanned/redacted
Coordinates of bounding boxes encapsulating PII
Debug
Assignees
Baseline Operating Mode
Transformer Score Threshold
Entity Frequency Threshold
Use DICOM Metadata
Entities to Find
API Key Path
There are four operating modes for the image redactor gear. Regardless of
selected operating mode, the presidio-image-redactor will tag files that it
runs on with its gear name: presidio-image-redactor .
- A csv denoting PII entities found alongside corresponding bounding box coordinates
- A duplicate DICOM image with bounding boxes overlaid on the image
- A
.jsonfile containing the coordinates for the bounding boxes
Lastly, the gear will tag files and acquisition containers with
PHI-Foundif PII was identified andPHI-Not-Foundif no PHI was identified.
- A Reader Protocol, default name
presidio_default_protocolfor assigning ReaderTasks to- A ReaderTask for the image that is being processed
- Annotations of the returned bounding boxes, overlaying them on the ReaderTask image
Only 1 ReaderTask is created for a given
input_fileand is assigned using theAssigneesconfiguration option.
This operating mode permits an optional configuration option called "Bbox_coords". This optional configuration option allows the user to input the bounding box coordinates from their Detection Only job to the gear which will prevent the gear from scanning for a second time and proceed directly to redacting the image.
Operating the gear in this mode will cause the gear to redact any and all text that it finds in the image, regardless if it is PHI or not.
Identified PHI
Bounding box DICOM(s)
Redacted DICOM(s)
Gear Tag
PHI Tag
No PHI Tag
There are no specific pre-requisites in order to run this gear. All that is needed is a DICOM image or series. However, it is recommended that users have some pre-existing knowledge of de-identification processes to effectively identify which PII entities to look for and obscure.
This gear runs Optical Character Recognition (OCR), NER, and regex operations in order to identify PII entities in DICOM pixel data. PII identified by these algorithms are then cataloged for review by the user, consolidated into a ReaderTask for human review, or redact to ensure subject privacy during research.
At this time, DICOM images or series must have the photometric interpretation metadata value of MONOCHROME1, MONOCHROME2, or RGB. It is highly recommended to first run the dicom-fixer on all DICOM files prior running Presidio Image Redactor. Improper metadata formatting or alternative pixel compression formats can impair or terminate the gear run.
A picture and description of the workflow
graph LR;
A["Input<br>DICOM Image"]:::start;
A --> X[Detection+ReaderTasks]:::input --> H;
A --> Y[DetectionOnly]:::input --> D;
A --> C[RedactAllText]:::input --> L;
H[Human-in-the-loop <br>ReaderTask annotations review]:::container-->I;
D[Review any found PII <br> Decide if further scanning required]:::container-->E;
L[Review images to determine if sufficient text removed]:::container --> K
E((Run gear in <br> Dynamic PHI Redaction)):::gear --> F;
I((Run<br>image-redaction-exporter)):::gear --> J;
K[Review redacted outputs <br> Move redacted files to deid project]:::output
F[Review redacted outputs <br> Move redacted files to deid project]:::output;
J[Review redacted outputs <br> Move redacted files to deid project]:::output;
classDef start fill:#415e9a,color:#fff
classDef container fill:#415e9a,color:#fff
classDef input fill:#008080,color:#fff
classDef gear fill:#659,color:#fff
classDef output fill:#005851
PHI Detection + ReaderTask Pipeline: You need to conduct PHI identification and redaction on your data set & require human-in-the-loop verification of gear's identification performance.
- Prep the images by ensuring
dicom-fixerhas been run on all your images.- Enter the Flywheel emails of the individuals that will be reviewing the ReaderTasks.
- Select the
Detection+ReaderTasksoperating mode in the configuration options.- Run the gear & have your Readers complete their Assigned ReaderTasks. Ensure Readers add or remove annotations on the image as needed.
- Once satisfied that your dataset has been de-identified, run the
image-redaction-exporterto redact all areas indicated by ReaderTask annotations.- Export data to clean project or instance, or simply begin data analytics.
Simple PHI Scan & Redact
- Prep the images by ensuring
dicom-fixerhas been run on all your images.- Select the
DetectionOnlyoperating mode in the configuration options.- Run the gear & inspect output files showcasing identified PHI.
- Once satisfied that your dataset has been de-identified, run the gear again and set the operating mode to
Dynamic PHI Redaction. The gear will run and redact the entities that were found. You may choose to provide the bounding box json as an additional input.- Export data to clean project or instance, or simply begin data analytics.
Complete Text Removal
- Prep the images by ensuring
dicom-fixerhas been run on all your images.- Select the
RedactAllTextoperating mode in the configuration options.- Run the gear & inspect output to determine if sufficient text has been removed from the images.
- Export data to clean project or instance, or simply begin data analytics.
Logging implemented for this gear aims to provide the user with an understanding of what flags were passed into the gear, what mode of operation the gear is currently running, and what outputs are provided upon completion.
To facilitate troubleshooting, raw OCR results can be created when running the gear in debug mode.
[For more information about how to get started contributing to that gear, checkout CONTRIBUTING.md.]
Python
99.2%
Gear is under active development and current Release Candidate is subject to change. At present, running the Presidio-Image-Redactor as a Gear Rule is not supported, but will be added in a future release.
PLEASE NOTE: The methodologies used in this gear for identifying text & PHI entities in medical images relies heavily on statistics-based models and algorithms. These methodologies are not fullproof and it is highly recommended that human-in-the-loop workflows are implemented to verify the identification of PHI or text entities.
This gear builds upon Microsoft's open source Presidio SDK to scan DICOM images for potential Personal Identifiable Information (PII), report on PII findings, generate example images with bounding boxes embedded, generate ReaderTasks with annotated PHI entities, and the option to redact PII stored within DICOM pixel data.
Additional information on Microsoft's Presidio SDK can be found on their website and through their GitHub Page.
MIT
Category: Converter
Gear Level:
DICOM image or series to be scanned/redacted
Coordinates of bounding boxes encapsulating PII
Debug
Assignees
Baseline Operating Mode
Transformer Score Threshold
Entity Frequency Threshold
Use DICOM Metadata
Entities to Find
API Key Path
There are four operating modes for the image redactor gear. Regardless of
selected operating mode, the presidio-image-redactor will tag files that it
runs on with its gear name: presidio-image-redactor .
- A csv denoting PII entities found alongside corresponding bounding box coordinates
- A duplicate DICOM image with bounding boxes overlaid on the image
- A
.jsonfile containing the coordinates for the bounding boxes
Lastly, the gear will tag files and acquisition containers with
PHI-Foundif PII was identified andPHI-Not-Foundif no PHI was identified.
- A Reader Protocol, default name
presidio_default_protocolfor assigning ReaderTasks to- A ReaderTask for the image that is being processed
- Annotations of the returned bounding boxes, overlaying them on the ReaderTask image
Only 1 ReaderTask is created for a given
input_fileand is assigned using theAssigneesconfiguration option.
This operating mode permits an optional configuration option called "Bbox_coords". This optional configuration option allows the user to input the bounding box coordinates from their Detection Only job to the gear which will prevent the gear from scanning for a second time and proceed directly to redacting the image.
Operating the gear in this mode will cause the gear to redact any and all text that it finds in the image, regardless if it is PHI or not.
Identified PHI
Bounding box DICOM(s)
Redacted DICOM(s)
Gear Tag
PHI Tag
No PHI Tag
There are no specific pre-requisites in order to run this gear. All that is needed is a DICOM image or series. However, it is recommended that users have some pre-existing knowledge of de-identification processes to effectively identify which PII entities to look for and obscure.
This gear runs Optical Character Recognition (OCR), NER, and regex operations in order to identify PII entities in DICOM pixel data. PII identified by these algorithms are then cataloged for review by the user, consolidated into a ReaderTask for human review, or redact to ensure subject privacy during research.
At this time, DICOM images or series must have the photometric interpretation metadata value of MONOCHROME1, MONOCHROME2, or RGB. It is highly recommended to first run the dicom-fixer on all DICOM files prior running Presidio Image Redactor. Improper metadata formatting or alternative pixel compression formats can impair or terminate the gear run.
A picture and description of the workflow
graph LR;
A["Input<br>DICOM Image"]:::start;
A --> X[Detection+ReaderTasks]:::input --> H;
A --> Y[DetectionOnly]:::input --> D;
A --> C[RedactAllText]:::input --> L;
H[Human-in-the-loop <br>ReaderTask annotations review]:::container-->I;
D[Review any found PII <br> Decide if further scanning required]:::container-->E;
L[Review images to determine if sufficient text removed]:::container --> K
E((Run gear in <br> Dynamic PHI Redaction)):::gear --> F;
I((Run<br>image-redaction-exporter)):::gear --> J;
K[Review redacted outputs <br> Move redacted files to deid project]:::output
F[Review redacted outputs <br> Move redacted files to deid project]:::output;
J[Review redacted outputs <br> Move redacted files to deid project]:::output;
classDef start fill:#415e9a,color:#fff
classDef container fill:#415e9a,color:#fff
classDef input fill:#008080,color:#fff
classDef gear fill:#659,color:#fff
classDef output fill:#005851
PHI Detection + ReaderTask Pipeline: You need to conduct PHI identification and redaction on your data set & require human-in-the-loop verification of gear's identification performance.
- Prep the images by ensuring
dicom-fixerhas been run on all your images.- Enter the Flywheel emails of the individuals that will be reviewing the ReaderTasks.
- Select the
Detection+ReaderTasksoperating mode in the configuration options.- Run the gear & have your Readers complete their Assigned ReaderTasks. Ensure Readers add or remove annotations on the image as needed.
- Once satisfied that your dataset has been de-identified, run the
image-redaction-exporterto redact all areas indicated by ReaderTask annotations.- Export data to clean project or instance, or simply begin data analytics.
Simple PHI Scan & Redact
- Prep the images by ensuring
dicom-fixerhas been run on all your images.- Select the
DetectionOnlyoperating mode in the configuration options.- Run the gear & inspect output files showcasing identified PHI.
- Once satisfied that your dataset has been de-identified, run the gear again and set the operating mode to
Dynamic PHI Redaction. The gear will run and redact the entities that were found. You may choose to provide the bounding box json as an additional input.- Export data to clean project or instance, or simply begin data analytics.
Complete Text Removal
- Prep the images by ensuring
dicom-fixerhas been run on all your images.- Select the
RedactAllTextoperating mode in the configuration options.- Run the gear & inspect output to determine if sufficient text has been removed from the images.
- Export data to clean project or instance, or simply begin data analytics.
Logging implemented for this gear aims to provide the user with an understanding of what flags were passed into the gear, what mode of operation the gear is currently running, and what outputs are provided upon completion.
To facilitate troubleshooting, raw OCR results can be created when running the gear in debug mode.
[For more information about how to get started contributing to that gear, checkout CONTRIBUTING.md.]
Python
99.2%