Results Figures for the Web SiteΒΆ
This section describes how figures are produced automatically from the results of nowcast system runs to appear on the daily pages that are linked from the Model Results section of https://gomss.ocean.dal.ca/.
In summary:
Web site figures are generated by code modules stored in the
nowcast/figures/
directory tree. See Figure Modules Organization for details and links to docs about how to structure and write the functions in a figure module, and how to develop and test a figure module with the help of a Jupyter notebook.The
make_figure()
functions from figure modules are called by the nowcast systemnowcast.workers.make_plots
worker. The figure object that amake_figure()
function returns is rendered to storage on the nemo cluster. See CallingMakeFigureFunctionsInTheMakePlotsWorker for details of variables that themake_plots
worker can provide tomake_figure()
functions, and how to store the figure to the cluster storage.The title of the figure and the name of the figure file are added to a list of web site figures. The title will appear on the results figures page linked from the Model Results section of https://gomss.ocean.dal.ca/. The figure file name is used to find the figure in the cluster storage. The list of figures is in the
gomss_site.views.landing
module of the gomss.ocean.dal.ca Site Web App. The figure titles and file names are added to the list asgomss_site.views.figures.FigureMetadata
instances. See GoMSSSiteWebPageViewFigureMetadata for details of how to add figure titles and file names to the site web app view module.
The Nowcast Figures Development Environment section below explains how to set up a conda environment that you can use to:
develop figure modules
test that the
nowcast.workers.make_plots
worker can render your figures to to the figures servertest that the figure appears on a results page in the web app