{% extends "base.html" %} {% block main %} {# 与 figures.PT_COLORS 保持一致 #} {% set pt_colors = {"P": "#3c5488", "T": "#e64b35", "N": "#8491b4"} %} {% set pt_stats = string_stats | selectattr("name", "equalto", "pistacking_type") | list %} {% set pt_seen = (pt_stats[0].top if pt_stats else []) | map(attribute="value") | list %} {% set legend_types = (["P", "T", "N"] | select("in", pt_seen) | list) or ["P", "T"] %} {% set has_pt = pt_stats | length > 0 %}

{{ type }}

{{ n_pairs }} pairs · {{ n_frames }} frames

CSV (all rows)

metadata

h5 file{{ meta.h5_path }}
interaction type{{ meta.type }}
pairs{{ meta.n_pairs }}
frames{{ meta.n_frames }}
{% set ts = meta.time_start if meta.time_start is not none else "—" %} {% set te = meta.time_end if meta.time_end is not none else "—" %}
time range (ps){{ ts }} → {{ te }}
metrics{{ meta.metrics | join(", ") }}
flags{{ meta.flags | join(", ") if meta.flags else "none" }}
{% if meta.file %}
file size{{ meta.file.size_kb }} KB
modified{{ meta.file.mtime }}
format version{{ meta.file.format_version or "—" }}
interactions in file{{ meta.file.n_interactions }}
{% endif %}
{% set run_info = meta.run %}

run provenance

{% if run_info %}
created at{{ run_info.created_at or "—" }}
dii version{{ run_info.dii_version or "—" }}
force field{{ run_info.ff or "—" }}
strategy{{ run_info.strategy or "—" }}
pairing{{ run_info.pairing or "—" }}
mark redundant{{ "yes" if run_info.mark_redundant else "no" }}
run interactions{{ run_info.interactions | join(", ") or "—" }}
select expressions{{ run_info.select | join(" · ") or "—" }}
topology{{ run_info.topology or "—" }}
trajectory{{ run_info.trajectory or "—" }}
output{{ run_info.output or "—" }}
cwd{{ run_info.cwd or "—" }}
{% set topology_input = run_info.inputs.topology %} {% set trajectory_input = run_info.inputs.trajectory %} {% set topology_recorded = "not recorded" if topology_input.size_kb is none and topology_input.mtime is none else ((topology_input.size_kb ~ " KB") if topology_input.size_kb is not none else "—") ~ " · " ~ (topology_input.mtime if topology_input.mtime is not none else "—") %} {% set trajectory_recorded = "not recorded" if trajectory_input.size_kb is none and trajectory_input.mtime is none else ((trajectory_input.size_kb ~ " KB") if trajectory_input.size_kb is not none else "—") ~ " · " ~ (trajectory_input.mtime if trajectory_input.mtime is not none else "—") %}
topology recorded{{ topology_recorded }}
trajectory recorded{{ trajectory_recorded }}
equivalent command
{{ run_info.command or "—" }}
{% else %}

run metadata not recorded (legacy h5)

{% endif %}
pairs × frames — hover a cell for its metrics, click a row to drill down
click a column header to inspect that frame · click a cell to open the pair at that frame
{% if has_pt %}
pistacking type {% for t in legend_types %}{{ t }}{% endfor %}
{% endif %}

frame / {{ n_frames - 1 if n_frames else 0 }}

loading…

aggregates · {{ table.total }} pairs

showing {{ rows_offset + table.rows | length }} of {{ table.total }}
{% if table.rows %}
{% for col in table.columns %}{% set base = col[4:] if (col.startswith("avg_") or col.startswith("std_")) else "" %}{% endfor %} {% for row in table.rows %} {% set cells = table.cells[loop.index0] %} {% for col in table.columns %} {% endfor %} {% endfor %}
{{ col }}{% if base and table.units.get(base) %} ({{ table.units[base] }}){% endif %}
{% if col == "pair_label" %}{{ row[col] }} {% else %}{{ cells[loop.index0] }}{% endif %}
{% else %}

no pairs match the current filter

{% endif %} {% set rows_cfg = {"url": "/api/rows/" ~ (type | urlencode), "type": type, "search": search, "min_occupancy": min_occupancy, "sort_by": sort_by, "sort_dir": sort_dir, "total": table.total, "limit": rows_limit, "offset": rows_offset} %}

top residues · this type

{% if hotspots_top %} {% with segments = hotspot_segments %}{% include "_residue_chart.html" %}{% endwith %}
{% for row in hotspots_top %} {% endfor %}
residueoccupancypairspartnersavg dist
{{ row.label }} {{ "%.1f" | format(row.occupancy * 100) }}% {{ row.n_pairs }} {{ row.n_partners }} {{ "%.3f" | format(row.avg_distance) if row.avg_distance is not none else "—" }}
{% else %}

no residues for this type

{% endif %}

active pairs per frame{% if activity | length < n_frames %} · {{ activity | length }} buckets, max per bucket{% endif %}

{% if activity %} {% set act_top = activity | max %}
active pairs
{% for c in activity %}{% endfor %}
frame 0frame {{ n_frames - 1 }}
{% else %}

no frames in this h5

{% endif %}

occupancy distribution · {{ meta.n_pairs }} pairs

{% if meta.n_pairs and n_frames %} {% set occ_top = meta.occupancy.hist | max %}
pairs
{% for c in meta.occupancy.hist %}{% endfor %}
0%50%100%
{% else %}

{{ "no pairs in this h5" if not meta.n_pairs else "no frames in this h5" }}

{% endif %}
{% if stats %}

metric distributions · active frames only

{% for s in stats %} {% endfor %}
metricunitdtypecountminmeanmaxstddistribution
{{ s.name }} {{ s.unit or "—" }} {{ s.dtype }} {{ s.count }} {{ "%.3f" | format(s.min) if s.min is not none else "—" }} {{ "%.3f" | format(s.mean) if s.mean is not none else "—" }} {{ "%.3f" | format(s.max) if s.max is not none else "—" }} {{ "%.3f" | format(s.std) if s.std is not none else "—" }} {% if s.count %} {% set top = s.hist | max %}
{% for c in s.hist %}{% endfor %}
{% if s.edges %}
{{ s.edges[0] }}{{ s.edges[-1] }}
{% endif %} {% else %} no active frames {% endif %}
{% endif %} {% if string_stats %}

string metrics · active frames only

{% for s in string_stats %}
{{ s.name }} · {{ s.count }} values
{% for item in s.top %}{% if s.name == "pistacking_type" %}{% endif %}{{ item.value }} ×{{ item.count }}{% endfor %}
{% endfor %}
{% endif %} {% set matrix_cfg = {"url": "/api/matrix/" ~ (type | urlencode), "type": type, "search": search, "min_occupancy": min_occupancy, "sort_by": sort_by, "sort_dir": sort_dir, "n_frames": n_frames, "frame": frame} %} {% if has_pt %}{% set _ = matrix_cfg.update({"pt_colors": pt_colors}) %}{% endif %} {% endblock %} {% block scripts %}{% endblock %}