Skip to content

Commit

Permalink
Write files out to show AOS plotting is working
Browse files Browse the repository at this point in the history
  • Loading branch information
mfisherlevine committed Nov 30, 2024
1 parent 89dbf3c commit 67798a8
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions python/lsst/donut/viz/plot_aos_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,13 @@ def runQuantum(

zkPyramid, residPyramid, intrinsicPyramid = self.plotZernikePyramids(aos_raw)

# visit = inputRefs.aggregateAOSRaw.dataId["visit"]
# day_obs, seq_num = get_day_obs_seq_num_from_visitid(visit)
# filename = f"/sdf/home/m/mfl/u/rubintv/plots/{day_obs}_{seq_num}-zk_measurement_pyramid.png"
# Path(filename).touch()
# filename = f"/sdf/home/m/mfl/u/rubintv/plots/{day_obs}_{seq_num}-zk_residual_pyramid.png"
# Path(filename).touch()

butlerQC.put(zkPyramid, outputRefs.measuredZernikePyramid)
butlerQC.put(residPyramid, outputRefs.residualZernikePyramid)
butlerQC.put(intrinsicPyramid, outputRefs.intrinsicZernikePyramid)
Expand All @@ -124,13 +131,20 @@ def runQuantum(
zk_resid_fn = Path(tmpdir) / "zk_residual_pyramid.png"
residPyramid.savefig(zk_resid_fn)

# XXX remove this!
filename = f"/sdf/home/m/mfl/u/rubintv/plots/{day_obs}_{seq_num}-zk_measurement_pyramid.png"
Path(filename).touch()
self.uploader.uploadPerSeqNumPlot(
instrument=get_instrument_channel_name(instrument),
plotName="zk_measurement_pyramid",
dayObs=day_obs,
seqNum=seq_num,
filename=zk_meas_fn,
)

# XXX remove this!
filename = f"/sdf/home/m/mfl/u/rubintv/plots/{day_obs}_{seq_num}-zk_residual_pyramid.png"
Path(filename).touch()
self.uploader.uploadPerSeqNumPlot(
instrument=get_instrument_channel_name(instrument),
plotName="zk_residual_pyramid",
Expand Down Expand Up @@ -373,6 +387,9 @@ def runQuantum(
donut_gallery_fn = Path(tmpdir) / f"fp_donut_gallery_{visit}.png"
fig.savefig(donut_gallery_fn)

# XXX remove this!
filename = f"/sdf/home/m/mfl/u/rubintv/plots/{day_obs}_{seq_num}-fp_donut_gallery.png"
Path(filename).touch()
self.uploader.uploadPerSeqNumPlot(
instrument=get_instrument_channel_name(instrument),
plotName="fp_donut_gallery",
Expand Down

0 comments on commit 67798a8

Please sign in to comment.