Installation Guide | readthedocs | Introduction on Colab | HowToGalaxy
PyAutoGalaxy is software for analysing the morphologies and structures of galaxies:
PyAutoGalaxy also fits interferometer data from observatories such as ALMA:
You can use PyAutoGalaxy by describing what you want in natural language, through the PyAutoGalaxy AI Assistant, or by writing Python yourself. Both routes use the same software. To start in natural language, paste this prompt into Claude Code, Codex or another AI coding agent:
Starting prompt for Claude Code, Codex or other AI coding agent
I want to study galaxy structure and morphology with PyAutoGalaxy (https://github.com/PyAutoLabs/PyAutoGalaxy)
and the autogalaxy_assistant (https://github.com/PyAutoLabs/autogalaxy_assistant). First clone that
repository, cd into it and follow its AGENTS.md.
Begin the "start here" guide for a new user.
The assistant takes you through the Start Here page as a conversation (grids, light profiles and bulge-plus-disk galaxies, then simulating and fitting a galaxy image), one step at a time, then helps you get started on your own galaxies. Claude Code and Codex are recommended, and sustained scientific use normally needs paid access to one of them. Free options are listed on the AI Options page. Start Here explains why PyAutoGalaxy is designed to be used in natural language, and why its Python API is not going anywhere.
All of the documentation and examples are written for people to read:
- The PyAutoGalaxy readthedocs, which includes an overview of PyAutoGalaxy's core features, a new user starting guide and an installation guide.
- The introduction Jupyter Notebook on Google Colab, where you can try PyAutoGalaxy in a web browser (without installation).
- The autogalaxy_workspace GitHub repository: example scripts covering every PyAutoGalaxy use case.
- The HowToGalaxy GitHub repository: a Jupyter notebook lecture series teaching galaxy modeling from the ground up.
PyAutoGalaxy has three core aims:
- Big Data: Scaling automated Sérsic fitting to extremely large datasets, accelerated with JAX on GPUs and using tools like an SQL database to build a scalable scientific workflow.
- Model Complexity: Fitting complex galaxy morphology models (e.g. Multi Gaussian Expansion, Shapelets, Ellipse Fitting, Irregular Meshes) that go beyond just simple Sérsic fitting.
- Data Variety: Support for many data types (e.g. CCD imaging, interferometry, multi-band imaging) which can be fitted independently or simultaneously.
A complete overview of the software's aims is provided in our Journal of Open Source Software paper.
PyAutoGalaxy is built in the open by its users: everyone is welcome to ask questions, share what they have made with it, and contribute.
Questions, ideas and bug reports: the PyAutoLabs Discussions. Chat with us on Slack.
Community-built tools and tutorials, and how to contribute: the PyAutoGalaxy community page.
For users less familiar with galaxy analysis, Bayesian inference, and scientific analysis, you may wish to read through the HowToGalaxy lectures. These introduce the basic principles of galaxy modeling and Bayesian inference, with the material pitched at undergraduate level and above.
A complete overview of the lectures is provided on the HowToGalaxy readthedocs page, and the notebooks themselves live in the PyAutoLabs/HowToGalaxy repository.
Information on how to cite PyAutoGalaxy in publications can be found on the citations page.

