Portpy: An Open-Source Platform for Benchmarking and Clinical Translation of Radiotherapy Treatment Planning Optimization
Abstract
Purpose
We present PortPy (Planning and Optimization for Radiation Therapy in Python), an open-source platform designed to accelerate research, benchmarking, and clinical translation of treatment planning optimization algorithms. PortPy provides curated benchmark datasets (100 lung and 129 prostate cases) and a comprehensive suite of IMRT and VMAT optimization tools. Native interfaces to commercial treatment planning systems (TPSs) enable rapid evaluation and translation of new algorithms.
Methods
PortPy implements a broad range of classical and advanced optimization methods for IMRT and VMAT, including fluence-map-optimization, leaf-sequencing, direct-aperture-optimization, and column-generation techniques. An AI-based 3D dose prediction module is also included. For research on challenging non-convex planning problems—such as VMAT optimization and beam angle selection—PortPy provides mixed-integer programming formulations capable of computing globally optimal solutions. Although computationally intensive and not intended for routine clinical use, these methods provide high-quality ground truth for benchmarking faster, clinically viable approaches. The publicly released lung and prostate datasets include CT images, contours, clinical plans, and dose-influence matrices extracted from a commercial TPS via scripting APIs. Tight TPS integration enables plan evaluation within an FDA-approved environment against current clinical practice. PortPy has recently been clinically deployed for automated VMAT planning, with optimization performed in PortPy and final dose calculation executed in the TPS.
Results
More than ten reproducible, Jupyter-notebook–based examples demonstrate end-to-end IMRT and VMAT planning workflows using classical and AI-driven optimization methods. PortPy is used in routine clinical practice to generate automated VMAT plans, bypassing the TPS optimization engine and relying only on the TPS for final dose calculation. The platform has shown growing community adoption, averaging over 1,000 downloads per month in the past year.
Conclusion
PortPy combines openly accessible benchmark datasets, advanced optimization algorithms, and seamless TPS integration to enable transparent, reproducible research and direct clinical evaluation, and even clinical deployment, of novel treatment planning methods.