-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathcreate_wall.py
More file actions
20 lines (14 loc) · 849 Bytes
/
create_wall.py
File metadata and controls
20 lines (14 loc) · 849 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# Creates a Wall ROI (zPTV_Wall) with an outward 1 cm distance from the PTV ROI.
#
from connect import *
case = get_current("Case")
examination = get_current("Examination")
with CompositeAction('Create wall (zPTV_Wall)'):
retval_0 = case.PatientModel.CreateRoi(Name=r"zPTV_Wall", Color="Gray", Type="Organ", TissueName=None, RbeCellTypeName=None, RoiMaterial=None)
retval_0.SetWallExpression(SourceRoiName=r"PTV", OutwardDistance=1, InwardDistance=0)
retval_0.UpdateDerivedGeometry(Examination=examination, Algorithm="Auto")
# CompositeAction ends
with CompositeAction('Apply ROI changes (zPTV_Wall)'):
case.PatientModel.ToggleExcludeFromExport(ExcludeFromExport=True, RegionOfInterests=[r"zPTV_Wall"], PointsOfInterests=[])
case.PatientModel.RegionsOfInterest['zPTV_Wall'].OrganData.OrganType = "Other"
# CompositeAction ends