{% extends "base.html" %} {% import "_macros.html" as m %} {% import "_nc_tables.html" as nc %} {% import "_sensor_vars.html" as sv %} {% block title %}SBE sensors — {{ cruise }}{% endblock %} {% block masthead_title %}SBE sensors{% endblock %} {% block masthead_type %}sensor inventory & change log{% endblock %} {% block head_extra %} {% endblock %} {% block masthead_meta %}
{% if cruise %}
Cruise
{{ cruise }}
{% endif %}
Source
{{ meta.filename }}
Casts
{{ meta.n_casts }}
Devices
{{ meta.n_devices }}
Configurations
{{ meta.blocks | length }}
{% endblock %} {% block content %} {% if meta.error %}

Could not read {{ meta.filename }}: {{ meta.error }}

{% elif not meta.has_catalog %}

No sensor catalog in {{ meta.filename }}. Rebuild it with ctdcast process config.yaml --stage profiles --force so the compiled profiles carry the sensor catalog and per-profile linkage.

{% else %} {# Section numbers follow the sections actually shown. #} {% set sections = [("s-config", "Sensor configuration")] %} {% if meta.preferred %}{% set sections = sections + [("s-preferred", "Preferred sensors")] %}{% endif %} {% set sections = sections + [("s-inventory", "Sensor inventory")] %} {% if meta.has_channel %}{% set sections = sections + [("s-rewiring", "Rewiring")] %}{% endif %} {% if sensor_vars %}{% set sections = sections + [("s-variables", "Sensor variables")] %}{% endif %} {% macro heading(id) %}{% for sid, title in sections %}{% if sid == id %}

{{ m.heading_text(loop.index, title) }}

{% endif %}{% endfor %}{% endmacro %}
{% for sid, title in sections %}{{ m.heading_text(loop.index, title) }} {% endfor %}
{{ heading("s-config") }}

Which sensor (by serial number) served each role, over which casts. Each row is a run of casts that shared the same set of sensors; a new row marks a hardware change. Serials resolve to model and calibration in the inventory below.

{{ nc.thead(["Casts"] + meta.role_cols | map(attribute="label") | list) }} {% for b in meta.blocks %} {% for r in meta.role_cols %}{% endfor %} {% endfor %}
{{ b.range }}{{ b.cells[r.key] or "—" }}
{% if meta.preferred %} {{ heading("s-preferred") }}

Which line each cast uses where it carries two: the T/C pair (temperature, conductivity and salinity together) and oxygen, as declared by processing.preferred_pair and processing.preferred_oxygen in the cruise config. Serials are the chosen sensors, temperature / conductivity. An undeclared dual T/C cast has no preferred temperature or salinity; an undeclared dual-oxygen cast shows line 1 in the figures. The choice is resolved at stage 3, so a cast compiled from an earlier stage reads not resolved yet.

{% if meta.preferred | selectattr("undeclared") | list %}

Amber row: a cast with two T/C pairs or two oxygen sensors and no preferred choice declared for it in the cruise config.

{% endif %} {{ nc.thead(["Casts", "T/C pair", "T/C serials", "Oxygen", "O₂ serial"]) }} {% for r in meta.preferred %} {% set bg = ' style="background:var(--warn-bg)"' if r.undeclared else "" %} {{ r.pair }} {{ r.oxygen or "—" }} {% endfor %}
{{ r.range }} {{ r.pair_serials or "—" }} {{ r.oxygen_serial or "—" }}
{% endif %} {{ heading("s-inventory") }}

Every distinct physical device used during the cruise, identified by serial number. Slope and Offset are the datcnv correction in the instrument configuration (temperature, conductivity and pressure sensors only). Source: header = named in the file; assumed = inferred from the SensorID; operator = supplied in the cruise config.

{% if meta.any_calibrated %}

Amber row: a calibration was applied — the sensor's Slope ≠ 1 or Offset ≠ 0 (a drift/span correction); the departing value is in bold.

{% endif %} {{ nc.thead(["Type", "Model", "Serial", "Calibration", "Slope", "Offset", "Maker", "Source", "Role(s)"]) }} {% for d in meta.catalog %} {% set bg = ' style="background:var(--warn-bg)"' if (d.slope_nondefault or d.offset_nondefault) else "" %} {{ d.sensor_type }} {{ d.model }} {{ d.maker }} {% endfor %}
{{ d.serial }} {{ d.calibration_date or "—" }} {% if d.slope_nondefault %}{{ d.slope }}{% else %}{{ d.slope or "—" }}{% endif %} {% if d.offset_nondefault %}{{ d.offset }}{% else %}{{ d.offset or "—" }}{% endif %} {{ d.model_source }} {{ d.roles | join(", ") }}
{% if meta.has_channel %} {{ heading("s-rewiring") }}

Casts where a device stayed the same but moved to a different acquisition channel — a re-cabling, not a hardware change.

{% if meta.rewiring %} {{ nc.thead(["Cast", "Role", "Serial", "Moved"]) }} {% for r in meta.rewiring %} {% endfor %}
{{ "%03d"|format(r.cast) }} {{ r.role }} {{ r.serial }} ch{{ r.from_ch }} → ch{{ r.to_ch }}
{% else %}

No rewiring — every device stayed on its original channel.

{% endif %} {% endif %} {% if sensor_vars %} {{ heading("s-variables") }}

The variables in {{ meta.filename }} that the tables above are built from{% if inventory_href %}; the rest of the file is in its netCDF inventory{% endif %}.

{{ sv.explanation() }} {{ sv.tables(sensor_vars) }} {% endif %} {% endif %} {{ js_top_links | safe }} {% endblock %}