Skip to main content

Galaxies Datasets

Project description

Galaxies Datasets

PyPI Status Python Version License

Read the documentation at https://galaxies_datasets.readthedocs.io/ Tests Codecov

pre-commit Black

Galaxies Datasets is a collection of ready-to-use extragalactic astronomy datasets for use with TensorFlow, Jax, and other Machine Learning frameworks.

It follows the tensorflow_datasets framework, making it very easy to switch between different datasets. All datasets are exposed as tf.data.Datasets, enabling easy-to-use and high-performance input pipelines.

Usage

Loading a dataset can be as easy as:

from galaxies_datasets import datasets
import tensorflow_datasets as tfds

# Construct a tf.data.Dataset
ds = tfds.load("galaxy_zoo_challenge", split="train")

# Build your input pipeline
ds = ds.shuffle(1000).batch(128).prefetch(10).take(5)

In the example above:

from galaxies_datasets import datasets

registers the collection of galactic datasets with the tensorflow_datasets package making them available through its API. And that is it! …Almost.

For more details on tensorflow_datasets check out the documentation.

Some datasets require that you first manually download data. Check each dataset for instructions.

Datasets

Currently available datasets focus on galaxy morphology.

They include observational data from the Galaxy zoo project:

  • galaxy_zoo_challenge

  • galaxy_zoo2

  • galaxy_zoo_decals

As well as mock galaxy images from the EAGLE simulation:

  • eagle

Installation

You can install Galaxies Datasets via pip from PyPI:

$ pip install galaxies_datasets

Scripts

Galaxies Datasets provides some scripts to download and prepare data. The scripts are available through a command-line interface powered by Typer.

For example, to download images and data from the EAGLE simulation you could simply do:

galaxies_datasets eagle download USER SIMULATION

where USER is your username for the EAGLE public database and SIMULATION is the name of one of the EAGLE simulations.

For all available commands check the Command-line Interface reference, or run:

galaxies_datasets --help

The command-line interface also supports automatic completion in all operating systems, in all the shells (Bash, Zsh, Fish, PowerShell), so that you can just hit TAB and get the available options or subcommands.

To install automatic completion in bash run:

galaxies_datasets --install-completion bash

Contributing

Contributions are very welcome. To learn more, see the Contributor Guide.

License

Distributed under the terms of the MIT license, Galaxies Datasets is free and open source software.

Issues

If you encounter any problems, please file an issue along with a detailed description.

Disclaimer

This is a utility library that downloads and prepares datasets. We do not host or distribute these datasets, vouch for their quality or fairness, or claim that you have license to use the dataset. It is your responsibility to determine whether you have permission to use the dataset under the dataset’s license.

If you’re a dataset owner and wish to update any part of it (description, citation, etc.), or do not want your dataset to be included in this library, please get in touch through a GitHub issue. Thanks for your contribution to the ML community!

Credits

This project was generated from @cjolowicz’s Hypermodern Python Cookiecutter template.

Icons made by Freepik from www.flaticon.com

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

galaxies_datasets-0.1.0.tar.gz (8.7 MB view details)

Uploaded Source

Built Distribution

galaxies_datasets-0.1.0-py3-none-any.whl (8.7 MB view details)

Uploaded Python 3

File details

Details for the file galaxies_datasets-0.1.0.tar.gz.

File metadata

  • Download URL: galaxies_datasets-0.1.0.tar.gz
  • Upload date:
  • Size: 8.7 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for galaxies_datasets-0.1.0.tar.gz
Algorithm Hash digest
SHA256 68a5a06660c01f784af1ee01a2cf7c919e9e13eef51021336fc54832ae8ca90c
MD5 77501ad5c4b5fb6850b07c43b85a36e8
BLAKE2b-256 030787df589d562963d827cf58b4cb37f06f248671a9cb7784df7c60ddc6ee5a

See more details on using hashes here.

File details

Details for the file galaxies_datasets-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: galaxies_datasets-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 8.7 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for galaxies_datasets-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8a1b2ddd2e62ac57922a99ef8d3dd032de81391e6b82d38084b6ce8bde31ab16
MD5 c1f31dc4ca8c97e075bf811ccd03a2cf
BLAKE2b-256 5024b1a6438ec7b1fd2507fc506a24c1103035760dba8099697d07c86085251e

See more details on using hashes here.

Supported by

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