MafTracking¶
- class rubin_sim.maf.web.MafTracking(database=None)¶
Bases:
object
Class to read MAF’s tracking SQLite database (tracking a set of MAF runs) and handle the output for web display.
Methods Summary
get_run
(maf_run_id)Set up a mafRunResults object to read and handle the data from an individual run.
run_info
(run)Provide the tracking database information relevant for a given run in a format that the jinja2 templates can use.
sort_runs
(runs[, order])Sort the numpy array of run data.
Methods Documentation
- get_run(maf_run_id)¶
Set up a mafRunResults object to read and handle the data from an individual run. Caches the mafRunResults object, meaning the metric information from a particular run is only read once from disk.
- Parameters:
- maf_run_id
int
maf_run_id value in the tracking database corresponding to a particular MAF run.
- maf_run_id
- Returns:
- runPage
MafRunResults
A MafRunResults object containing the information about a particular run. Stored internally in self.runs_page dict, but also passed back to the tornado server.
- runPage
- run_info(run)¶
Provide the tracking database information relevant for a given run in a format that the jinja2 templates can use.
- Parameters:
- run
numpy.NDarray
One line from self.runs
- run
- Returns:
- run_info
OrderedDict
Ordered dict version of the numpy structured array.
- run_info