# ghaniketrajputp005/adobe-gensolve-hackathon-2024 architecture

> Architecture diagram of the GitHub repository ghaniketrajputp005/adobe-gensolve-hackathon-2024, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-06-22). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024
- Repository: https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024

## Overview

##### Project Type and Purpose
- It includes dataset generation, model training, evaluation, and model artifact storage.

##### File Structure
- Top-level directories and files:
- “problems/”: CSV files with doodle fragments (raw input data).
- “src/”: Python scripts for dataset generation (`generate_dataset.py`), model creation (`model_creation_d.py`, `model_creation_dc.py`), and testing (`test_model_d.py`, `test_model_dc.py`).
- “CURVES_MODELS/”: pre-trained `.h5` model artifacts.
- “INSTRUCTIONS/”: documentation (PDF).
- `requirements.txt` / `setup.py`: dependency definitions.
- Virtual-environment implied by README (venv).
- Cloud integration mention—presumed storage bucket or object store for model artifacts.

##### README
- Dependencies managed via `requirements.txt`.
- Cloud storage used to persist trained models.

##### Main Components and Their Interactions
a. Data Ingestion Component
- Source: CSV files in “problems/”
- Responsible for reading raw doodle fragments.
b. Dataset Generation Component
- Script: `src/generate_dataset.py`
- Processes CSVs → cleans, augments, and outputs training/validation datasets.
c. Model Training Component
- Scripts: `model_creation_d.py` (simple model), `model_creation_dc.py` (complex model)
- Inputs: processed datasets → output: `.h5` model files.
d. Model Evaluation Component
- Scripts: `test_model_d.py`, `test_model_dc.py`
- Runs on validation/test splits → produces accuracy reports.
e. Artifact Storage Component
- Local: “CURVES_MODELS/”
- Remote: Cloud storage (e.g., AWS S3, GCP Storage) for model persistence.
f. Development Environment
- Virtual environment (venv), dependencies via `requirements.txt`.
g. Documentation
- “INSTRUCTIONS/Curvetopia1-compressed…pdf”

##### Architectural Patterns and Design Principles
- Pipeline pattern: chaining together data ingestion → preprocessing → training → evaluation → storage.
- Separation of concerns: one script per pipeline stage.
- Reproducibility: dependency isolation (venv) + `requirements.txt`.
- Artifact versioning: distinct `.h5` model files.

##### Technologies and Frameworks
- Python 3.x
- ML libraries (TensorFlow / Keras implied by `.h5` models)
- CSV processing (pandas or built-in)
- Cloud SDK (e.g., `boto3` or `google-cloud-storage`) for model upload (per README “Cloud Integration”).

##### Essential Elements Checklist
– [ ] Script/process names and locations
– [ ] Data sources and formats
– [ ] Output artifacts and storage targets
– [ ] Dependency/environment boundary

## Diagram (Mermaid)

```mermaid
flowchart TD
    DataIngestion["Raw Data (problems/*.csv)"]:::data
    DatasetGen["Dataset Generator (generate_dataset.py)"]:::compute
    SimpleTrainer["Simple Model Trainer (model_creation_d.py)"]:::compute
    ComplexTrainer["Complex Model Trainer (model_creation_dc.py)"]:::compute
    SimpleEval["Simple Model Evaluation (test_model_d.py)"]:::compute
    ComplexEval["Complex Model Evaluation (test_model_dc.py)"]:::compute
    LocalStorage["Local Artifact Storage (CURVES_MODELS/)"]:::storage
    CloudStorage["Cloud Artifact Storage"]:::storage

    subgraph "Development Environment"
        style Development Environment stroke:#666,stroke-width:2px,stroke-dasharray: 5 5
        Req["requirements.txt"]:::dev
        Setup["setup.py"]:::dev
        DocPDF["Curvetopia Documentation (PDF)"]:::doc
        Readme["README.md"]:::doc
    end

    DataIngestion -->|reads CSVs| DatasetGen
    DatasetGen -->|processed data| SimpleTrainer
    DatasetGen -->|processed data| ComplexTrainer
    SimpleTrainer -->|model.h5| SimpleEval
    ComplexTrainer -->|model.h5| ComplexEval
    SimpleEval -->|evaluation results| LocalStorage
    ComplexEval -->|evaluation results| LocalStorage
    SimpleEval -->|evaluation results| CloudStorage
    ComplexEval -->|evaluation results| CloudStorage

    click DataIngestion "https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024/tree/main/problems/"
    click DatasetGen "https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024/blob/main/src/generate_dataset.py"
    click SimpleTrainer "https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024/blob/main/src/model_creation_d.py"
    click ComplexTrainer "https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024/blob/main/src/model_creation_dc.py"
    click SimpleEval "https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024/blob/main/src/test_model_d.py"
    click ComplexEval "https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024/blob/main/src/test_model_dc.py"
    click LocalStorage "https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024/tree/main/CURVES_MODELS/"
    click Req "https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024/blob/main/requirements.txt"
    click Setup "https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024/blob/main/setup.py"
    click DocPDF "https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024/blob/main/INSTRUCTIONS/Curvetopia1-compressed-20240725163225.pdf"
    click Readme "https://github.com/ghaniketrajputp005/adobe-gensolve-hackathon-2024/blob/main/README.md"

    classDef data fill:#ADD8E6,stroke:#333,stroke-width:1px
    classDef compute fill:#90EE90,stroke:#333,stroke-width:1px
    classDef storage fill:#FFA500,stroke:#333,stroke-width:1px
    classDef dev fill:#D3D3D3,stroke:#333,stroke-width:1px
    classDef doc fill:#D3D3D3,stroke:#333,stroke-width:1px
```
