Skip to main content

Logo

lfast-etc

Exposure Time Calculator for the LFAST telescope array at Kitt Peak (nominally 20 x 0.726 m unit telescopes feeding one spectrograph through an 18 um fiber combiner), with two instruments: the WIYN Bench spectrograph (visible; the 15 grating/order modes of the WIYN configuration table that reach 400 nm, scaled from the reference 600 @ 10.1 deg mode by scripts/build_bench_presets.py) and CSHELL (1.08-1.75 um, R up to 43,000).

The number of telescopes, the fiber, and every instrument parameter are plain inputs, so the calculator follows the array design as it evolves. The physics is the per-resolution-element model of the reference LFAST ETC notebook (2026-10-12) with the Choi et al. (2026, SPIE 14147) throughput model; the test-suite reproduces that notebook to 1e-6.

Install

Requires Python >= 3.11 and numpy >= 2.0.

git clone git@github.com:schmidt-observatories/lfast-etc.git
cd lfast-etc
pip install -e .            # core
pip install -e ".[web]"     # + browser ETC
pip install -e ".[docs,web]"  # + Sphinx docs (the API page documents the web app)

Quick start

from lfast_etc import LFASTETC, Source, Telescope

etc = LFASTETC("bench_r1800", n_telescopes=20)          # presets: list_instruments()
star = Source.blackbody(5800, mag=15, band="V")
res = etc.exptime(star, snr=50)                         # per resolution element
res.plot(); res.summary(); res.at(550.0); res.to_table()

res = etc.snr(star, exptime=600, n_exp=3)               # SNR for 600 s in 3 reads
res.plot_noise_budget(); res.plot_spectrum()            # what limits you; what the spectrum looks like
etc.plot_throughput(); etc.plot_sky(); star.plot()
etc.limiting_magnitude(star, exptime=900, snr=10, wavelength=(500, 650))
etc.snr_grid(star, mags, exptimes, wavelength=(500, 650))   # sensitivity map

# scale the array
LFASTETC("cshell_r43000", telescope=Telescope(n_telescopes=40, fiber="18um"),
         wavelength_min_nm=1081, wavelength_max_nm=1086)

Everything is per resolution element; SNR per pixel is lower by about sqrt(n_pix). The bundled sky is grey time (moon up), so faint-end numbers are 0.3-0.5 mag pessimistic for dark time. The docs (docs/, build with make html, or hosted on Read the Docs once the project is connected) have a quick start, the concepts, every preset, the physics and its known limitations, and a plot gallery.

Browser ETC

pip install -e ".[web]"
lfast-etc-web --port 5000     # http://127.0.0.1:5000  (JSON at /api/calc?...)

Notebooks

notebooks/ holds executed examples, written as a walkthrough for someone new to the package. Start with 01 (the whole API, with checks and exercises at the end). 01-05 are rebuilt with python scripts/build_notebooks.py: quick start, sensitivity maps and array scaling, stellar metallicity, transient classification, exoplanet atmospheres (He 10830) with CSHELL. 06-10 (python scripts/build_science_notebooks.py) compare science cases versus the array size (20 telescopes, 10 m equivalent = 200, 30 m equivalent = 1720): array-scaling overview, LSST-era time domain, Galactic archaeology, stellar activity and flares, CSHELL NIR science. The notebooks are generated from those scripts; edit the scripts, not the .ipynb files.

Docs

pip install -e ".[docs,web]"
cd docs && make html         # needs pandoc on PATH for the notebooks

Tests

pytest

CI (GitHub Actions) runs the tests on Python 3.11-3.13 and builds the docs on every push and pull request. Bugs and planned features are tracked in the issues, labelled by area and priority.

Layout

src/lfast_etc/        package (etc.py, source.py, telescope.py, instrument.py, sky.py, plotting.py)
src/lfast_etc/data/   throughput curves, SkyCalc table, instrument presets (TOML)
src/lfast_etc/web/    Flask + Bokeh browser ETC
notebooks/            executed example notebooks
docs/                 Sphinx site
tests/                pytest, including the regression test against the reference notebook

License

BSD 3-Clause. See LICENSE.

Metadata

Release files for lfast-etc 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for lfast-etc 0.1.1
File Size Uploaded Provenance Actions
lfast_etc-0.1.1.tar.gz 2.8 MB With provenance Details for lfast_etc-0.1.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for lfast-etc 0.1.1
File Interpreter ABI Platform Actions
lfast_etc-0.1.1-py3-none-any.whl Python 3 none any Details for lfast_etc-0.1.1-py3-none-any.whl

Total release size: 5.6 MB

Release files / lfast_etc-0.1.1.tar.gz

Download URL lfast_etc-0.1.1.tar.gz
Size 2.8 MB
Tags Source
SHA-256 checksum
How to use checksums
35878c672ddc5ef21ba6f6a05cdec84ed3482c2d5249d3fa11ea5ee8cb35b13c
BLAKE2b-256 checksum
How to use checksums
7ef0d7ae7d9eba90c58c4738b1b4728439b393d8a1c13d597915ae55dbbca488
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Oct 29, 2026.

Transparency log

Release files / lfast_etc-0.1.1-py3-none-any.whl

Download URL lfast_etc-0.1.1-py3-none-any.whl
Size 2.8 MB
Tags Python 3
SHA-256 checksum
How to use checksums
f8ca017c2d862dcdce6b449f1780f7d73702912fc4bc270704a81e2e7593db4e
BLAKE2b-256 checksum
How to use checksums
b7710fc4f0705f20e24d54e1d8f37a6fdbce87dc04e237dafcdf71dc19a39f60
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Oct 29, 2026.

Transparency log

Security for lfast-etc 0.1.1

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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for lfast_etc-0.1.1.tar.gz

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 Oct 29, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page