# macster9/galaxyclassifier architecture

> Architecture diagram of the GitHub repository macster9/galaxyclassifier, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-07-24). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/macster9/galaxyclassifier
- Repository: https://github.com/macster9/galaxyclassifier

## Overview

##### Project type and purpose
- From the file tree and minimal README (“GalaxyClassifier”), this is a Python-based machine-learning pipeline/tool designed to train, evaluate, and run a classifier on galaxy data. It combines data ingestion, preprocessing, model training/evaluation, and interactive analysis in notebooks.

##### File structure
- Top-level files:
- main.py / run.bat / __install__.bat / __update__.bat – entrypoints and automation scripts
- config.yml – central configuration for paths, parameters, hyperparameters
- requirements.txt – Python dependencies
- data/ – raw and intermediary CSV/GZ data artifacts (train, test, validation, error logs, reference tables)
- scripts/:
- data_pipeline.py – orchestrates ingestion + preprocessing
- training.py – model training and checkpointing
- tools/: reusable modules:
- read.py – data I/O utilities
- utils.py – preprocessing helpers
- network.py – model architecture definitions
- plot.py – visualization routines
- setup.py – environment or dependency setup logic
- notebooks/: Execute.ipynb for exploratory analysis and interactive runs.

##### README for additional insights
- There is no further architectural description beyond the title. We’ll infer typical ML pipeline stages and automation intent from batch scripts.

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% CLI/Automation Layer
    subgraph "CLI/Automation Layer"
        Install["__install__.bat"]:::automation
        Update["__update__.bat"]:::automation
        Run["run.bat"]:::automation
        Main["main.py"]:::automation
    end

    %% Configuration Manager
    subgraph "Configuration Manager"
        ConfigYML["config.yml"]:::config
        Setup["tools/setup.py"]:::config
    end

    %% Data Layer (Ingestion & Storage)
    subgraph "Data Layer (Ingestion & Storage)"
        DataDir["data/"]:::data
        DataPipeline["scripts/data_pipeline.py"]:::data
        Read["tools/read.py"]:::data
    end

    %% Preprocessing & Feature Engineering
    subgraph "Preprocessing & Feature Engineering"
        Utils["tools/utils.py"]:::process
    end

    %% Model Layer (Training & Architecture)
    subgraph "Model Layer (Training & Architecture)"
        Training["scripts/training.py"]:::model
        Network["tools/network.py"]:::model
    end

    %% Evaluation & Visualization
    subgraph "Evaluation & Visualization"
        Plot["tools/plot.py"]:::viz
    end

    %% Interactive Analysis
    subgraph "Interactive Analysis"
        Notebook["notebooks/Execute.ipynb"]:::viz
    end

    %% External Dependencies
    subgraph "External Dependencies"
        Requirements["requirements.txt"]:::external
        Readme["README.md"]:::external
    end

    %% Data Flows
    Install -->|invokes| Main
    Update -->|updates| Main
    Run -->|runs| Main
    Main -->|loads config| ConfigYML
    Main -->|calls setup| Setup
    Main -->|triggers| DataPipeline
    ConfigYML -->|provides parameters| DataPipeline
    DataPipeline -->|reads raw data| Read
    Read -->|fetches files| DataDir
    DataPipeline -->|calls| Utils
    Utils -->|returns cleaned data| DataPipeline
    DataPipeline -->|outputs cleaned data| Training
    Training -->|builds model with| Network
    Training -->|produces model artifacts| DataDir
    Training -->|calls| Plot
    Plot -->|generates visualizations| DataDir
    Plot -->|can be viewed in| Notebook
    Requirements -->|defines deps for| Main
    Readme -->|documents| Main

    %% Click Events
    click Install "https://github.com/macster9/galaxyclassifier/blob/main/__install__.bat"
    click Update "https://github.com/macster9/galaxyclassifier/blob/main/__update__.bat"
    click Run "https://github.com/macster9/galaxyclassifier/blob/main/run.bat"
    click Main "https://github.com/macster9/galaxyclassifier/blob/main/main.py"
    click ConfigYML "https://github.com/macster9/galaxyclassifier/blob/main/config.yml"
    click Setup "https://github.com/macster9/galaxyclassifier/blob/main/tools/setup.py"
    click DataDir "https://github.com/macster9/galaxyclassifier/tree/main/data/"
    click DataPipeline "https://github.com/macster9/galaxyclassifier/blob/main/scripts/data_pipeline.py"
    click Read "https://github.com/macster9/galaxyclassifier/blob/main/tools/read.py"
    click Utils "https://github.com/macster9/galaxyclassifier/blob/main/tools/utils.py"
    click Training "https://github.com/macster9/galaxyclassifier/blob/main/scripts/training.py"
    click Network "https://github.com/macster9/galaxyclassifier/blob/main/tools/network.py"
    click Plot "https://github.com/macster9/galaxyclassifier/blob/main/tools/plot.py"
    click Notebook "https://github.com/macster9/galaxyclassifier/blob/main/notebooks/Execute.ipynb"
    click Requirements "https://github.com/macster9/galaxyclassifier/blob/main/requirements.txt"
    click Readme "https://github.com/macster9/galaxyclassifier/blob/main/README.md"

    %% Styles
    classDef automation fill:#d3d3d3,stroke:#333,stroke-width:1px
    classDef config fill:#c0c0c0,stroke:#333,stroke-width:1px
    classDef data fill:#aed6f1,stroke:#333,stroke-width:1px
    classDef process fill:#a9dfbf,stroke:#333,stroke-width:1px
    classDef model fill:#f5b041,stroke:#333,stroke-width:1px
    classDef viz fill:#d7bde2,stroke:#333,stroke-width:1px
    classDef external fill:#f9e79f,stroke:#333,stroke-width:1px
```
