lsst.sims.ocs.database.tables.write_tbls module

lsst.sims.ocs.database.tables.write_tbls.write_config(data, sid)[source]

Create a dictionary of data for the Config table.

Parameters:
  • data (tuple) – The set of information from a configuration parameter.
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the data.

lsst.sims.ocs.database.tables.write_tbls.write_field(data, sid)[source]

Create a dictionary of data for the Field table.

Parameters:
  • data (tuple) – The set of information from a field.
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_observation_exposures(data, sid)[source]

Create a dictionary of data for the ObsExposures table.

Parameters:
  • data (class:.ObsExposure) – The instance containing the observation exposure information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_observation_history(data, sid)[source]

Create a dictionary of data for the ObsHistory table.

Parameters:
  • data (SALPY_scheduler.observationC) – The SAL observation topic instance.
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_observation_proposal_history(data, sid)[source]

Create a dictionary of data for the ObsProposalHistory table.

Parameters:
  • data (tuple) – The instance containing the observation proposal history information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_proposal_field(data, sid)[source]

Create a dictionary of data for the ProposalField table.

Parameters:
  • data (tuple) – The instance containing the proposal field information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_proposal(data, sid)[source]

Create a dictionary of data for the Proposal table.

Parameters:
  • data (tuple) – The instance containing the proposal information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_scheduled_downtime(data, sid)[source]

Create a dictionary of data for the ScheduledDowntime table.

Parameters:
  • data (tuple) – The instance containing the scheduled downtime information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_slew_activities(data, sid)[source]

Create a dictionary of data for the SlewHistory table.

Parameters:
  • data (class:.SlewActivity) – The instance containing the slew activity information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_slew_history(data, sid)[source]

Create a dictionary of data for the SlewHistory table.

Parameters:
  • data (class:.SlewHistory) – The instance containing the slew history information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_slew_final_state(data, sid)[source]

Create a dictionary of data for the SlewFinalState table.

Parameters:
  • data (class:.SlewFinalState) – The instance containing the slew state information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_slew_initial_state(data, sid)[source]

Create a dictionary of data for the SlewInitialState table.

Parameters:
  • data (class:.SlewInitialState) – The instance containing the slew state information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_slew_maxspeeds(data, sid)[source]

Create a dictionary of data for the SlewMaxSpeeds table.

Parameters:
  • data (class:.SlewMaxSpeeds) – The instance containing the slew maxspeeds information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_target_exposures(data, sid)[source]

Create a dictionary of data for the TargetExposures table.

Parameters:
  • data (class:.TargetExposure) – The instance containing the target exposure information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_target_history(data, sid)[source]

Create a dictionary of data for the TargetHistory table.

Parameters:
  • data (SALPY_scheduler.targetC) – The SAL target topic instance.
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_target_proposal_history(data, sid)[source]

Create a dictionary of data for the TargetProposalHistory table.

Parameters:
  • data (tuple) – The instance containing the target proposal history information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.

lsst.sims.ocs.database.tables.write_tbls.write_unscheduled_downtime(data, sid)[source]

Create a dictionary of data for the UnscheduledDowntime table.

Parameters:
  • data (tuple) – The instance containing the unscheduled downtime information
  • sid (int) – The current session ID.
Returns:

collections.OrderedDict – A dictionary of the topic data.