Skip to content

[WIP] Add pyproject.toml and CI workflow configuration#1

Merged
PhD-Brown merged 1 commit into
mainfrom
copilot/add-pyproject-and-ci-workflow
May 8, 2026
Merged

[WIP] Add pyproject.toml and CI workflow configuration#1
PhD-Brown merged 1 commit into
mainfrom
copilot/add-pyproject-and-ci-workflow

Conversation

Copilot AI commented May 8, 2026

Copy link
Copy Markdown

Thanks for asking me to work on this. I will get started on it and keep this PR's description up to date as I form a plan and make progress.

Original prompt

AstroVision is a deep learning pipeline for morphological galaxy classification
using PyTorch. The project is already structured as follows:

src/astrovision/

  • data_loader.py (Galaxy10 DECaLS HDF5 loader, PyTorch Dataset)
  • models.py (SimpleCNN from scratch + EfficientNet-B0 fine-tuning)
  • trainer.py (training loop with W&B tracking)
  • gradcam.py (Grad-CAM visualization)
    notebooks/
  • 01_galaxy10_cnn.ipynb
    requirements.txt (torch, torchvision, h5py, wandb, scikit-learn, matplotlib)

DO NOT regenerate these files. Instead, please generate only:

  1. pyproject.toml with project metadata (name=astrovision, python>=3.11,
    all deps from requirements.txt, setuptools build backend)

  2. .github/workflows/ci.yml — GitHub Actions workflow that:

    • Triggers on push to main and pull requests
    • Runs on ubuntu-latest with Python 3.11
    • Installs dependencies with pip
    • Runs pytest on tests/ directory
    • Lints with ruff
  3. tests/test_models.py — pytest unit tests that verify:

    • SimpleCNN forward pass produces correct output shape (B, 10)
    • EfficientNetGalaxy forward pass produces correct output shape (B, 10)
    • build_model factory raises ValueError on unknown model name
    • GradCAM instantiates without errors
  4. tests/test_data_loader.py — pytest unit tests that:

    • Mock the HDF5 file and verify Galaxy10Dataset len and getitem
    • Verify get_transforms returns correct Compose objects for train/val
  5. ruff.toml — ruff linter config (line-length=100, target Python 3.11)

@PhD-Brown PhD-Brown marked this pull request as ready for review May 8, 2026 16:15
Copilot AI review requested due to automatic review settings May 8, 2026 16:15

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@PhD-Brown PhD-Brown merged commit 34261ed into main May 8, 2026
1 check failed
@PhD-Brown PhD-Brown deleted the copilot/add-pyproject-and-ci-workflow branch May 8, 2026 16:16
Copilot AI requested a review from PhD-Brown May 8, 2026 16:16
Copilot stopped work on behalf of PhD-Brown due to an error May 8, 2026 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants