diff --git a/notebooks/voila.ipynb b/notebooks/voila.ipynb index 6cb91ad..cfce8dc 100644 --- a/notebooks/voila.ipynb +++ b/notebooks/voila.ipynb @@ -1209,7 +1209,13 @@ "\n", " run_power_level_dbm = float(self.power_level.value)\n", " measured_at_power = float(sarsample_results.measured_peak_wkg)\n", - " pssar_pass = abs(float(sarsample_results.scaling_error) * 100.0) <= 25.0\n", + " _antenna = self.radio_button_grid.filter_options.antenna_type\n", + " _u_mr = 14.3 if (_antenna and str(_antenna.value).upper() == \"VPIFAS\") else 9.4\n", + " _dose_da = float(sarsample_results.dose_to_agreement)\n", + " _pssar_criteria = ((30.0 - _dose_da) ** 2 + _u_mr**2) ** 0.5\n", + " pssar_pass = (\n", + " abs(float(sarsample_results.scaling_error) * 100.0) <= _pssar_criteria\n", + " )\n", " pattern_pass = float(sarsample_results.pass_rate_percent) >= 100.0\n", "\n", " def result_cell(passed: bool) -> str:\n", @@ -1255,7 +1261,7 @@ " %.2f W/kg\n", " %.2f W/kg\n", " %.2f\n", - " ≤ ± 25\n", + " ≤ ± %.1f\n", " \n", " \n", " \n", @@ -1285,6 +1291,7 @@ " _TD,\n", " float(sarsample_results.scaling_error) * 100.0,\n", " _TD,\n", + " _pssar_criteria,\n", " )\n", "\n", " def _on_file_upload_change(self, change: Bunch):\n", diff --git a/tests/test_report.py b/tests/test_report.py index 144b7c1..336247c 100644 --- a/tests/test_report.py +++ b/tests/test_report.py @@ -219,6 +219,7 @@ def test_compile_report_produces_pdf(tmp_path: Path): out_dir.mkdir() _shutil.copy2(DEFAULT_TEMPLATE_DIR / "main.tex", out_dir / "main.tex") + _shutil.copytree(DEFAULT_TEMPLATE_DIR / "figures", out_dir / "figures") pdf = compile_report(out_dir / "main.tex") assert pdf is not None