{% extends "master.html" %} {% import 'macros.html' as mcr %} {% set active_page = "multicolor" %} {% set skymapTypes = ['SkyMap', 'TwoD', 'neoxyPlotter'] %} {% set comboplotTypes = ['ComboHistogram', 'ComboMetricVsH', 'Combo'] %} {% set hourglassTypes = ['Hourglass'] %} {% set run = runlist.getRun(runId) %} {% set metrics = run.metrics %} {% block moresidebar %} {% endblock %} {% block content %} {% set metricInfo = run.metricInfo() %} {% set ninfo = metricInfo|length %} {% for g in run.groups.keys() %} {% set groupstart = True %} {% for sg in run.groups[g] %} {# Get the metrics, skymaps and combo histograms in this subgroup. #} {% set subsetMetrics = run.metricsInSubgroup(g, sg) %} {% set skysetMetrics = run.metricsWithPlotType(plotType=skymapTypes, metrics=subsetMetrics) %} {% set combosetMetrics = run.metricsWithPlotType(plotType=comboplotTypes, metrics=subsetMetrics) %} {% set hourglassMetrics = run.metricsWithPlotType(plotType=hourglassTypes, metrics=subsetMetrics) %} {% set statNames = run.allStatNames(subsetMetrics) %} {% set displaygroup = skysetMetrics|length + combosetMetrics|length + vectorMetrics|length + hourglassMetrics|length + statNames|length %} {% if displaygroup > 0 %} {# then show this group ... #} {% if groupstart == True %} {% set groupstart = False %} {% endif %}

{{g|escape}} : {{sg|escape}}

{# In each group, plot sky maps/TwoD maps, then combo hists, then hourglass, then summary stats #} {% set metricNames = run.uniqueMetricNames(skysetMetrics, baseonly=True) %} {% for mname in metricNames %} {% set mskyset = run.metricsWithMetricName(mname, skysetMetrics, baseonly=True) %} {% set skymaps = run.getSkyMaps(mskyset, plotType=skymapTypes) %} {% set skymaps = run.orderPlots(skymaps) %} {% if skymaps|length > 0 %}
{% set metricLink = 'metricResults?runId=%s&metricId=' %(runId) %} {# add a link to click to the skymap group's details #} {% set metricSelect = run.metricsToMetricIds(mskyset)|join('&metricId=') %} {% set metricLink = metricLink ~ metricSelect %} {{mname}}
{# put in the sky map plots #} {% for skymap in skymaps %} {% set mapkey = 'SkyMap' %} {% if skymap[mapkey]['plotFile']|length == 0 %} {% else %} {% set plotfile = skymap[mapkey]['plotFile'][0] %} {% set thumbfile = skymap[mapkey]['thumbFile'][0] %} {% endif %} {% if loop.index is divisibleby 3 %} {% endif %} {% endfor %}
{% endif %} {% endfor %} {% for m in combosetMetrics %} {% set comboplots = run.plotsForMetric(m) %} {% set combodict = run.plotDict(comboplots) %} {% set combohist = combodict['ComboHistogram'] %} {% if combohist|length > 0 %}
{% set metricInfo = run.metricInfo(m) %} {{ metricInfo['MetricName']|escape }} ({{metricInfo['Slicer']|escape}})
{{metricInfo['Metadata']|escape}}

{% for plotfile, thumbfile in zip(combohist['plotFile'], combohist['thumbFile']) %} {% endfor %}
{% endif %} {% endfor %} {% if hourglassMetrics|length > 0 %}
{% for h in hourglassMetrics %} {% set metricInfo = run.metricInfo(h) %} {# {{metricInfo['Metadata']|escape}}
#} {% set hourglassplots = run.plotsForMetric(h) %} {% set hourglassdict = run.plotDict(hourglassplots) %} {% set hourglass = hourglassdict['Hourglass'] %} {% for plotfile, thumbfile in zip(hourglass['plotFile'], hourglass['thumbFile']) %} {% endfor %} {% endfor %}
{% endif %} {% if statNames | length > 0 %}
{{ mcr.MakeStatTable(subsetMetrics, g, sg, run) }}
{% endif %} {% endif %} {% endfor %} {% endfor %} {% endblock %}