408 {
409 setDouble(metadata,
"EXPTIME",
visitInfo.getExposureTime(),
"Exposure time (sec)");
410 setDouble(metadata,
"DARKTIME",
visitInfo.getDarkTime(),
"Time from CCD flush to readout (sec)");
412 metadata.
set(
"DATE-AVG",
visitInfo.getDate().toString(::DateTime::TAI),
413 "TAI date at middle of observation");
414 metadata.
set(
"TIMESYS",
"TAI");
415 }
416 setDouble(metadata,
"MJD-AVG-UT1",
visitInfo.getUt1(),
"UT1 MJD date at ctr of obs");
417 setAngle(metadata,
"AVG-ERA",
visitInfo.getEra(),
"Earth rot ang at ctr of obs (deg)");
419 setAngle(metadata,
"BORE-RA",
boresightRaDec[0],
"ICRS RA (deg) at boresight");
420 setAngle(metadata,
"BORE-DEC",
boresightRaDec[1],
"ICRS Dec (deg) at boresight");
421 auto boresightAzAlt =
visitInfo.getBoresightAzAlt();
422 setAngle(metadata, "BORE-AZ", boresightAzAlt[0], "Refr app topo az (deg) at bore");
423 setAngle(metadata, "BORE-ALT", boresightAzAlt[1], "Refr app topo alt (deg) at bore");
424 setDouble(metadata,
"BORE-AIRMASS",
visitInfo.getBoresightAirmass(),
"Airmass at boresight");
425 setAngle(metadata,
"BORE-ROTANG",
visitInfo.getBoresightRotAngle(),
"Rotation angle (deg) at boresight");
426 metadata.
set(
"ROTTYPE", rotTypeStrFromEnum(
visitInfo.getRotType()),
"Type of rotation angle");
427 auto observatory =
visitInfo.getObservatory();
428 setAngle(metadata, "OBS-LONG", observatory.getLongitude(), "Telescope longitude (+E, deg)");
429 setAngle(metadata, "OBS-LAT", observatory.getLatitude(), "Telescope latitude (deg)");
430 setDouble(metadata, "OBS-ELEV", observatory.getElevation(), "Telescope elevation (m)");
432 setDouble(metadata, "AIRTEMP", weather.getAirTemperature(), "Outside air temperature (C)");
433 setDouble(metadata, "AIRPRESS", weather.getAirPressure(), "Outdoor air pressure (P)");
434 setDouble(metadata, "HUMIDITY", weather.getHumidity(), "Relative humidity (%)");
435 setString(metadata,
"INSTRUMENT",
visitInfo.getInstrumentLabel(),
436 "Short name of the instrument that took this data");
438 metadata.
set(
"IDNUM",
visitInfo.getId(),
"identifier of this full focal plane exposure");
439 }
440 setDouble(metadata,
"FOCUSZ",
visitInfo.getFocusZ(),
"Defocal distance (mm)");
441 setString(metadata,
"OBSTYPE",
visitInfo.getObservationType(),
"Type of this observation");
442 setString(metadata,
"PROGRAM",
visitInfo.getScienceProgram(),
443 "observing program (survey or proposal) identifier");
444 setString(metadata,
"REASON",
visitInfo.getObservationReason(),
445 "reason this observation was taken, or its purpose");
446 setString(metadata,
"OBJECT",
visitInfo.getObject(),
"object of interest or field name");
447 metadata.
set(
"HAS-SIMULATED-CONTENT",
visitInfo.getHasSimulatedContent(),
448 "Was any part of this observation simulated?");
449}
table::CoordKey boresightRaDec
bool isValid() const noexcept
Return true if the key was initialized to valid offset.
void set(std::string const &name, T const &value)
Replace all values for a property name (possibly hierarchical) with a new scalar value.