Changes required:
* calibDate in calib generation
* calibDate in calib ingestion
* obsDate in raw ingestion
* Calib lookup in Mapper
Let's validate using the PIPE2D-618 dataset, where we had to play games with the calib registry; such games should not be required now. We need to ingest everything from scratch, to include the times in the registry.
(lsst-scipipe) pprice@tiger2-sumire:/tigress/pprice/pipe2d-619 $ mkdir DATA
(lsst-scipipe) pprice@tiger2-sumire:/tigress/pprice/pipe2d-619 $ echo lsst.obs.pfs.PfsMapper > DATA/_mapper
(lsst-scipipe) pprice@tiger2-sumire:/tigress/pprice/pipe2d-619 $ ingestPfsImages.py DATA --pfsConfigDir /projects/HSC/PFS/Subaru/drp/pfsDesign --config parse.pfsDesignId=1099528409104 --ignore-ingested -- '/projects/HSC/PFS/Subaru/raw/2020-05-*/sps/PFSA*.fits' '/projects/HSC/PFS/Subaru/raw/2020-06-*/sps/PFSA*.fits'
(lsst-scipipe) pprice@tiger2-sumire:/tigress/pprice/pipe2d-619 $ mkdir CALIB
(lsst-scipipe) pprice@tiger2-sumire:/tigress/pprice/pipe2d-619 $ ingestPfsCalibs.py DATA --calib CALIB --validity=1800 --doraise --mode=copy ~/pfs/drp_pfs_data/detectorMap/detectorMap-2019Jul-*.fits
(lsst-scipipe) pprice@tiger2-sumire:/tigress/pprice/pipe2d-619 $ generateCommands.py DATA --calib CALIB --rerun calibs --blocks=pipe2d_618 -j 20 ../pipe2d-618/pipe2d-618.yaml calibs.sh
generateCommands INFO: Start writing shell commands on 'calibs.sh'
generateCommands INFO: Processing calib block 'pipe2d_618'
generateCommands INFO: End writing shell commands on 'calibs.sh'
(lsst-scipipe) pprice@tiger2-sumire:/tigress/pprice/pipe2d-619 $ bash calibs.sh
constructFiberTrace.py DATA --calib=CALIB --rerun=fiberTrace --doraise --batch-type=smp --cores=10 --id visit=18228..18231
constructFiberTrace.py DATA --calib=CALIB --rerun=fiberTrace --doraise --batch-type=smp --cores=10 --id visit=18236..18238
constructFiberTrace.py DATA --calib=CALIB --rerun=fiberTrace --doraise --batch-type=smp --cores=10 --id visit=18245..18248
...
(lsst-scipipe) pprice@tiger2-sumire:/tigress/pprice/pipe2d-619 $ ingestPfsCalibs.py DATA --calib CALIB --validity 1800 --doraise --mode=copy DATA/rerun/fiberTrace/FIBERTRACE/pfsFiberTrace-*.fits
>>> from lsst.daf.persistence import Butler
>>> butler = Butler("DATA", calibRoot="/tigress/pprice/pipe2d-619/CALIB-test")
>>> butler.get("fiberTrace_filename", visit=18228, arm="r")[0]
'/tigress/pprice/pipe2d-619/CALIB-test/FIBERTRACE/pfsFiberTrace-2020-06-02-018228-r1.fits'
>>> butler.get("fiberTrace_filename", visit=18236, arm="r")[0]
'/tigress/pprice/pipe2d-619/CALIB-test/FIBERTRACE/pfsFiberTrace-2020-06-02-018236-r1.fits'