Skip to main content

Common Routines of OCA Observatory and Araucaria Project

Project description

Common Routines of OCA Observatory and Araucaria Project

pyaraucaria is a Python library providing a collection of common routines and command-line tools used in the Araucaria Project and OCA (Observatorio Cerro Armazones) observatory software. It aims to be a lightweight, dependency-focused toolkit for astronomical data processing and observatory operations.

The library requires Python 3.10+.

Installation

Basic Install

pip install git+https://github.com/araucaria-project/pyaraucaria.git

Developer Install

git clone https://github.com/araucaria-project/pyaraucaria.git
cd pyaraucaria
uv sync --all-extras

Usage in Your Project

Add to your pyproject.toml dependencies:

dependencies = [
    "pyaraucaria @ git+https://github.com/araucaria-project/pyaraucaria.git",
]

Or directly form PyPi, after checking versions (PyPi releases may lag behind GitHub):

dependencies = [
    "pyaraucaria>=2.11.0",
]

Core Modules

Coordinates

pyaraucaria.coordinates contains dependency-free, fast routines to parse and format sexagesimal coordinates (RA/Dec).

from pyaraucaria.coordinates import ra_to_decimal, dec_to_sexagesimal
ra = ra_to_decimal('12:30:00')  # Returns 187.5
dec = dec_to_sexagesimal(-15.5)  # Returns '-15:30:00.000'

Lookup Objects

Lookup for objects/targets parameters using one of its aliases. Uses Objects.database and TAB.ALL files.

from pyaraucaria.lookup_objects import ObjectsDatabase
od = ObjectsDatabase()
od.lookup_object('lmc105_8_11987')

Date and Time

pyaraucaria.date handles conversion between Julian dates, datetime objects, and heliocentric corrections.

FITS Operations

pyaraucaria.fits provides utilities for reading and writing FITS files, including header management and array saving.

Fast FITS Statistics (FFS)

pyaraucaria.ffs provides optimized routines for star detection in images and basic image statistics (mean, median, noise estimation).

Focus

pyaraucaria.focus implements various telescope focusing algorithms (RMS, FWHM, Lorentzian, Laplacian).

Ephemeris

pyaraucaria.ephemeris offers calculations for moon illumination, object visibility, and other ephemeris-related data using astropy and astroplan.

Airmass

pyaraucaria.airmass calculates airmass based on elevation using Kasten and Young's model.

Reddening

pyaraucaria.reddening provides lookup for interstellar reddening based on coordinate databases (e.g., LMC).

Dome Geometry

pyaraucaria.dome_eq calculates the required dome azimuth for telescopes on equatorial mounts.

Observation Plan Parser

pyaraucaria.obs_plan contains a parser for custom observation plan formats using the lark grammar library.

Command Line Tools

lookup_objects

Query the object database from the command line.

lookup_objects -j hd167003

find_stars

Perform star detection and calculate statistics on a FITS file.

find_stars path/to/image.fits gain=1.2 rn_noise=5.0

Development and Testing

To run tests:

python -m unittest discover tests

License

This project is licensed under the LGPL-3.0-or-later License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyaraucaria-2.11.2.tar.gz (210.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyaraucaria-2.11.2-py3-none-any.whl (206.0 kB view details)

Uploaded Python 3

File details

Details for the file pyaraucaria-2.11.2.tar.gz.

File metadata

  • Download URL: pyaraucaria-2.11.2.tar.gz
  • Upload date:
  • Size: 210.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.7

File hashes

Hashes for pyaraucaria-2.11.2.tar.gz
Algorithm Hash digest
SHA256 b9c3caeccf68fe956036c4f85f13d00e8eee92065b2069949723e8b750efc062
MD5 913846f0e96b8655f9f197aadae500fe
BLAKE2b-256 a0075f3d665ecf3ee5b9b69a3528d1927b0afbba47faae6d64b8850a1e5a0f96

See more details on using hashes here.

File details

Details for the file pyaraucaria-2.11.2-py3-none-any.whl.

File metadata

File hashes

Hashes for pyaraucaria-2.11.2-py3-none-any.whl
Algorithm Hash digest
SHA256 2a13d846584ce1e22502059f74c41431695e6207376ea85698b81ff79227b90c
MD5 957facb837ed50fb73753ae90c812fe7
BLAKE2b-256 1bf001c6bfeffbe887ee4ce3e2904d9ebb499a554067a6777b6af0fe72b02b3e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page