Datasets:
Galaxy Zoo 2 - Preprocessed Dataset
Preprocessed galaxy images from SDSS with Galaxy Zoo 2 morphological classifications, ready for deep learning.
π Dataset Structure
βββ labels.csv # All ~239K galaxy labels (101 MB)
βββ labels_sampled.csv # 25K stratified sample (11 MB)
βββ preprocessed_69x69.zip # Full dataset at 69Γ69 resolution (2.8 GB)
βββ preprocessed_224x224.zip # Full dataset at 224Γ224 resolution (3.14 GB)
βββ sample_preprocessed_69x69.zip # Sample subset at 69Γ69 resolution (308 MB)
βββ zoobot_dataset_224.zip # Zoobot-compatible format at 224Γ224 (1.94 GB)
πΌοΈ Available Image Versions
| File | Resolution | Size | Best For |
|---|---|---|---|
preprocessed_69x69.zip |
69Γ69 | 2.8 GB | Reproducing Dieleman et al. (2015) baseline |
sample_preprocessed_69x69.zip |
69Γ69 | 308 MB | Quick experiments, prototyping |
preprocessed_224x224.zip |
224Γ224 | 3.14 GB | Modern architectures (ResNet, EfficientNet, ViT) |
zoobot_dataset_224.zip |
224Γ224 | 1.94 GB | Fine-tuning with Zoobot pretrained weights |
πΌοΈ Image Format
- Format: Compressed NumPy arrays (
.npz) - Shape:
(H, W, 3)β RGB - Type:
float32, range[0, 1] - Source: SDSS DR19
Load with:
import numpy as np
img = np.load('file.npz')['image']
π·οΈ Labels
37 morphological probability distributions from Galaxy Zoo 2:
- Smooth vs. Featured
- Spiral arms
- Edge-on orientation
- Bars, bulges, mergers
- And more...
All labels are debiased probabilities accounting for volunteer expertise and question tree structure.
labels.csv covers the full ~239K dataset. labels_sampled.csv is a 25K stratified sample maintaining morphological diversity (minimum 2,000 images per category: Smooth, Spiral, Edge-on, Featured, Artifact, Uncertain).
π¬ Preprocessing Pipelines
Each dataset version was preprocessed differently. Choose the version matching your use case.
preprocessed_69x69.zip / sample_preprocessed_69x69.zip
*Reproduces Dieleman et al. (2015)
SDSS API
βββ Download 424Γ424 JPEG cutout (RA/Dec centered, scale=0.396 arcsec/px)
βββ Center crop β 207Γ207 (removes ~108px from each edge)
βββ Lanczos downsample β 69Γ69
βββ Normalize to [0, 1] (Γ· 255, float32)
βββ Save as .npz
preprocessed_224x224.zip
*Larger resolution for modern architectures
SDSS API
βββ Download 424Γ424 JPEG cutout (RA/Dec centered, scale=0.396 arcsec/px)
βββ Center crop β 380Γ380 (removes ~22px from each edge)
βββ Lanczos downsample β 224Γ224
βββ Normalize to [0, 1] at training time (Γ· 255, NOT ImageNet mean/std)
βββ Save as .jpg (quality=95)
Note: normalization is not applied during preprocessing β divide by 255 at training time. Images are saved as JPG (not NPZ) to save disk space (~7 GB vs ~36 GB).
zoobot_dataset_224.zip
*Scale-invariant crop for Zoobot fine-tuning
SDSS API
βββ Download 424Γ424 JPEG cutout
βββ Lookup Petrosian radius R90 from gz2_complete.csv (SDSS petroR90_r column)
βββ Scale-invariant crop: crop_size = int((R90 / 0.396) Γ 3.5)
clamped to [64px, min(image dims)]
centered on image center (x = w//2, y = h//2)
βββ Resize β 224Γ224
INTER_AREA if crop > 224 (downscaling)
INTER_CUBIC if crop < 224 (upscaling)
βββ Save as .jpg
β Crop size adapts to each galaxy's physical extent β larger galaxies get a larger crop, preserving spiral arms and outer structure. Galaxies without a matching R90 entry are skipped.
β FAQ
Q: Which version should I download?
- Prototyping / quick experiments:
sample_preprocessed_69x69.zip(308 MB, ~25K images) - Reproducing Dieleman et al. (2015):
preprocessed_69x69.zip(full 69Γ69 dataset) - Modern CNN architectures (ResNet, ConvNeXt, EfficientNet):
preprocessed_224x224.zip - Zoobot fine-tuning:
zoobot_dataset_224.zip
Q: What format are the images?
Compressed NumPy arrays (.npz). Load with np.load('file.npz')['image'].
Q: Are images augmented? No. Apply rotation, flipping, and scaling during training for best results.
Q: Why both 69Γ69 and 224Γ224? 69Γ69 follows Dieleman et al. (2015). 224Γ224 is the standard input size for modern pretrained architectures like ResNet, EfficientNet, ConvNeXt, and Zoobot.
π Citation
@article{willett2013galaxy,
title={Galaxy Zoo 2: detailed morphological classifications for 304,122 galaxies from the Sloan Digital Sky Survey},
author={Willett, Kyle W and others},
journal={Monthly Notices of the Royal Astronomical Society},
volume={435},
number={4},
pages={2835--2860},
year={2013}
}
π License
- Images: Public domain (SDSS)
- Labels: ODC-By (Galaxy Zoo 2)
π Links
Credits
Original Data: Galaxy Zoo 2 Team, SDSS Collaboration, 300,000+ volunteers
- Downloads last month
- 32