spectro-kernel 0.8.1__tar.gz → 0.9.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/CHANGELOG.md +254 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/PKG-INFO +1 -1
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/usage/library.md +29 -0
- spectro_kernel-0.9.1/examples/longslit_selfcalibrated.py +59 -0
- spectro_kernel-0.9.1/src/spectro_kernel/algorithms/_robust.py +29 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/activity/activity_index_caii_hk.py +3 -2
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/advanced/doppler_tomogram.py +25 -17
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/catalogs/gaia.py +38 -13
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/catalogs/simbad.py +3 -3
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/catalogs/vizier.py +11 -3
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/classification/classify_template_chi2.py +12 -6
- spectro_kernel-0.9.1/src/spectro_kernel/algorithms/continuum/normalize_region.py +210 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/continuum/normalize_spline.py +3 -2
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/atmospheric_extinction.py +3 -3
- spectro_kernel-0.9.1/src/spectro_kernel/algorithms/corrections/convert_flux_to_rayleigh.py +219 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/doppler_shift.py +2 -2
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/fit_telluric_scaling.py +3 -2
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/embedding/embed_band_power.py +2 -2
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/embedding/embed_pretrained.py +15 -13
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/embedding/embed_remote.py +3 -2
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/embedding/embed_wavelets.py +7 -4
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/exports/export_fits_bess.py +4 -4
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/exports/export_hdf5.py +2 -2
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/extraction/boxcar.py +100 -4
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/extraction/detect_trace.py +6 -5
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/extraction/easyspec_extract.py +10 -5
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/extraction/optimal.py +7 -7
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/io/read_echelle.py +70 -16
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/io/read_sdss.py +4 -3
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/kinematics/vsini_fourier.py +2 -2
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/lines/_line_flux.py +2 -1
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/lines/compare_line_fits.py +4 -4
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/lines/detect.py +64 -34
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/lines/vr_ratio.py +5 -3
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/nebular/bpt_line_ratios.py +18 -16
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/nebular/sii_electron_density.py +3 -3
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/quality/compare_snr_methods.py +2 -2
- spectro_kernel-0.9.1/src/spectro_kernel/algorithms/quality/measure_line_offsets.py +132 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/quality/snr_der.py +2 -1
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/bias_combine.py +3 -2
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/clip_cosmic_rays.py +5 -3
- spectro_kernel-0.9.1/src/spectro_kernel/algorithms/reduction/correct_smile_xcorr.py +370 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/denoise_2d.py +5 -5
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/easyspec_cosmic_ray.py +6 -5
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/easyspec_flat.py +3 -3
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/extract_spectrum_sum.py +3 -3
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/flat_combine.py +5 -5
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/flat_normalize.py +5 -5
- spectro_kernel-0.9.1/src/spectro_kernel/algorithms/reduction/flat_normalize_response.py +271 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/geometry.py +21 -17
- spectro_kernel-0.9.1/src/spectro_kernel/algorithms/reduction/subtract_bias.py +325 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/subtract_sky_2d.py +2 -2
- spectro_kernel-0.9.1/src/spectro_kernel/algorithms/reduction/wavelength_calibrate.py +230 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/rv/precision_bouchy.py +22 -8
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/stacking/merge_echelle_orders.py +6 -4
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/stacking/stack.py +2 -1
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/timeseries/box_least_squares.py +2 -1
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/timeseries/lomb_scargle.py +13 -12
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/timeseries/phase_fold.py +1 -1
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/timeseries/temporal_variance_spectrum.py +2 -1
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/transforms/combine_arithmetic.py +4 -3
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/transforms/resample.py +30 -5
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/viz/plot_dynamic_spectrum.py +5 -8
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/viz/plot_plotly.py +6 -5
- spectro_kernel-0.9.1/src/spectro_kernel/algorithms/wavelength_calibration/_line_fit.py +76 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/wavelength_calibration/arc_geometry.py +31 -32
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/wavelength_calibration/easyspec_wavelength.py +8 -4
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/wavelength_calibration/in_situ.py +22 -19
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/wavelength_calibration/lamp_atlas.py +140 -39
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/wavelength_calibration/match_lamp.py +37 -27
- spectro_kernel-0.9.1/src/spectro_kernel/algorithms/wavelength_calibration/refine_zeropoint.py +169 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/wavelength_calibration/reidentify.py +6 -12
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/wavelength_calibration/solar.py +30 -26
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/registry.py +12 -14
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/version.py +1 -1
- spectro_kernel-0.9.1/tests/unit/test_audit_behaviour_fixes.py +120 -0
- spectro_kernel-0.9.1/tests/unit/test_calibration_flag_chain.py +47 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_catalog_queries_mocked.py +32 -15
- spectro_kernel-0.9.1/tests/unit/test_convert_flux_to_rayleigh.py +134 -0
- spectro_kernel-0.9.1/tests/unit/test_correct_smile_xcorr.py +162 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_examples_run.py +1 -0
- spectro_kernel-0.9.1/tests/unit/test_extract_boxcar_fixed.py +141 -0
- spectro_kernel-0.9.1/tests/unit/test_flat_normalize_response.py +147 -0
- spectro_kernel-0.9.1/tests/unit/test_measure_line_offsets.py +86 -0
- spectro_kernel-0.9.1/tests/unit/test_normalize_to_region_guard.py +114 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_presets.py +4 -2
- spectro_kernel-0.9.1/tests/unit/test_refine_wavelength_zeropoint.py +142 -0
- spectro_kernel-0.9.1/tests/unit/test_resample_oversampling.py +60 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_rv_precision_bouchy.py +32 -10
- spectro_kernel-0.9.1/tests/unit/test_source_path_layouts.py +42 -0
- spectro_kernel-0.9.1/tests/unit/test_subtract_bias_margin.py +176 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_uncertainty_propagation.py +3 -2
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_viz.py +2 -1
- spectro_kernel-0.9.1/tests/unit/test_wavelength_calibrate_apply.py +140 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tools/docs/netlify.toml +5 -3
- spectro_kernel-0.8.1/src/spectro_kernel/algorithms/continuum/normalize_region.py +0 -112
- spectro_kernel-0.8.1/src/spectro_kernel/algorithms/reduction/subtract_bias.py +0 -122
- spectro_kernel-0.8.1/src/spectro_kernel/algorithms/reduction/wavelength_calibrate.py +0 -106
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/.gitignore +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/AGENTS.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/LICENSE +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/README.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/.drafts/README.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/.drafts/notebooks/aurora-line-monitor.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/concepts/algorithms.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/concepts/architecture.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/concepts/data-types.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/concepts/pipelines.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/contributing.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/cookbook/multi-star-viewer.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/cookbook/web-playground.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/getting-started.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_ew_timeseries.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_halpha_phase_stack.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_halpha_timeseries.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_overlay.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_pc1_vs_phase.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_pca_2d.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_pca_3d.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_periodogram.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_phase_folded.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_rv_timeseries.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_similarity.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_cyg_similarity_date.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_dra_halpha_phase_stack.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_dra_pc1_vs_phase.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_dra_pca_2d.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_dra_pca_3d.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_dra_periodogram.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_dra_phase_folded.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_dra_rv_timeseries.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_dra_similarity_date.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/images/notebooks/alpha_dra_similarity_phase.png +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/index.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/notebooks/alpha-cyg-time-series.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/notebooks/alpha-dra-binary-period.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/notebooks/be-star-variability.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/notebooks/claude-mcp-end-to-end.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/notebooks/exoplanet-transit-rv.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/notebooks/full-reduction-walkthrough.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/notebooks/native-vs-easyspec-showdown.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/notebooks/your-first-sb2.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/recipes/format.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/recipes/index.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/recipes/share.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/reference/python.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/tutorials/add-an-algorithm.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/tutorials/analyse-a-spectrum.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/tutorials/discover-the-catalogue.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/tutorials/first-spectrum.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/tutorials/long-slit-reduction.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/usage/cli.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/usage/mcp.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/validation/.nav.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/validation/index.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/docs/why.md +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/examples/mcp_client.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/examples/quickstart.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/examples/recipe_with_profile.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/examples/wavelength_calibration.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/pyproject.toml +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/adapters/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/adapters/easyspec.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/_common.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/activity/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/activity/_bands.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/activity/activity_index_halpha.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/activity/ccf_bisector.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/advanced/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/advanced/aperture_photometry.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/advanced/disentangle_sb2.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/catalogs/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/catalogs/standard_star.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/classification/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/classification/pickles_atlas.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/continuum/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/continuum/compare_normalisations.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/continuum/normalize_edges.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/continuum/normalize_max.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/continuum/normalize_percentile.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/continuum/normalize_polynomial.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/continuum/subtract_continuum.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/air_vacuum.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/barycentric.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/deredden_interstellar.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/extinction_correct_easyspec.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/flux_calibrate_easyspec.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/remove_telluric.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/response_from_standard.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/corrections/synth_telluric.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/embedding/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/embedding/embed_continuum_subtracted.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/embedding/embed_lick_indices.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/embedding/embed_log_lambda.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/embedding/embed_spectrum.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/exports/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/exports/_bess_contract.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/exports/export_csv.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/exports/export_fits.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/exports/export_votable.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/extraction/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/extraction/_aperture.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/extraction/sky_lateral_bands.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/io/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/io/read_ascii.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/io/read_fits.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/io/read_votable.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/kinematics/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/kinematics/rotation_curve.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/lines/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/lines/_profiles.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/lines/catalogs.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/lines/equivalent_width.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/lines/fit_gaussian.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/lines/fit_lorentzian.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/lines/fit_voigt.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/nebular/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/nebular/balmer_decrement_extinction.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/nebular/oiii_electron_temperature.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/quality/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/quality/measure_resolving_power.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/quality/snr_edge.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/quality/snr_linear_fit.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/quality/validate_bess_header.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/_easyspec_apply.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/_easyspec_helpers.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/dark_combine.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/dark_subtract.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/easyspec_bias.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/easyspec_dark.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/easyspec_flat_normalize.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/easyspec_subtract_bias.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/reduction/easyspec_subtract_dark.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/rv/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/rv/cross_correlate.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/rv/fit_keplerian_orbit.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/rv/measure.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/rv/redshift_lines.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/smoothing/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/smoothing/_kernel_uncertainty.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/smoothing/_nan_bridge.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/smoothing/compare_smoothings.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/smoothing/smooth_gaussian.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/smoothing/smooth_savgol.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/stacking/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/timeseries/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/timeseries/_light_curve.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/timeseries/phase_dispersion_minimization.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/transforms/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/transforms/clip_sigma.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/transforms/extract_region.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/transforms/mask_range.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/transforms/resample_flux_conserving.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/viz/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/viz/plot_3d_surface.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/viz/plot_animation.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/wavelength_calibration/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/base.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/cli.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/embeddings.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/errors.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/io/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/io/ascii.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/io/fits.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/io/votable.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/pipeline.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/presets/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/presets/catalog/analysis/balmer_quick.yaml +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/presets/catalog/analysis/embed_quick.yaml +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/presets/catalog/analysis/quality_report.yaml +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/presets/catalog/analysis/rv_quick.yaml +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/presets/catalog/analysis/snr_check.yaml +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/presets/catalog/analysis/time_series_overview.yaml +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/presets/catalog/reduction/full_reduction_easyspec.yaml +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/presets/loader.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/presets/preset.schema.json +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/presets/variables.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/py.typed +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/registry_export.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/types/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/types/catalog.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/types/context.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/types/enums.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/types/history.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/types/image.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/types/line.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/types/spectrum.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/types/timeseries.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/url_safety.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_mcp/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_mcp/__main__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_mcp/auth.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_mcp/auto_tools.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_mcp/observability.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_mcp/py.typed +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_mcp/resources.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_mcp/server.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_mcp/session.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_mcp/url_safety.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/conftest.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/reference/cases.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/reference/conftest.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/reference/test_known_answers.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/reference/test_sun.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/reference/test_validation_cases.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/reference/test_vega.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_activity_bisector.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_activity_caii_hk.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_activity_halpha.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_aperture_photometry.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_barycentric_bjd.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_base.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_classify_template_chi2.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_cli.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_combine.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_combine_arithmetic.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_continuum.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_corrections.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_cross_correlate_extension.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_dark_flat_combine.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_denoise_2d.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_detect_lines_blind.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_detect_trace.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_disentangle_sb2.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_docs_generators.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_doppler_tomogram.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_easyspec_apply_staging.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_easyspec_sessions.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_easyspec_wrappers.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_embedding.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_embedding_pretrained.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_embedding_remote_lick.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_embedding_tier1.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_export_fits_bess.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_export_hdf5.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_extract_boxcar.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_extract_optimal.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_extract_spectrum_sum.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_extraction_centring.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_flux_atmospheric_extinction.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_flux_balmer_decrement.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_flux_calibrate_easyspec.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_flux_deredden_interstellar.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_flux_standard_star_reference.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_geometry_corrections.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_io.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_io_fits_zoo.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_lamp_atlas_match.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_line_profiles.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_lines.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_mask_honoured.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_mcp.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_mcp_http_entry.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_mcp_param_guard.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_mcp_production.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_mcp_resources.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_mcp_security.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_mcp_tools_extra.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_measure_arc_geometry.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_misc_algorithms.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_nebular_diagnostics.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_no_circular_imports.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_normalize_spline.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_normalize_to_region.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_output_produces_contract.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_pipeline.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_quality.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_read_sdss.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_redshift_lines.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_registry.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_reidentify.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_resample_flux_conserving.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_resolving_power.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_response_from_standard.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_rotation_curve.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_sky_lateral_bands.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_smoothing.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_subtract_bias.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_timeseries.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_timeseries_bls.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_timeseries_pdm.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_timeseries_tvs.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_transforms.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_types.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_url_safety_kernel.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_validate_bess_header.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_vr_ratio.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_vsini_fourier.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_wavelength_calibration_in_situ.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tests/unit/test_wavelength_calibration_solar.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tools/docs/__init__.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tools/docs/build.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tools/docs/generate.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tools/docs/generate_catalogue.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tools/docs/generate_cli.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tools/docs/generate_llms.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tools/docs/generate_mcp.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tools/docs/generate_recipes.py +0 -0
- {spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/tools/docs/generate_validation.py +0 -0
|
@@ -6,6 +6,260 @@ Until `1.0.0` the public API may change between minor versions.
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [0.9.1] — 2026-11-09
|
|
10
|
+
|
|
11
|
+
A correction release driven by a reader's report on the public MCP server
|
|
12
|
+
(broken GitHub links, a `backend` field misread, one description that did
|
|
13
|
+
not match its code, one duplicated constant) and by the full audit it
|
|
14
|
+
prompted: every brick's text was compared with its code. Three kinds of
|
|
15
|
+
changes, kept strictly apart :
|
|
16
|
+
|
|
17
|
+
- **Kernel fixes** with no numeric effect on any brick ;
|
|
18
|
+
- **Behaviour corrections** on nine bricks that did not do what their
|
|
19
|
+
description said. None of them is used by a downstream application
|
|
20
|
+
(checked against NORVIS Redux, LineMill, SpecRelay and the BeSS
|
|
21
|
+
projects before the change) ;
|
|
22
|
+
- **Documentation and metadata** on forty bricks, including six used by
|
|
23
|
+
NORVIS Redux and LineMill, where only the text changes.
|
|
24
|
+
|
|
25
|
+
Two findings that *would* change results of bricks NORVIS Redux and
|
|
26
|
+
LineMill run today are deliberately **not** applied and are listed under
|
|
27
|
+
"Known" below for a separate decision.
|
|
28
|
+
|
|
29
|
+
### Fixed — kernel
|
|
30
|
+
|
|
31
|
+
- `get_algorithm_source` (library, `spectro source`, MCP tool) rebuilds the
|
|
32
|
+
repository path from the package directory, so a wheel install reports
|
|
33
|
+
`src/spectro_kernel/algorithms/<category>/<file>.py` and a working GitHub
|
|
34
|
+
link instead of the bare file name. The public server, installed from the
|
|
35
|
+
wheel, returned `snr_der.py` for every brick. Tests cover the editable,
|
|
36
|
+
wheel and unknown layouts.
|
|
37
|
+
- `algorithms/_robust.py` defines `MAD_TO_SIGMA` (1.482602) and
|
|
38
|
+
`DER_SNR_NOISE_FACTOR` (1.482602 / √6, Stoehr et al. 2008) once ; seven
|
|
39
|
+
copies replaced. The three bricks that carried the rounded literal
|
|
40
|
+
`0.6052697` — `match_lamp_lines` 1.0.3, `reidentify_arc_features` 1.0.1,
|
|
41
|
+
`measure_arc_geometry` 2.0.1 — now use the exact value : a 5e-8 relative
|
|
42
|
+
shift of a peak-detection threshold that is never exported ; on every test
|
|
43
|
+
fixture the closest peak candidate sits 1.8 % from the threshold.
|
|
44
|
+
- The documented chain *extract → calibrate → `refine_wavelength_zeropoint`
|
|
45
|
+
/ `measure_line_offsets`* failed after a fitted calibration, because only
|
|
46
|
+
the coefficient mode of `wavelength_calibrate_polynomial` cleared the
|
|
47
|
+
extractor's `needs_wavelength_calibration` flag (0.9.0 regression).
|
|
48
|
+
`wavelength_calibrate_polynomial` 1.1.1 (fit mode),
|
|
49
|
+
`wavelength_calibration_solar` 2.0.1 and `wavelength_calibrate_easyspec`
|
|
50
|
+
1.0.2 now set `wavelength_calibrated = True` and
|
|
51
|
+
`needs_wavelength_calibration = False` ; the axes are unchanged.
|
|
52
|
+
- The documentation site builds on every push (the Netlify `ignore` script
|
|
53
|
+
had skipped the 0.9.0 deploy).
|
|
54
|
+
|
|
55
|
+
### Changed — behaviour aligned on the description (bricks used by no application)
|
|
56
|
+
|
|
57
|
+
- `gaia_query` 1.1.0 — `data_release` accepts the release aliases the
|
|
58
|
+
description promised (`DR3`, `EDR3`, `DR2`, case-insensitive) or a full
|
|
59
|
+
table name ; anything else is refused instead of being pasted into the
|
|
60
|
+
ADQL `FROM`, where `'DR3'` made the query fail.
|
|
61
|
+
- `vizier_query` 2.0.0 — cone search of `radius_arcsec` around the resolved
|
|
62
|
+
object (`Vizier.query_region`) ; 1.x called `query_object` and ignored the
|
|
63
|
+
radius it documented.
|
|
64
|
+
- `rv_precision_bouchy` 3.0.0 — without an uncertainty array the photon
|
|
65
|
+
noise σ_F ∝ √|F| is scaled to the spectrum's own DER_SNR noise, as the
|
|
66
|
+
description always said ; `snr_floor` is only the fallback when that
|
|
67
|
+
estimate is unavailable (2.x always used `snr_floor`, so σ_v scaled with
|
|
68
|
+
an assumption, never with the data).
|
|
69
|
+
- `bpt_line_ratios` 3.0.0 — `log_sii_ha` needs both [S II] lines ; 2.x
|
|
70
|
+
reported (6716 + 6731)/Hα with one member of the doublet.
|
|
71
|
+
- `doppler_tomogram` 3.0.0 — velocities a spectrum does not cover stay NaN
|
|
72
|
+
and are excluded from the back-projection average, as the NaN-aware
|
|
73
|
+
description and the code comment said ; 2.x zeroed them and counted them
|
|
74
|
+
as phases with no excess, diluting the map.
|
|
75
|
+
- `merge_echelle_orders` 2.0.0 — a non-finite flux sample carries no weight ;
|
|
76
|
+
1.x kept its weight in the denominator and pulled the merge toward 0
|
|
77
|
+
under a NaN gap.
|
|
78
|
+
- `read_echelle_fits` 2.0.0 — IRAF multispec `WAT2_*` records are decoded
|
|
79
|
+
(linear and log dispersions, `z` factor) ; a non-linear record
|
|
80
|
+
(Chebyshev / Legendre / spline, not decoded) leaves the order on a
|
|
81
|
+
flagged pixel axis (`meta["wcs"]`) instead of the shared linear WCS,
|
|
82
|
+
which gave a silently wrong axis. 1.x never read `WAT*` although its
|
|
83
|
+
docstring said so.
|
|
84
|
+
- `embed_pretrained` 2.1.0 — `model_path` may be a directory holding
|
|
85
|
+
`model.pt`, as documented.
|
|
86
|
+
- `plot_dynamic_spectrum` 1.1.0 — y labels are `DATE-OBS` or the exposure
|
|
87
|
+
index ; the object-name fallback collapsed every row of a single target
|
|
88
|
+
onto one label.
|
|
89
|
+
|
|
90
|
+
### Documentation and metadata (PATCH bumps, no numeric change)
|
|
91
|
+
|
|
92
|
+
- `measure_arc_geometry` : one joint least-squares fit of every (row, dx)
|
|
93
|
+
sample, no per-row or per-line averaging ; the `smile_order` 4 / 6 terms
|
|
94
|
+
are fitted but only dy² enters R ; implemented here on scipy / numpy
|
|
95
|
+
primitives (the `backend = "scipy"` convention : *implemented on
|
|
96
|
+
numerical primitives*, not *wrapped*).
|
|
97
|
+
- `correct_tilt_affine` / `correct_slant_affine` / module docstring : the two
|
|
98
|
+
physical descriptions were swapped — tilt levels the trace (vertical
|
|
99
|
+
shear), slant straightens the monochromatic lines (horizontal shear) ; the
|
|
100
|
+
shear uses the angle in radians, ≈ tan θ for the small angles involved.
|
|
101
|
+
- `clip_cosmic_rays` : astroscrappy's default clean is a 5×5 masked mean,
|
|
102
|
+
not a local median ; `backend = "astroscrappy"`.
|
|
103
|
+
- `classify_template_chi2` : `top_n` includes the best match ;
|
|
104
|
+
`min_overlap` gates the observed spectrum (templates are dropped below
|
|
105
|
+
100 shared samples) ; `teff_unstable` needs templates with a `T_eff`
|
|
106
|
+
(Pickles route), so it stays False and `best_teff_k` is absent on the
|
|
107
|
+
`atlas_dir` route.
|
|
108
|
+
- `extract_spectrum_easyspec` : `trace_method` is argmax / moments / multi,
|
|
109
|
+
`extraction_weights` gaussian / tophat, `shift_y_pixels` is the sky-window
|
|
110
|
+
offset raised to 3 × `trace_half_width` by easyspec ; the Monte-Carlo
|
|
111
|
+
errors are not kept (no uncertainty on the output).
|
|
112
|
+
- `cosmic_ray_remove_easyspec` : the gain correction is not optional, the
|
|
113
|
+
output is always in electrons.
|
|
114
|
+
- `wavelength_calibration_in_situ` : the uniform grid is built from the two
|
|
115
|
+
linear coefficients only and out-of-axis samples are filled with 0 ;
|
|
116
|
+
`fit_emission_lines_gaussian` writes `extras["emission_line_centroids"]`.
|
|
117
|
+
- `match_lamp_lines` : `wave_min` / `wave_max` declared required (the brick
|
|
118
|
+
already refused their absence ; `spectro preset validate` now catches it) ;
|
|
119
|
+
the hand-off to `wavelength_calibrate_polynomial` goes through its
|
|
120
|
+
parameters, as `examples/wavelength_calibration.py` shows ; peaks are the
|
|
121
|
+
most prominent, noise is DER_SNR ; `lamp_atlas` intensities are
|
|
122
|
+
informative only.
|
|
123
|
+
- `vr_ratio` : the most prominent peak per side, not the highest sample.
|
|
124
|
+
- `detect_trace` : the FWHM helper returns the span of samples above
|
|
125
|
+
half-maximum, no interpolation, no restriction to the centre.
|
|
126
|
+
- `wavelength_calibration_solar` : prominence as a fraction of the range,
|
|
127
|
+
matching in wavelength space.
|
|
128
|
+
- `subtract_sky_2d` `sky_half_width` is the window height ;
|
|
129
|
+
`extract_spectrum_optimal` flanking sky fit is unweighted and its lower
|
|
130
|
+
window starts one row further than `subtract_sky_2d`'s.
|
|
131
|
+
- `simbad_query`, Plotly bricks : they register without the optional
|
|
132
|
+
library and fail at run time with an install hint.
|
|
133
|
+
- `flat_combine`, `flat_normalize`, `flat_combine_easyspec` : point at
|
|
134
|
+
`flat_normalize_response` and `flat_normalize_easyspec`, which exist.
|
|
135
|
+
- `read_sdss_spectrum`, `compare_line_fits` (reports `best_profile`),
|
|
136
|
+
`compare_snr_methods`, `fit_telluric_scaling` (both extras keys),
|
|
137
|
+
`extract_spectrum_sum` (row, not column), `bias_combine` (feeds
|
|
138
|
+
`subtract_bias`), `_line_flux.continuum` (fitted offset),
|
|
139
|
+
`sii_electron_density` (fails / NaN), `export_fits_bess` (sentinel for
|
|
140
|
+
masked pixels only), `embed_band_power` (log10 of |power|),
|
|
141
|
+
`denoise_median_2d` border, `atmospheric_extinction_correct` (geometric
|
|
142
|
+
zenith angle), `activity_index_caii_hk` (`s_index_calibrated` is
|
|
143
|
+
α·S + β), `combine_spectra_arithmetic` (pass-through inside reference
|
|
144
|
+
NaN gaps too), `doppler_tomogram` (untimed spectra skipped, odd
|
|
145
|
+
`n_velocity` optional), `normalize_spline` (knots include the boundary),
|
|
146
|
+
embedding bricks (how to deal with masked samples),
|
|
147
|
+
`wavelength_calibrate_easyspec` (the applied polynomial is
|
|
148
|
+
`numpy.polyfit` on the identifications).
|
|
149
|
+
- Backend labels : `export_hdf5` h5py, `doppler_shift` numpy,
|
|
150
|
+
`vsini_fourier` numpy, `correct_smile_xcorr` scipy.
|
|
151
|
+
|
|
152
|
+
### Known — not changed, for a separate decision (bricks in production)
|
|
153
|
+
|
|
154
|
+
- `wavelength_calibration_in_situ` (NORVIS Redux, LineMill) : the uniform
|
|
155
|
+
grid should span the polynomial over the whole axis and fill with NaN,
|
|
156
|
+
and the brick should clear `needs_wavelength_calibration` like the other
|
|
157
|
+
calibrators (a NORVIS `WAVCAL` header would flip to True).
|
|
158
|
+
- `correct_tilt_affine` / `correct_slant_affine` (NORVIS Redux, LineMill) :
|
|
159
|
+
the shear should be tan θ rather than θ (0.1 % at 3°).
|
|
160
|
+
- `detect_trace` (LineMill) : the FWHM should be interpolated at half-maximum
|
|
161
|
+
around the central row ; a second source in the slit currently widens it
|
|
162
|
+
and the SNR exclusion zone with it.
|
|
163
|
+
- `response_from_standard` (LineMill) : `n_fit_samples` and `response_rms`
|
|
164
|
+
reported from the post-clip mask ; to be checked against the final fit.
|
|
165
|
+
|
|
166
|
+
## [0.9.0] — 2026-10-23
|
|
167
|
+
|
|
168
|
+
Bricks for self-calibrating long-slit instruments, requested by NORVIS Redux,
|
|
169
|
+
which reduces auroral long-slit spectra with ten local bricks that implement
|
|
170
|
+
generic, published methods. Five new bricks and five extensions ; every
|
|
171
|
+
extension keeps its default behaviour **byte-identical to 0.8.1, metrics
|
|
172
|
+
included** (MINOR attribute bumps, no MAJOR). Each brick was checked bit for
|
|
173
|
+
bit against the Redux reference implementation on a synthetic harness covering
|
|
174
|
+
the apply, skip and failure branches (report in the pull request). No NORVIS
|
|
175
|
+
constant became a default : which lines, which header keyword, which geometry
|
|
176
|
+
are required parameters.
|
|
177
|
+
|
|
178
|
+
### Added
|
|
179
|
+
|
|
180
|
+
- **`refine_wavelength_zeropoint`** (wavelength_calibration, 1.0.0, scipy) — a
|
|
181
|
+
guarded pure zero-point shift of a calibrated axis from one emission line of
|
|
182
|
+
the spectrum itself (Osterbrock, Fulbright, Martel, Keane, Trager & Basri
|
|
183
|
+
1996, PASP 108, 277 ; Osterbrock, Fulbright & Bida 1997, PASP 109, 614 :
|
|
184
|
+
night-sky lines as wavelength standards). Gaussian on a linear baseline
|
|
185
|
+
inside `reference_wavelength ± search_halfwidth_angstrom`, Δλ = λ_ref − λ_fit
|
|
186
|
+
added to the whole axis, dispersion untouched. Skips (`applied = 0`, measured
|
|
187
|
+
centre, shift and S/N reported) on a faint line (`min_snr`), a centre outside
|
|
188
|
+
the window or a shift beyond `max_shift_angstrom` ; fails on a pixel axis.
|
|
189
|
+
`reference_wavelength` is required.
|
|
190
|
+
- **`measure_line_offsets`** (quality, 1.0.0, scipy) — where known lines land on
|
|
191
|
+
a calibrated axis, measured and never applied : per line
|
|
192
|
+
`line_<λ>_detected`, `line_<λ>_snr`, `line_<λ>_offset_angstrom`, plus
|
|
193
|
+
`n_lines_detected` and `mean_offset_angstrom`. Same fit helper as the
|
|
194
|
+
zero-point brick (`wavelength_calibration/_line_fit.py`).
|
|
195
|
+
`reference_wavelengths` is required.
|
|
196
|
+
- **`flat_normalize_response`** (preprocessing, 1.0.0, scipy) — the IRAF
|
|
197
|
+
`response` recipe (Massey, Valdes & Barnes 1992 ; Howell 2006 ch. 4) : the
|
|
198
|
+
flat over its own smoothed lamp spectrum, scaled to median 1 over the lit
|
|
199
|
+
area, applied only where the lamp gave signal and the response lies within
|
|
200
|
+
`[min_response, max_response]`. `pedestal_mode = "dark_margin"` holds the
|
|
201
|
+
science pedestal out of the division, `(image − p) / N + p`. Metrics : lit
|
|
202
|
+
span, lit rows, corrected fraction, pixel-response scatter, illumination
|
|
203
|
+
percentiles. Fills the gap the `flat_normalize` docstring declared.
|
|
204
|
+
- **`correct_smile_xcorr`** (preprocessing, 1.0.0, astropy) — line curvature
|
|
205
|
+
measured on the frame itself (Kelson 2003, PASP 115, 688 ; Massey, Valdes &
|
|
206
|
+
Barnes 1992 ; Tonry & Davis 1979) : row bands cross-correlated against the
|
|
207
|
+
band at `reference_row` with parabolic sub-pixel refinement, shift(row)
|
|
208
|
+
fitted with an astropy `Polynomial1D` under two 3σ clipping passes,
|
|
209
|
+
re-anchored so the reference row is untouched and held constant outside the
|
|
210
|
+
fitted rows, every row resampled. Skips on a narrow lit span, a reference row
|
|
211
|
+
outside the lit rows, fewer than `min_bands` bands, a fit rms above
|
|
212
|
+
`max_fit_rms_px` or an amplitude above `max_amplitude_px`. Fit written to
|
|
213
|
+
`ctx.extras[output_key]`.
|
|
214
|
+
- **`convert_flux_to_rayleigh`** (flux_calibration, 1.0.0, numpy) — a
|
|
215
|
+
response-corrected slit spectrum to rayleigh per nm (Hunten, Roach &
|
|
216
|
+
Chamberlain 1956, J. Atmos. Terr. Phys. 8, 345 ; Baker 1974, Appl. Opt. 13,
|
|
217
|
+
2160 ; Baker & Romick 1976, Appl. Opt. 15, 1966) through the solid angle
|
|
218
|
+
Ω = (w / f) · (N · p / (m · f)) and the absolute response scale read from the
|
|
219
|
+
response header under `response_scale_keyword` (required : the keyword is a
|
|
220
|
+
convention of whoever built the response). A `normalize_to_region` step is
|
|
221
|
+
undone. Missing scale or exposure time goes to `on_missing`.
|
|
222
|
+
- `examples/longslit_selfcalibrated.py` — the ten bricks chained on a synthetic
|
|
223
|
+
frame, run by CI ; a section on self-calibrating long-slit instruments in the
|
|
224
|
+
library usage page.
|
|
225
|
+
|
|
226
|
+
### Changed — extensions, defaults byte-identical to 0.8.1
|
|
227
|
+
|
|
228
|
+
- `extract_spectrum_boxcar` 3.0.0 → 3.1.0 : `trace_method = "fixed"` extracts
|
|
229
|
+
the window `trace_center_row ± trace_half_width` on every column without
|
|
230
|
+
tracing (IRAF `apall` without `aptrace`), for extended sources that fill the
|
|
231
|
+
slit ; no easyspec or matplotlib import in that mode. Meta `trace_method` /
|
|
232
|
+
`trace_center_row` and metric `trace_center_row` in fixed mode only.
|
|
233
|
+
- `wavelength_calibrate_polynomial` 1.0.1 → 1.1.0 : apply mode. `coefficients`
|
|
234
|
+
(`coefficients_order` lowest_first by default, or highest_first) and
|
|
235
|
+
`pixel_offset` evaluate a known dispersion solution instead of fitting one
|
|
236
|
+
(Massey & Hanson 2013, DOI 10.1007/978-94-007-5618-2_2) ; fails on a
|
|
237
|
+
non-increasing axis ; `required_params` is now empty, the pixel/wavelength
|
|
238
|
+
pairs are checked in `run()` when no coefficients are given. Metrics
|
|
239
|
+
`applied`, `wavelength_min_angstrom`, `wavelength_max_angstrom`,
|
|
240
|
+
`dispersion_angstrom_per_px` ; meta `wavelength_calibration = {method:
|
|
241
|
+
polynomial_coefficients, …}`.
|
|
242
|
+
- `resample_linear` 2.0.0 → 2.1.0 : `oversampling`, the grid holds
|
|
243
|
+
`round((npix − 1) · oversampling) + 1` samples over the same bounds ;
|
|
244
|
+
exclusive with `step` and `n_points`.
|
|
245
|
+
- `normalize_to_region` 3.0.0 → 3.1.0 : `window_selection` (`"nearest"`,
|
|
246
|
+
the default, or `"within"`) and a significance guard (`min_snr`,
|
|
247
|
+
`on_invalid`) on the standard error of the mean (Bevington & Robinson 2003) :
|
|
248
|
+
a negative mean, or one below `min_snr` standard errors, fails or skips
|
|
249
|
+
instead of inverting the spectrum or scaling it by noise.
|
|
250
|
+
- `subtract_bias` 1.0.0 → 1.1.0 : the pedestal from an explicit
|
|
251
|
+
`overscan_columns` range or, with `overscan_auto`, from the columns the
|
|
252
|
+
spectrum never reaches (public `unilluminated_columns` : trimmed-mean column
|
|
253
|
+
profile, noise-based threshold, contiguous lit span widened by
|
|
254
|
+
`guard_columns`). Estimator : astropy sigma-clipped mean, which resolves the
|
|
255
|
+
level of a coarsely quantised integer frame below its step where a median
|
|
256
|
+
cannot ; residual reported. `min_columns` and `max_level_adu` go to
|
|
257
|
+
`on_invalid`. Precedence : `bias_level` > `overscan_columns` >
|
|
258
|
+
`overscan_auto` > master frame.
|
|
259
|
+
- `tests/unit/test_uncertainty_propagation.py` pins the major version of
|
|
260
|
+
`resample_linear` instead of `2.0.0`, since the propagation rule of 2.0.0 is
|
|
261
|
+
kept by 2.1.0.
|
|
262
|
+
|
|
9
263
|
## [0.8.1] — 2026-09-26
|
|
10
264
|
|
|
11
265
|
One native brick, the last of the September audit's "trivial and already requested"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: spectro-kernel
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.9.1
|
|
4
4
|
Summary: A shared catalogue of astronomical spectroscopy algorithms, composable into reproducible pipelines, usable as a Python library, a CLI, or an MCP server.
|
|
5
5
|
Project-URL: Homepage, https://github.com/matthieulel/spectro-kernel
|
|
6
6
|
Project-URL: Documentation, https://docs.spectrokernel.io/
|
|
@@ -146,3 +146,32 @@ class MyMetric(BaseAlgorithm):
|
|
|
146
146
|
Once the module is imported, `run_algorithm("my_metric", ctx)` works - and so does the
|
|
147
147
|
CLI and the MCP server. The full walkthrough is in
|
|
148
148
|
[Tutorial: add an algorithm](../tutorials/add-an-algorithm.md).
|
|
149
|
+
|
|
150
|
+
## Self-calibrating long-slit instruments
|
|
151
|
+
|
|
152
|
+
Some slit spectrographs calibrate themselves: no arc lamp, no bias frames, a
|
|
153
|
+
dispersion solution stored in every frame. The catalogue covers that chain
|
|
154
|
+
without a single instrument-specific brick:
|
|
155
|
+
|
|
156
|
+
- `subtract_bias` with `overscan_auto` measures the pedestal on the columns the
|
|
157
|
+
spectrum never reaches (a sigma-clipped mean, which resolves a coarsely
|
|
158
|
+
quantised integer frame below its step);
|
|
159
|
+
- `flat_normalize_response` divides by a flat normalised along the dispersion,
|
|
160
|
+
the IRAF `response` recipe, so the lamp spectrum is not imprinted;
|
|
161
|
+
- `correct_smile_xcorr` measures the line curvature on the frame itself and
|
|
162
|
+
straightens it, anchored on the extraction row;
|
|
163
|
+
- `extract_spectrum_boxcar` with `trace_method="fixed"` sums a fixed band of
|
|
164
|
+
rows, the right aperture for a source that fills the slit;
|
|
165
|
+
- `wavelength_calibrate_polynomial` with `coefficients` applies the stored
|
|
166
|
+
dispersion polynomial, `resample_linear` with `oversampling` puts it on a
|
|
167
|
+
uniform grid, `refine_wavelength_zeropoint` takes the night's zero-point
|
|
168
|
+
drift out on a sky line and `measure_line_offsets` reports where the other
|
|
169
|
+
lines land without moving anything;
|
|
170
|
+
- `normalize_to_region` with its significance guard, then
|
|
171
|
+
`convert_flux_to_rayleigh` for an absolute radiance in R/nm when the
|
|
172
|
+
response carries an absolute scale.
|
|
173
|
+
|
|
174
|
+
Every one of these bricks skips rather than guesses when its input is doubtful
|
|
175
|
+
(`applied = 0` in the metrics, context untouched). The chain runs end to end
|
|
176
|
+
in [`examples/longslit_selfcalibrated.py`](https://github.com/matthieulel/spectro-kernel/blob/main/examples/longslit_selfcalibrated.py)
|
|
177
|
+
on a synthetic frame.
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"""Self-calibrating long-slit reduction: a synthetic sky frame to rayleigh per nm, no arc lamp.
|
|
2
|
+
|
|
3
|
+
Run with ``python examples/longslit_selfcalibrated.py``: margin pedestal, response flat, smile
|
|
4
|
+
measured on the frame, stored dispersion polynomial refined on [O I] 5577, R/nm. Deterministic.
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
import numpy as np
|
|
8
|
+
|
|
9
|
+
from spectro_kernel import WorkContext, run_algorithm
|
|
10
|
+
from spectro_kernel.types import ImageFrame, Spectrum1D
|
|
11
|
+
|
|
12
|
+
ROWS, COLS, PED, REF = 240, 600, 300.0, 120
|
|
13
|
+
COEF = [5000.0, 2.5, -1.0e-4] # stored solution lambda(column), lowest degree first
|
|
14
|
+
LINES = (5577.34, 6300.30) # [O I] night-sky lines (air)
|
|
15
|
+
GEOM = {"slit_width_um": 20.0, "focal_mm": 50.0, "pixel_um": 2.9, "aperture_rows": 121}
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
def synthetic(rng: np.random.Generator) -> tuple[ImageFrame, ImageFrame]:
|
|
19
|
+
cols, rows = np.arange(COLS, dtype=float), np.arange(ROWS, dtype=float)[:, None]
|
|
20
|
+
wave = np.polynomial.polynomial.polyval(cols, COEF) - 1.0 # 1 A zero-point drift
|
|
21
|
+
smile = 6.0 * ((rows - REF) / 100.0) ** 2 # line curvature, in columns
|
|
22
|
+
lit, slit = (cols >= 80) & (cols < 520), (rows >= 30) & (rows < 210)
|
|
23
|
+
centres = [np.interp(w, wave, cols) + smile for w in LINES]
|
|
24
|
+
sky = 30.0 * lit + sum(800.0 * np.exp(-0.5 * ((cols - c) / 2.0) ** 2) for c in centres)
|
|
25
|
+
lamp = 2000.0 * (1 + 0.4 * (cols - 80) / 440) * lit
|
|
26
|
+
pattern = 1.0 + 0.02 * rng.uniform(-1, 1, (ROWS, COLS))
|
|
27
|
+
noise = rng.normal(0, 2.0, (2, ROWS, COLS))
|
|
28
|
+
science = ImageFrame(pattern * slit * sky + PED + noise[0], header={"EXPTIME": 30.0})
|
|
29
|
+
return science, ImageFrame(pattern * slit * lamp + PED + noise[1], frame_type="flat")
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
def main() -> None:
|
|
33
|
+
science, flat = synthetic(np.random.default_rng(0))
|
|
34
|
+
ctx = WorkContext(image=science, extras={"master_flat": flat})
|
|
35
|
+
ctx.extras["reference_spectrum"] = Spectrum1D(
|
|
36
|
+
[5000.0, 7000.0], [1, 1], header={"RESPABS": 2.5e8}
|
|
37
|
+
)
|
|
38
|
+
bias = run_algorithm("subtract_bias", ctx, {"overscan_auto": True})
|
|
39
|
+
print(f"subtract_bias: pedestal {bias.metrics['bias_median']:.1f} ADU from the unlit margin")
|
|
40
|
+
run_algorithm("flat_normalize_response", ctx, {"pedestal_mode": "dark_margin"})
|
|
41
|
+
run_algorithm("correct_smile_xcorr", ctx, {"reference_row": REF})
|
|
42
|
+
boxcar = {"trace_method": "fixed", "trace_center_row": REF, "trace_half_width": 60}
|
|
43
|
+
run_algorithm("extract_spectrum_boxcar", ctx, boxcar)
|
|
44
|
+
run_algorithm("wavelength_calibrate_polynomial", ctx, {"coefficients": COEF})
|
|
45
|
+
run_algorithm("resample_linear", ctx, {"oversampling": 2.0})
|
|
46
|
+
zp = run_algorithm("refine_wavelength_zeropoint", ctx, {"reference_wavelength": LINES[0]})
|
|
47
|
+
off = run_algorithm("measure_line_offsets", ctx, {"reference_wavelengths": list(LINES)})
|
|
48
|
+
delta, rest = zp.metrics["delta_angstrom"], off.metrics["line_6300_offset_angstrom"]
|
|
49
|
+
print(f"refine_wavelength_zeropoint: {delta:+.2f} A applied; [O I] 6300 now {rest:+.2f} A off")
|
|
50
|
+
window = {"wave_lo": 5800.0, "wave_hi": 5900.0, "window_selection": "within", "min_snr": 3.0}
|
|
51
|
+
run_algorithm("normalize_to_region", ctx, {**window, "on_invalid": "skip"})
|
|
52
|
+
ray = {**GEOM, "samples_per_pixel": 2.0, "response_scale_keyword": "RESPABS"}
|
|
53
|
+
out = run_algorithm("convert_flux_to_rayleigh", ctx, ray)
|
|
54
|
+
omega, unit = out.metrics["solid_angle_sr"], ctx.spectrum.flux_unit
|
|
55
|
+
print(f"convert_flux_to_rayleigh: solid angle {omega:.3e} sr, spectrum now in {unit}")
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
if __name__ == "__main__":
|
|
59
|
+
main()
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"""Robust noise constants shared by the bricks (one definition, seven former copies).
|
|
2
|
+
|
|
3
|
+
``MAD_TO_SIGMA`` converts a median absolute deviation to a Gaussian σ
|
|
4
|
+
(1 / Φ⁻¹(3/4) ≈ 1.4826). ``DER_SNR_NOISE_FACTOR`` is the DER_SNR noise scale
|
|
5
|
+
of Stoehr et al. 2008 (ASP Conf. Ser. 394, 505): σ = 1.482602 / √6 ·
|
|
6
|
+
median(|2 F[i] − F[i−2] − F[i+2]|).
|
|
7
|
+
"""
|
|
8
|
+
|
|
9
|
+
from __future__ import annotations
|
|
10
|
+
|
|
11
|
+
import math
|
|
12
|
+
|
|
13
|
+
import numpy as np
|
|
14
|
+
|
|
15
|
+
MAD_TO_SIGMA = 1.482602
|
|
16
|
+
DER_SNR_NOISE_FACTOR = MAD_TO_SIGMA / math.sqrt(6.0)
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
def der_snr_noise(flux: np.ndarray) -> float:
|
|
20
|
+
"""DER_SNR noise estimate of a 1-D flux array (NaN-aware, 0.0 below 5 samples)."""
|
|
21
|
+
flux = np.asarray(flux, dtype=np.float64)
|
|
22
|
+
if flux.size < 5:
|
|
23
|
+
return 0.0
|
|
24
|
+
diff = np.abs(2.0 * flux[2:-2] - flux[:-4] - flux[4:])
|
|
25
|
+
diff = diff[np.isfinite(diff)]
|
|
26
|
+
return DER_SNR_NOISE_FACTOR * float(np.median(diff)) if diff.size else 0.0
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
__all__ = ["DER_SNR_NOISE_FACTOR", "MAD_TO_SIGMA", "der_snr_noise"]
|
|
@@ -116,7 +116,7 @@ def log_rhk_noyes(s_mw: float, b_v: float) -> float | None:
|
|
|
116
116
|
category=AlgorithmCategory.ACTIVITY,
|
|
117
117
|
# 2.0.0: masked samples (Spectrum1D.mask) are dropped from the passband
|
|
118
118
|
# integrals like non-finite ones.
|
|
119
|
-
version="2.0.
|
|
119
|
+
version="2.0.1",
|
|
120
120
|
)
|
|
121
121
|
class ActivityIndexCaiiHk(BaseAlgorithm):
|
|
122
122
|
"""Mount Wilson S index from the Ca II H & K cores, plus R'_HK when B−V is given.
|
|
@@ -162,7 +162,8 @@ class ActivityIndexCaiiHk(BaseAlgorithm):
|
|
|
162
162
|
"calibrated on 0.44 < B−V < 0.82 : outside that range log_rhk is "
|
|
163
163
|
"still written but flagged in the message. Rejects (no log_rhk) when "
|
|
164
164
|
"R_HK ≤ R_phot. Metrics are prefixed for provenance: "
|
|
165
|
-
"s_index_alpha
|
|
165
|
+
"s_index_alpha echoes the input, s_index_calibrated is the computed "
|
|
166
|
+
"alpha · S + beta. v2.0.0: masked "
|
|
166
167
|
"samples (Spectrum1D.mask) are ignored — dropped from the passband "
|
|
167
168
|
"integrals (and their transmission from the weight sum) like "
|
|
168
169
|
"non-finite ones."
|
|
@@ -32,8 +32,9 @@ that suppresses the streak artefacts of pure back-projection. MEM is
|
|
|
32
32
|
intentionally left out of v1.0.0 to keep the surface tight.
|
|
33
33
|
|
|
34
34
|
Phase computation : ``φ = ((JD_mid − epoch_HJD) / period) mod 1``.
|
|
35
|
-
Each input ``Spectrum1D``
|
|
36
|
-
``spec.meta["jd_mid"]``
|
|
35
|
+
Each input ``Spectrum1D`` should carry its **mid-exposure JD** in
|
|
36
|
+
``spec.meta["jd_mid"]`` (a spectrum with no usable timestamp is skipped
|
|
37
|
+
and counted in the message) ; if absent, the algorithm falls back to
|
|
37
38
|
deriving it from ``spec.meta["dateobs"]`` and ``spec.meta["exptime_s"]``
|
|
38
39
|
(``jd_mid = Time(dateobs).jd + exptime_s / 2 / 86400``), which requires
|
|
39
40
|
``astropy.time`` (imported lazily).
|
|
@@ -85,7 +86,9 @@ def _resolve_jd_mid(spec: Spectrum1D) -> float | None:
|
|
|
85
86
|
|
|
86
87
|
|
|
87
88
|
def _line_excess_on_velocity_grid(
|
|
88
|
-
spec: Spectrum1D,
|
|
89
|
+
spec: Spectrum1D,
|
|
90
|
+
line_centre_aa: float,
|
|
91
|
+
velocity_grid: np.ndarray,
|
|
89
92
|
) -> np.ndarray | None:
|
|
90
93
|
"""Resample the spectrum onto a velocity grid and subtract the continuum.
|
|
91
94
|
|
|
@@ -118,9 +121,9 @@ def _line_excess_on_velocity_grid(
|
|
|
118
121
|
|
|
119
122
|
|
|
120
123
|
def _back_project(
|
|
121
|
-
trailed: np.ndarray,
|
|
122
|
-
phases: np.ndarray,
|
|
123
|
-
velocity_grid: np.ndarray,
|
|
124
|
+
trailed: np.ndarray, # (n_phases, n_velocity)
|
|
125
|
+
phases: np.ndarray, # (n_phases,)
|
|
126
|
+
velocity_grid: np.ndarray, # (n_velocity,)
|
|
124
127
|
gamma_kms: float,
|
|
125
128
|
n_velocity: int,
|
|
126
129
|
) -> np.ndarray:
|
|
@@ -157,7 +160,9 @@ def _back_project(
|
|
|
157
160
|
# 2.0.0: back-projection locus follows Marsh & Horne 1988 Eq. 1
|
|
158
161
|
# (v = γ − Vx·cos 2πφ + Vy·sin 2πφ); v1 had sin/cos swapped and
|
|
159
162
|
# produced maps reflected with respect to the literature convention.
|
|
160
|
-
|
|
163
|
+
# 3.0.0: velocities a spectrum does not cover stay NaN and are excluded from
|
|
164
|
+
# the back-projection average (2.x set them to 0 and counted them).
|
|
165
|
+
version="3.0.0",
|
|
161
166
|
)
|
|
162
167
|
class DopplerTomogram(BaseAlgorithm):
|
|
163
168
|
"""Doppler tomogram of a binary from N phase-resolved spectra.
|
|
@@ -190,8 +195,7 @@ class DopplerTomogram(BaseAlgorithm):
|
|
|
190
195
|
|
|
191
196
|
backend = "numpy"
|
|
192
197
|
references = [
|
|
193
|
-
"Marsh & Horne 1988, MNRAS 235, 269 — Doppler tomography by "
|
|
194
|
-
"back-projection (§2).",
|
|
198
|
+
"Marsh & Horne 1988, MNRAS 235, 269 — Doppler tomography by back-projection (§2).",
|
|
195
199
|
"Horne 1985, MNRAS 213, 129 — MEM tomographic reconstruction "
|
|
196
200
|
"(not implemented; cited for completeness).",
|
|
197
201
|
"Marsh 2001, Lecture Notes in Physics 573 — astrotomography review.",
|
|
@@ -225,7 +229,9 @@ class DopplerTomogram(BaseAlgorithm):
|
|
|
225
229
|
"gamma_kms": "Systemic velocity (km/s) added to the back-projection.",
|
|
226
230
|
"line_center_aa": "Rest wavelength (Å) of the line to tomogram.",
|
|
227
231
|
"velocity_window_kms": "Half-extent (km/s) of the V_x/V_y axes.",
|
|
228
|
-
"n_velocity":
|
|
232
|
+
"n_velocity": (
|
|
233
|
+
"Number of velocity samples per axis (11–401 ; an odd value puts a sample at 0)."
|
|
234
|
+
),
|
|
229
235
|
}
|
|
230
236
|
input_requirements: list[str] = [] # validated dynamically
|
|
231
237
|
output_produces = [
|
|
@@ -240,9 +246,7 @@ class DopplerTomogram(BaseAlgorithm):
|
|
|
240
246
|
def run(self, ctx: WorkContext, params: dict[str, Any]) -> AlgorithmOutput:
|
|
241
247
|
spectra = list(ctx.spectra or [])
|
|
242
248
|
if len(spectra) < 3:
|
|
243
|
-
return AlgorithmOutput.fail(
|
|
244
|
-
f"Need ≥ 3 spectra in ctx.spectra; got {len(spectra)}."
|
|
245
|
-
)
|
|
249
|
+
return AlgorithmOutput.fail(f"Need ≥ 3 spectra in ctx.spectra; got {len(spectra)}.")
|
|
246
250
|
|
|
247
251
|
period = float(params["period_days"])
|
|
248
252
|
if period <= 0.0:
|
|
@@ -284,11 +288,15 @@ class DopplerTomogram(BaseAlgorithm):
|
|
|
284
288
|
rows.sort(key=lambda row: row[0])
|
|
285
289
|
phases = np.asarray([row[0] for row in rows], dtype=np.float64)
|
|
286
290
|
trailed = np.stack([row[1] for row in rows], axis=0)
|
|
287
|
-
# NaN-aware:
|
|
288
|
-
#
|
|
289
|
-
|
|
291
|
+
# NaN-aware: velocities a spectrum does not cover stay NaN; np.interp
|
|
292
|
+
# propagates them and _back_project excludes them from the average
|
|
293
|
+
# ("no data" ≠ "0 signal" — 2.x zeroed them and counted them).
|
|
290
294
|
doppler_map = _back_project(
|
|
291
|
-
|
|
295
|
+
trailed,
|
|
296
|
+
phases,
|
|
297
|
+
velocity_grid,
|
|
298
|
+
gamma_kms,
|
|
299
|
+
n_velocity,
|
|
292
300
|
)
|
|
293
301
|
|
|
294
302
|
result = {
|
{spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/catalogs/gaia.py
RENAMED
|
@@ -5,11 +5,35 @@ from __future__ import annotations
|
|
|
5
5
|
from typing import Any
|
|
6
6
|
|
|
7
7
|
from ...base import AlgorithmOutput, BaseAlgorithm
|
|
8
|
+
from ...errors import InvalidParameterError
|
|
8
9
|
from ...registry import register_algorithm
|
|
9
10
|
from ...types import AlgorithmCategory, CatalogResult, WorkContext
|
|
10
11
|
|
|
12
|
+
_RELEASE_TABLES = {
|
|
13
|
+
"dr3": "gaiadr3.gaia_source",
|
|
14
|
+
"edr3": "gaiaedr3.gaia_source",
|
|
15
|
+
"dr2": "gaiadr2.gaia_source",
|
|
16
|
+
}
|
|
11
17
|
|
|
12
|
-
|
|
18
|
+
|
|
19
|
+
def _release_table(value: object) -> str:
|
|
20
|
+
"""ADQL table of a release alias ('DR3', 'EDR3', 'DR2') or a full table name."""
|
|
21
|
+
if value is None or str(value).strip() == "":
|
|
22
|
+
return _RELEASE_TABLES["dr3"]
|
|
23
|
+
key = str(value).strip().lower().replace("gaia", "").replace(" ", "")
|
|
24
|
+
if key in _RELEASE_TABLES:
|
|
25
|
+
return _RELEASE_TABLES[key]
|
|
26
|
+
if "." in str(value):
|
|
27
|
+
return str(value).strip()
|
|
28
|
+
raise InvalidParameterError(
|
|
29
|
+
f"data_release {value!r} is neither a release alias (DR3, EDR3, DR2) nor a "
|
|
30
|
+
"table name such as 'gaiadr3.gaia_source'."
|
|
31
|
+
)
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
# 1.1.0: data_release accepts the release aliases the description always
|
|
35
|
+
# promised (DR3, DR2, EDR3, case-insensitive) next to a full table name.
|
|
36
|
+
@register_algorithm("gaia_query", category=AlgorithmCategory.CATALOG, version="1.1.0")
|
|
13
37
|
class GaiaQuery(BaseAlgorithm):
|
|
14
38
|
"""Cone-search the Gaia archive around ICRS coordinates.
|
|
15
39
|
|
|
@@ -28,9 +52,10 @@ class GaiaQuery(BaseAlgorithm):
|
|
|
28
52
|
"Ginsburg et al. 2019, AJ 157, 98 — astroquery",
|
|
29
53
|
]
|
|
30
54
|
long_description = (
|
|
31
|
-
"Requires network access and the optional 'catalogs' extra.
|
|
32
|
-
"
|
|
33
|
-
"
|
|
55
|
+
"Requires network access and the optional 'catalogs' extra. Queries "
|
|
56
|
+
"gaiadr3.gaia_source by default (the latest full release). `data_release` "
|
|
57
|
+
"accepts a release alias ('DR3', 'EDR3', 'DR2', case-insensitive) or a full "
|
|
58
|
+
"table name such as 'gaiadr2.gaia_source'."
|
|
34
59
|
)
|
|
35
60
|
default_params = {
|
|
36
61
|
"ra_deg": None,
|
|
@@ -43,7 +68,10 @@ class GaiaQuery(BaseAlgorithm):
|
|
|
43
68
|
"ra_deg": "Right ascension (ICRS) in degrees.",
|
|
44
69
|
"dec_deg": "Declination (ICRS) in degrees.",
|
|
45
70
|
"radius_arcsec": "Cone-search radius around the position.",
|
|
46
|
-
"data_release":
|
|
71
|
+
"data_release": (
|
|
72
|
+
"Gaia release: an alias ('DR3', 'EDR3', 'DR2') or a full table name "
|
|
73
|
+
"('gaiadr3.gaia_source'); null means DR3."
|
|
74
|
+
),
|
|
47
75
|
}
|
|
48
76
|
input_requirements: list[str] = []
|
|
49
77
|
output_produces = ["catalog_lookups"]
|
|
@@ -53,14 +81,13 @@ class GaiaQuery(BaseAlgorithm):
|
|
|
53
81
|
from astroquery.gaia import Gaia as _Gaia
|
|
54
82
|
except ImportError:
|
|
55
83
|
return AlgorithmOutput.fail(
|
|
56
|
-
"gaia_query needs astroquery. "
|
|
57
|
-
"Install with: pip install 'spectro-kernel[catalogs]'."
|
|
84
|
+
"gaia_query needs astroquery. Install with: pip install 'spectro-kernel[catalogs]'."
|
|
58
85
|
)
|
|
59
86
|
|
|
60
87
|
ra = float(params["ra_deg"])
|
|
61
88
|
dec = float(params["dec_deg"])
|
|
62
89
|
radius_deg = float(params["radius_arcsec"]) / 3600.0
|
|
63
|
-
table_name = params.get("data_release")
|
|
90
|
+
table_name = _release_table(params.get("data_release"))
|
|
64
91
|
adql = (
|
|
65
92
|
f"SELECT TOP 1 source_id, ra, dec, parallax, phot_g_mean_mag, "
|
|
66
93
|
f"DISTANCE(POINT('ICRS', ra, dec), POINT('ICRS', {ra}, {dec})) AS sep "
|
|
@@ -81,7 +108,7 @@ class GaiaQuery(BaseAlgorithm):
|
|
|
81
108
|
ctx.catalog_lookups[key] = result
|
|
82
109
|
return AlgorithmOutput.ok(
|
|
83
110
|
artifacts={"result": result.to_dict()},
|
|
84
|
-
message=f
|
|
111
|
+
message=f'Gaia returned no source within {params["radius_arcsec"]}".',
|
|
85
112
|
)
|
|
86
113
|
|
|
87
114
|
row = table[0]
|
|
@@ -95,9 +122,7 @@ class GaiaQuery(BaseAlgorithm):
|
|
|
95
122
|
fields={
|
|
96
123
|
"parallax_mas": float(row["parallax"]) if row["parallax"] is not None else None,
|
|
97
124
|
"G_mag": (
|
|
98
|
-
float(row["phot_g_mean_mag"])
|
|
99
|
-
if row["phot_g_mean_mag"] is not None
|
|
100
|
-
else None
|
|
125
|
+
float(row["phot_g_mean_mag"]) if row["phot_g_mean_mag"] is not None else None
|
|
101
126
|
),
|
|
102
127
|
"separation_deg": float(row["sep"]),
|
|
103
128
|
},
|
|
@@ -105,5 +130,5 @@ class GaiaQuery(BaseAlgorithm):
|
|
|
105
130
|
ctx.catalog_lookups[source_id] = result
|
|
106
131
|
return AlgorithmOutput.ok(
|
|
107
132
|
artifacts={"result": result.to_dict()},
|
|
108
|
-
message=f
|
|
133
|
+
message=f'Gaia source {source_id} at {row["sep"] * 3600:.2f}".',
|
|
109
134
|
)
|
{spectro_kernel-0.8.1 → spectro_kernel-0.9.1}/src/spectro_kernel/algorithms/catalogs/simbad.py
RENAMED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"""Algorithm: resolve an object against the SIMBAD database.
|
|
2
2
|
|
|
3
3
|
Requires the optional ``catalogs`` extra (``pip install spectro-kernel[catalogs]``).
|
|
4
|
-
|
|
5
|
-
the catalogue
|
|
4
|
+
The algorithm registers whether or not astroquery is installed; without it, running
|
|
5
|
+
the brick fails with an install hint and the rest of the catalogue is unaffected.
|
|
6
6
|
"""
|
|
7
7
|
|
|
8
8
|
from __future__ import annotations
|
|
@@ -25,7 +25,7 @@ def _cell(row: Any, *names: str) -> Any:
|
|
|
25
25
|
return None
|
|
26
26
|
|
|
27
27
|
|
|
28
|
-
@register_algorithm("simbad_query", category=AlgorithmCategory.CATALOG, version="1.0.
|
|
28
|
+
@register_algorithm("simbad_query", category=AlgorithmCategory.CATALOG, version="1.0.1")
|
|
29
29
|
class SimbadQuery(BaseAlgorithm):
|
|
30
30
|
"""Resolve an object name against SIMBAD and store the record in the context.
|
|
31
31
|
|