Skip to content

Repository files navigation

Deep Learning Systems Project — Galaxy Morphology CNN

Project Description

This project implements and evaluates a convolutional neural network (CNN) for galaxy morphology classification using the Galaxy10 DECaLS dataset. The workflow demonstrates a complete deep learning experiment pipeline: dataset ingestion, preprocessing, model training, controlled architectural comparison, and performance evaluation.

The goal is not maximum accuracy, but a reproducible experimental workflow that highlights how architectural decisions influence generalization in deep learning systems. The project serves as a prototype for autonomous visual recognition in aerospace and astronomical monitoring contexts.

Dataset used: Galaxy10 DECaLS
https://www.kaggle.com/datasets/younghodaimma/galaxy10-decals


What I Built

I implemented a full deep learning experiment pipeline that includes:

  • Automated dataset download from Kaggle
  • Image preprocessing and stratified train/validation/test splits
  • A baseline convolutional neural network
  • A controlled architectural experiment (Batch Normalization)
  • Training loops with tracked loss and accuracy
  • Test evaluation with confusion matrices and classification metrics
  • Visualization of misclassified examples
  • A notebook that runs top-to-bottom reproducibly

The experiment demonstrates how small architectural changes can significantly alter model behavior.


How to Run deep_learning.ipynb

Install dependencies

pip install -r requirements.txt

The requirements file was generated using:

pip freeze > requirements.txt

Kaggle dataset access

This notebook downloads the dataset automatically.

  1. Create a free Kaggle account
  2. Go to Kaggle → Account → Create API Token
  3. Copy your username and key into the credential cell in the notebook
  4. Run the authentication cell
  5. Run the dataset download cell

No manual file downloads are required.

Run the notebook

  • Clone or download this repository
  • Open deep_learning.ipynb in Jupyter or Google Colab
  • Run all cells from top to bottom

The notebook executes without hidden state and reproduces the full experiment.


Reproducibility

This project emphasizes reproducible deep learning experiments:

  • The notebook runs top-to-bottom without manual intervention
  • Dataset access is automated via Kaggle API
  • All splits are deterministic with fixed random seeds
  • Training loops are fully defined in code
  • A requirements file captures the environment

Another user can recreate the experiment using only the repository contents.


Experimental Design

The experiment compares two architectures:

  • Baseline CNN: 3 convolutional blocks + classifier
  • Experimental CNN: identical architecture with Batch Normalization

All other conditions (optimizer, learning rate, batch size, epochs, dataset splits) are held constant. This ensures a controlled comparison focused on architectural impact.

The results demonstrate how architectural changes can produce underfitting and class collapse rather than improvement.


Bias Awareness

Astronomical datasets reflect human classification and sampling processes. Galaxy morphology labels may contain annotation noise, class imbalance, or observational bias. A model that collapses onto dominant classes can distort scientific interpretation of galaxy populations.

Careful evaluation and transparent reporting are essential when applying AI to scientific data.


Reflection: Deep Learning Workflow

If extended into a production ML pipeline, this workflow could include:

  • Data augmentation for improved generalization
  • Longer training schedules and learning rate tuning
  • Class weighting or resampling strategies
  • Larger or semi-supervised datasets
  • Modern architectures (e.g., residual networks)

The current project prioritizes experimental clarity over state-of-the-art performance.


Reflection: Scientific AI Systems

This experiment highlights a core principle of deep learning systems:

Architectural techniques do not guarantee improvement. Controlled experiments are required to validate assumptions about performance, stability, and bias.

Such workflows are essential in aerospace and scientific AI systems where reliability matters more than raw accuracy.


Repository Structure

📓 deep_learning.ipynb 📄 Deep_Learning_Systems_Analysis_Report.pdf 📄 requirements.txt 📘 README.md

This repository demonstrates a reproducible deep learning experiment suitable for academic review and professional portfolio use.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages