From 33df3689a2a135e7ce092f20721ac62b1f9647b6 Mon Sep 17 00:00:00 2001 From: Anthony Lombardi Date: Wed, 3 Apr 2024 15:27:55 -0400 Subject: [PATCH] ENH: Update calibration writer to include comment on clipping-range --- AutoscoperM/AutoscoperMLib/IO.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/AutoscoperM/AutoscoperMLib/IO.py b/AutoscoperM/AutoscoperMLib/IO.py index c04d787..fef4c39 100644 --- a/AutoscoperM/AutoscoperMLib/IO.py +++ b/AutoscoperM/AutoscoperMLib/IO.py @@ -56,6 +56,11 @@ def generateCameraCalibrationFile(camera: Camera, filename: str): contents_json = json.dumps(contents, indent=4) + # Add comments to file + contents_json += """\n//Note: the clipping-range field is not used by Autoscoper, + this is used to commuincate information between AutoscoperM and + VirtualRadiographGeneration modules within Slicer.""" + with open(filename, "w+") as f: f.write(contents_json)