DICOM Basics using Java - Radiation Therapy (RT) Objects

Introduction

This is part of my series of articles on the DICOM standard. In this tutorial, we'll explore DICOM Radiation Therapy (RT) objects, which are used in radiation oncology to store treatment planning and delivery information. These objects are complex and typically created by treatment planning systems (TPS).

Understanding RT objects is essential for anyone working with radiation therapy data integration, including PACS vendors, treatment planning system developers, and clinical informatics specialists.

Prerequisites

Before you begin, ensure you have the following:

  • Java JDK installed (Java 8 or later)
  • PixelMed Java DICOM Toolkit
  • Basic understanding of radiation therapy concepts
  • You can find all the code demonstrated in this tutorial on GitHub here

“How we spend our days is, of course, how we spend our lives.” ~ Annie Dillard

The Theory Behind Radiation Therapy Objects

DICOM RT objects represent one of the most complex and safety-critical applications of the standard. Radiation therapy delivers potentially lethal doses to targets within the human body - precision and data integrity are literally life-or-death matters.

The Radiation Therapy Data Chain

Understanding RT objects requires understanding the treatment planning workflow:

  1. Imaging: CT simulation acquires planning images with patient in treatment position
  2. Contouring: Radiation oncologist delineates tumor (target) and normal organs (OARs)
  3. Planning: Dosimetrist/physicist designs beam arrangements to maximize target dose while minimizing OAR dose
  4. Review: Plan is evaluated using dose-volume histograms (DVH)
  5. Delivery: Linear accelerator delivers radiation according to plan
  6. Verification: Treatment record confirms delivery matched prescription

Each step produces DICOM objects that must reference previous steps correctly. An error in this chain could result in treating the wrong location or wrong dose.

The Geometric Reference Chain

A critical concept in RT is the Frame of Reference UID that chains all objects together spatially:

  • CT images define the coordinate system (Frame of Reference)
  • RT Structure Set references CT's Frame of Reference for contour coordinates
  • RT Plan references Structure Set and inherits the same coordinate system
  • RT Dose is computed in the same coordinate system

This chain ensures that when the plan says "deliver radiation to coordinates (x, y, z)", those coordinates mean the same physical location throughout the workflow.

The Dose Uncertainty Problem

RT Dose objects store 3D dose distributions, but these are calculated estimates, not measurements. Understanding the limitations:

  • Dose calculation algorithms make physics approximations
  • Patient anatomy changes between planning and treatment
  • Delivered beams have small variations from planned beams

The Dose Summation Type attribute indicates whether the dose is for a single beam, single fraction, or entire treatment plan - critical for correct interpretation.

Safety-Critical Data Integrity

RT objects carry special safety considerations:

  • Machine Parameters: Wrong gantry angle, collimator setting, or MLC position could be catastrophic
  • Reference Integrity: Plans must reference the correct structure set; wrong contours mean wrong treatment
  • Unit Consistency: Dose in Gy vs cGy, angles in degrees - unit errors have caused fatal accidents

The complexity of RT objects reflects the complexity of safe radiation delivery. Every attribute exists because its absence or error could harm patients.

RT SOP Classes

SOP ClassUIDPurpose
RT Structure Set1.2.840.10008.5.1.4.1.1.481.3Anatomical contours
RT Plan1.2.840.10008.5.1.4.1.1.481.5Treatment beam parameters
RT Dose1.2.840.10008.5.1.4.1.1.481.23D dose distribution
RT Image1.2.840.10008.5.1.4.1.1.481.1Portal images, DRRs
RT Beams Treatment Record1.2.840.10008.5.1.4.1.1.481.4Delivered treatment

RT Structure Set

RT Structure Set contains contours defining anatomical structures and targets drawn on planning CT/MR images:

System.out.println("RT Structure Set Key Tags:");
System.out.println("  (3006,0020) Structure Set ROI Sequence");
System.out.println("  (3006,0039) ROI Contour Sequence");
System.out.println("  (3006,0080) RT ROI Observations Sequence");

Example Structure Set:

Structure Set ROI Sequence (3006,0020):
  Item 1:
    ROI Number: 1
    ROI Name: PTV (Planning Target Volume)
    ROI Generation Algorithm: MANUAL
  Item 2:
    ROI Number: 2
    ROI Name: Spinal Cord
    ROI Generation Algorithm: MANUAL
  Item 3:
    ROI Number: 3
    ROI Name: Left Lung
    ROI Generation Algorithm: AUTOMATIC

ROI Contour Sequence (3006,0039):
  Item 1 (ROI 1 - PTV):
    Contour Sequence:
      - Slice 1: 45 points, CLOSED_PLANAR
      - Slice 2: 52 points, CLOSED_PLANAR
    ROI Display Color: 255\0\0 (Red)

RT Plan

RT Plan contains treatment beam parameters, dose prescriptions, and fraction schemes:

System.out.println("RT Plan Key Tags:");
System.out.println("  (300A,00B0) Beam Sequence");
System.out.println("  (300A,0070) Fraction Group Sequence");
System.out.println("  (300C,0060) Referenced Structure Set Sequence");

Example RT Plan:

Plan Information:
  RT Plan Label: LUNG_SBRT_5FX
  Plan Intent: CURATIVE

Fraction Group Sequence (300A,0070):
  Fraction Group Number: 1
  Number of Fractions Planned: 5
  Number of Beams: 7

Beam Sequence (300A,00B0):
  Beam 1:
    Beam Number: 1
    Beam Name: AP
    Beam Type: STATIC
    Radiation Type: PHOTON
    Nominal Beam Energy: 6 MV
    Gantry Angle: 0.0
    Collimator Angle: 0.0
    MLC Sequence: (leaf positions)

RT Dose

RT Dose contains the 3D dose distribution grid and dose-volume histograms (DVH):

System.out.println("RT Dose Key Tags:");
System.out.println("  (3004,0002) Dose Units");
System.out.println("  (3004,0004) Dose Type");
System.out.println("  (3004,000A) Dose Summation Type");
System.out.println("  (3004,0050) DVH Sequence");

Example RT Dose:

Dose Information:
  Dose Units: GY
  Dose Type: PHYSICAL
  Dose Summation Type: PLAN
  Dose Grid Scaling: 0.0001

Dose Grid:
  Rows: 256
  Columns: 256
  Number of Frames: 80
  Pixel Spacing: 2.0\2.0 mm

DVH Sequence (3004,0050):
  DVH 1 (PTV):
    DVH Type: CUMULATIVE
    DVH Dose Scaling: 0.01
    DVH Volume Units: CM3
  DVH 2 (Spinal Cord):
    DVH Max Dose: 8.5 Gy
    DVH Mean Dose: 2.3 Gy

RT Workflow

The typical radiation therapy workflow and associated DICOM objects:

StepDescriptionOutput
1. ImagingCT simulation scanCT Image Series
2. ContouringDraw targets and OARsRT Structure Set
3. PlanningDesign beam arrangementRT Plan + RT Dose
4. ApprovalPhysician reviews plan(Approved plan)
5. DeliveryTreatment deliveredRT Beams Treatment Record
6. VerificationPortal imagingRT Image

RT Object Relationships

CT Images

RT Structure Set (references CT)

RT Plan (references Structure Set)

RT Dose (references Plan)

RT Beams Treatment Record (references Plan)

Common Terminology

TermDescription
GTVGross Tumor Volume - visible tumor
CTVClinical Target Volume - GTV + microscopic disease
PTVPlanning Target Volume - CTV + margins
OAROrgan At Risk - structures to spare
DVHDose-Volume Histogram
MLCMulti-Leaf Collimator
SBRTStereotactic Body Radiation Therapy
IMRTIntensity-Modulated Radiation Therapy

Conclusion

DICOM RT objects provide a comprehensive framework for storing and exchanging radiation therapy data. Understanding the relationships between RT Structure Set, RT Plan, RT Dose, and other RT objects is essential for building systems that integrate with radiation oncology workflows.

While RT objects are typically created by specialized treatment planning systems, understanding their structure enables building PACS integration, dose tracking, and clinical decision support applications for radiation oncology. In the next tutorial in this series, I will cover DICOM Waveforms for storing ECG, EEG, and other physiological signals. See you then!