diff --git a/tools/generate_optical_report.py b/tools/generate_optical_report.py index 0727d5c5..5aa8c43a 100644 --- a/tools/generate_optical_report.py +++ b/tools/generate_optical_report.py @@ -415,7 +415,7 @@ def make_psd_plot(psd_data_dict, title="Power Spectral Density"): return fig.to_html(include_plotlyjs=False, full_html=False, div_id="psd_plot") -def _psd_summary_html(band_dict): +def _psd_summary_html(band_dict, label=""): """Generate an HTML summary card for PSD band RMS values.""" m = band_dict total = m['total_rms'] @@ -425,7 +425,7 @@ def _psd_summary_html(band_dict): return f"""
-

PSD Band Decomposition (Tony Hull Methodology)

+

{'PSD Band Decomposition — ' + label if label else 'PSD Band Decomposition (Tony Hull Methodology)'}

Gravity Signature
@@ -979,9 +979,9 @@ def generate_report( print(f" [WARN] PSD for {ang_label} failed: {e}") psd_plot_html = make_psd_plot(psd_plot_data) if psd_plot_data else "" - psd_summary_40 = _psd_summary_html(psd_bands['40° vs 20°']) if '40° vs 20°' in psd_bands else "" - psd_summary_60 = _psd_summary_html(psd_bands['60° vs 20°']) if '60° vs 20°' in psd_bands else "" - psd_summary_90 = _psd_summary_html(psd_bands['90° (Abs)']) if '90° (Abs)' in psd_bands else "" + psd_summary_40 = _psd_summary_html(psd_bands['40° vs 20°'], '40° vs 20° (Relative)') if '40° vs 20°' in psd_bands else "" + psd_summary_60 = _psd_summary_html(psd_bands['60° vs 20°'], '60° vs 20° (Relative)') if '60° vs 20°' in psd_bands else "" + psd_summary_90 = _psd_summary_html(psd_bands['90° (Abs)'], '90° Manufacturing (Absolute)') if '90° (Abs)' in psd_bands else "" # Per-angle RMS plot angle_rms_data = {}