astropy
Skill by K-Dense-AI
Astropy is a skill that guides an AI assistant through the Astropy Python library for astronomy. It covers units, coordinates, FITS files, tables, time, WCS and cosmology. It is for developers writing or debugging astronomical data analysis code.
Install astropy
Built from the published package, never by AI.
git clone --depth 1 https://github.com/K-Dense-AI/scientific-agent-skills /tmp/scientific-agent-skills && mkdir -p ~/.claude/skills && cp -r /tmp/scientific-agent-skills/skills/astropy ~/.claude/skills/astropyRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
git clone --depth 1 https://github.com/K-Dense-AI/scientific-agent-skills /tmp/scientific-agent-skills && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/scientific-agent-skills/skills/astropy ~/.gemini/antigravity-cli/skills/astropyAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Skills can run scripts on your machine. Some need an API key: check the README.
About
The astropy skill gives an AI assistant guidance on the Astropy Python package, described as the core library for astronomy and astrophysics. It covers units and quantities, celestial coordinates, FITS file handling, tables, time scales, WCS pixel and world transforms, and cosmological calculations. Each topic points to a separate reference file with more detailed documentation.
The skill targets Astropy 8.0.1 and states that its numerical and small synthetic examples were executed. It requires Python 3.11+, NumPy 2+ and SciPy for cosmology, matching and fitting, and uses uv for installation. The source is aimed at developers implementing or debugging astronomical data analysis code with Astropy.
Written from the project's SKILL.md and checked against it.
What it can do
- Units and quantitiesConverts physical units and handles dimensional consistency in calculations.
- Coordinate systemsCreates SkyCoord objects, transforms between frames and matches catalogs.
- CosmologyCalculates luminosity distance, lookback time, Hubble parameter and volumes.
- FITS file handlingReads and writes FITS images and tables, and edits headers and HDUs.
- Table operationsReads and writes tables, then sorts, filters, joins and groups them.
- Time handlingConverts between time scales and formats and computes light travel corrections.
- WCS transformsConverts between pixel and world coordinates and calculates image footprints.
- Additional modulesCovers NDData, modeling, visualization, constants, convolution and statistics.
What you need
- Python 3.11+
- NumPy 2+
- SciPy for cosmology, matching and fitting
- uv for installation
- Network access for name resolution, site lookups, remote FITS reads and IERS updates
Try asking
- Convert RA 10.5 and Dec 41.2 degrees to Galactic coordinates with Astropy
- Calculate the luminosity distance at z=1.5 using Planck18 in Astropy
- Cross-match two FITS catalogs within 1 arcsec and count the matches
Good to know
- Some features need network access, such as name resolution and remote FITS reads.
- The recommended and all extras pull in unpinned transitive dependencies.
- Some examples are illustrative and require input files, online services or a GUI.
- WCS pixel methods use zero-based (x, y), while NumPy arrays index [row, column].
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: skills/astropy/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Inside the skill
-
SKILL.md17 KB -
references/coordinates.md9 KB -
references/cosmology.md8 KB -
references/fits.md11 KB -
references/review.md8 KB
Show all 9 files
-
references/tables.md11 KB -
references/time.md11 KB -
references/units.md4 KB -
references/wcs_and_other_modules.md11 KB
Alternatives to astropy
All alternatives →Searches arXiv for scientific papers and preprints, extracts their metadata and abstracts, and downloads PDF or HTML full text. Suited to users who need research papers, literature or specific arXiv IDs.
Downloads AlphaFold predicted structures and PAE matrices for a UniProt ID, then reports pLDDT confidence, domain boundaries and disorder. Built for users who already have a UniProt accession.
Queries the QuickGO and Evidence & Conclusion Ontology REST API to map genes to Gene Ontology terms. Built for researchers doing functional annotation and GO hierarchy exploration.
Connects an AI assistant to Peloton to browse fitness classes, check live and archived schedules, and manage workouts. Built for Peloton users who want to plan rides from their assistant.
Queries NCBI Gene through the E-utilities and Datasets API. It helps researchers search genes by symbol or ID, retrieve gene details, and run batch lookups for annotation and functional analysis.
Prepares and launches nf-core/pacsomatic runs for matched tumor-normal PacBio HiFi data starting from unaligned BAM files. It generates samplesheets and pinned launch artifacts, then runs locally or submits to a scheduler.
Compare with literature-search-arxiv, alphafold-database-fetch-and-analyze or quickgo-database
astropy: common questions
Which Astropy version does this skill target?
The skill targets Astropy 8.0.1 and requires Python 3.11+ and NumPy 2+. It also lists SciPy for cosmology, catalog matching and fitting.
Does the astropy skill need an internet connection?
Some features need network access, including object name resolution, site lookups, remote FITS reads and IERS updates. Other features work offline.
What astronomy tasks can the astropy skill help with?
It covers coordinate transforms, units, FITS I/O, tables, time systems, WCS and cosmology. It also points to reference files for modeling, visualization, convolution and statistics.
How do I install astropy?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is astropy free?
The code is published under the MIT licence. The service it connects to may have its own pricing.
Is astropy safe to use?
It scores 94 of 100. Grades: maintenance A, licence A, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to astropy?
Similar skills: literature-search-arxiv, alphafold-database-fetch-and-analyze, quickgo-database, peloton.
