Persist FFT settings, fix backend naming, parallelise batch DC caching
- FFT backend and pad factor persist across sessions via QSettings
(IniFormat; tests redirect the settings path for hermeticity).
- The default backend was labelled "NumPy FFT" but always dispatched to
scipy.fft — rename the canonical value to "scipy" ("numpy" stays as a
legacy alias) and fix the dialog label.
- cache_file: DC caching fans out over angles via _parallel_map with
per-angle budgets (the DcPrecomputeWorker pattern); FFT caching stays
serial per angle because compute_rf_image now parallelises internally
over blocks. Documented that the v7 FFT cache is natural-resolution
(pad 1) by design.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
+9
-1
@@ -1,8 +1,16 @@
|
||||
"""Shared test setup: repo-root imports and the offscreen Qt platform."""
|
||||
"""Shared test setup: repo-root imports, the offscreen Qt platform, and
|
||||
hermetic QSettings (tests must not read or write the user's real viewer
|
||||
settings)."""
|
||||
|
||||
import os
|
||||
import sys
|
||||
import tempfile
|
||||
from pathlib import Path
|
||||
|
||||
os.environ.setdefault("QT_QPA_PLATFORM", "offscreen")
|
||||
sys.path.insert(0, str(Path(__file__).resolve().parent.parent))
|
||||
|
||||
from PyQt6.QtCore import QSettings # noqa: E402
|
||||
|
||||
QSettings.setPath(QSettings.Format.IniFormat, QSettings.Scope.UserScope,
|
||||
tempfile.mkdtemp(prefix="sras_qsettings_"))
|
||||
|
||||
Reference in New Issue
Block a user