qsospec
qsospec fits UV, optical, and near-infrared quasar spectra. It provides
coverage-aware emission-line recipes, continuum decomposition, optional pPXF
host subtraction, QA figures, and resumable Parquet run bundles.
Installation
python -m pip install qsospec
For host-galaxy decomposition:
python -m pip install "qsospec[host]"
Minimal example
import qsospec
spectrum = qsospec.Spectrum.from_arrays(
wavelength,
flux,
err=uncertainty,
z=redshift,
wave_frame="observed",
flux_unit="cgs",
ra=ra,
dec=dec,
)
result = qsospec.fit_object_to_store(
spectrum,
"runs/my-quasar",
object_id="my-quasar",
global_config=qsospec.GlobalContinuumConfig(
power_law=qsospec.PowerLawConfig(mode="auto"),
),
write_qa=True,
)
result.show_qa()
Uncorrected spectra are dereddened by default with Planck GNILC and the
Fitzpatrick (1999) law. This requires locally configured
dustmaps
data; already-corrected spectra can be declared with
galactic_extinction_corrected=True.
Features
- Single or automatically selected broken power-law continua, Fe II, and a continuous Balmer pseudo-continuum.
- Lyα/N V, C IV, C III], Mg II, Balmer, optical, and NIR line complexes.
- Optional pPXF host decomposition for quasars at
z < 1.2. - Notebook-friendly and saved QA figures.
- Shared single-object and parallel batch run format.
See the documentation for setup, workflows, model definitions, examples, and API reference.
qsospec is distributed under the
GPLv3 license.
Metadata
Release files for qsospec 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| qsospec-0.1.1.tar.gz | 851.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| qsospec-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 1.2 MB
Release files / qsospec-0.1.1.tar.gz
| Download URL | qsospec-0.1.1.tar.gz |
|---|---|
| Size | 851.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0a8e2573a256163505708cb3899c7d9a0eb4acaeae0a055d14e5f45b92192706
|
|
BLAKE2b-256 checksum How to use checksums |
d65476edb8c7e4e40bc46a5ce6da48c1db7d8d275868f63df0ef6a9beddeb98a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 22, 2026.
Transparency logRelease files / qsospec-0.1.1-py3-none-any.whl
| Download URL | qsospec-0.1.1-py3-none-any.whl |
|---|---|
| Size | 346.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8a66cfc60c96c1491f0a9d01ffb02cd3f3d9669e314f1c90709ed6bef7129768
|
|
BLAKE2b-256 checksum How to use checksums |
12c45ea02d35521d5ca96928634ed89ae305cc73f6400ffcc7f1e3e47a49b55c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 22, 2026.
Transparency log