fix: update Plotly.js CDN to 3.3.1 (match Python lib 6.5.2 bdata format), show 50 modes

This commit is contained in:
2026-01-29 20:32:55 +00:00
parent c6427f3c6e
commit faab234d05

View File

@@ -389,7 +389,7 @@ def make_surface_plot(X, Y, W_res, mask, inner_radius=None, title="", amp=0.5, d
return fig.to_html(include_plotlyjs=False, full_html=False, div_id=f"surface_{title.replace(' ','_')}")
def make_bar_chart(coeffs, title="Zernike Coefficients", max_modes=30):
def make_bar_chart(coeffs, title="Zernike Coefficients", max_modes=50):
"""Create horizontal bar chart of Zernike coefficient magnitudes."""
n = min(len(coeffs), max_modes)
labels = [str(zernike_label(j))[:40] for j in range(1, n+1)]
@@ -890,7 +890,7 @@ def generate_report(
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>{title}</title>
<script src="https://cdn.plot.ly/plotly-2.27.0.min.js"></script>
<script src="https://cdn.plot.ly/plotly-3.3.1.min.js"></script>
<style>
:root {{
--bg-primary: #ffffff;