astropy

Unify coordinates, units, FITS I/O, time scales, and WCS transformations for astronomy data analysis in Python.

22|4|Updated May 25, 2026
One-click install
npx skills add https://github.com/crazymsn/academic-skills --skill astropy-crazymsn
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: astropy
Source: https://github.com/crazymsn/academic-skills/tree/main/academic-skills/astropy
Command: npx skills add https://github.com/crazymsn/academic-skills --skill astropy-crazymsn

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Astropy provides a unified Python toolkit that brings together coordinates, units, FITS I/O, time handling, WCS, cosmology, and table processing to streamline astronomical data analysis and reduce fragmentation across multiple libraries.

Core Features & Use Cases

  • Coordinate transformations and unit management with astropy.coordinates and astropy.units.
  • FITS I/O, table manipulation, and data handling via astropy.io.fits and astropy.table.
  • Cosmology calculations and time scale conversions using astropy.cosmology and astropy.time.
  • World Coordinate System transformations and data visualization workflows for imaging and catalogs.

Quick Start

Load a sample dataset and perform a simple coordinate conversion and FITS header inspection.

Frequently Asked Questions about astropy

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I convert FITS image headers to world coordinate system transformations in Python?

World coordinate system transformations are handled by parsing FITS headers and applying WCS mappings to translate pixel coordinates into celestial coordinates. The astropy toolkit provides built-in modules to perform these transformations natively alongside FITS I/O operations.

What is the best way to handle astronomical coordinate transformations and unit management?

Astronomical coordinate transformations and unit management are unified through dedicated coordinates and units modules. This approach ensures consistent physical unit handling and frame conversions across datasets, reducing fragmentation from using multiple separate Python libraries.

Can I perform cosmology calculations and time scale conversions with NumPy arrays?

Cosmology calculations and time scale conversions fully support NumPy array operations. The toolkit integrates with NumPy and SciPy environments, allowing you to compute cosmological models and convert time scales across large datasets efficiently.

Does Python have a unified toolkit for FITS I/O and astronomical table manipulation?

A unified Python toolkit for FITS I/O and table manipulation exists within the astropy ecosystem. It provides dedicated modules for reading, writing, and manipulating FITS files and astronomical tables, streamlining data handling from small catalogs to large survey images.

How do I calculate distances using built-in cosmology models for survey data?

Cosmology models are built directly into the astronomy toolkit, enabling distance calculations for survey data. You can apply these pre-configured models to large datasets to compute cosmological distances and scale factors without external dependencies.