← Back

Python · PyPI Package

Maglimit

github.com/iamstarstuff/maglimit
PythonPyPIAstropy

Maglimit is a Python package for astronomical observability calculations. It answers the question: given a telescope with a specific aperture and a sky with a specific darkness, can you observe an object of a given magnitude?

It was built during the Code/Astro 2023 workshop at Northwestern University — a week-long workshop focused on software engineering best practices for astronomers. The goal was to produce a properly packaged, documented, and tested Python package by the end of the week.

What it does

The limiting magnitude of a telescope depends on aperture, atmospheric seeing, sky background brightness, and the observer's eye or detector. Maglimit computes this limit and compares it against a target object's apparent magnitude to determine observability.

It integrates with Astropy for unit handling and coordinate transforms, so it works naturally with existing astronomy workflows. Input a telescope's aperture in mm and a sky brightness in mag/arcsec², and it returns whether a given target is detectable.

Code/Astro

Code/Astro is a workshop run by astronomers for astronomers, focused on turning research scripts into properly engineered software. The workshop covers version control, packaging, testing, documentation, and continuous integration — skills that are rarely taught in physics programmes.

Maglimit was published to PyPI at the end of the workshop week and is installable with pip.