# arcc-race/deepracer-for-dummies architecture

> Architecture diagram of the GitHub repository arcc-race/deepracer-for-dummies, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-01-06). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/arcc-race/deepracer-for-dummies
- Repository: https://github.com/arcc-race/deepracer-for-dummies

## Overview

##### Project Type Analysis
This is a specialized development environment project that creates a local training system for AWS DeepRacer using Docker containers. It includes a GUI wrapper and various automation scripts.

##### Main Components

A. Core Components:
- GUI Interface (Qt-based)
- Docker Container Orchestration Layer
- Training Environment
- Evaluation Environment
- Log Analysis System
- Storage Layer (Minio)

B. External Dependencies:
- AWS Services Integration
- Nvidia GPU Integration
- VNC Viewer Connection

##### User Interaction Layer
- VNC Viewer connection for visualization
- Command-line interface for scripts

##### Orchestration Layer
- Docker Compose management
- Container orchestration
- Resource management (memory-manager.py)

##### Core Processing Layer
- Training container
- Robomaker simulation container
- Coach container for reinforcement learning
- Sagemaker training environment

##### Storage Layer
- Minio bucket for model storage
- Local filesystem for logs and snapshots
- AWS S3 integration for model upload

Use the following visual elements:

- Containers: Use rectangles with rounded corners for Docker containers
- External Systems: Use clouds or hexagons for AWS services
- Blue: Core services
- Green: User interfaces
- Yellow: Storage systems
- Red: External dependencies

Special Considerations:

##### Relationship between components
- GUI → Docker Compose → Training Environment
- Training Environment ↔ Minio Storage
- Log Analysis ← Robomaker Logs
- Training Environment ↔ GPU Resources

##### Configuration points
- .env file configuration
- AWS credentials integration
- Nvidia Docker runtime
- Hyperparameter configuration

##### Three main operational modes
- Training workflow
- Evaluation workflow
- Log analysis workflow

## Diagram (Mermaid)

```mermaid
graph TB
    subgraph "User Interaction Layer"
        GUI["GUI Interface"]
        CLI["Command Line Interface"]
        VNC["VNC Viewer"]
    end

    subgraph "Orchestration Layer"
        DOCKER["Docker Compose"]
        MEM["Memory Manager"]
        INIT["Initialization Script"]
    end

    subgraph "Core Processing Layer"
        TRAIN["Training Container"]
        ROBO["Robomaker Simulation"]
        COACH["RL Coach Container"]
        SAGE["Sagemaker Environment"]
    end

    subgraph "Storage Layer"
        MINIO["Minio Storage"]
        LOCAL["Local Filesystem"]
        S3["AWS S3"]
    end

    %% Relationships
    GUI --> DOCKER
    CLI --> DOCKER
    VNC --> ROBO
    DOCKER --> TRAIN
    DOCKER --> ROBO
    DOCKER --> COACH
    DOCKER --> SAGE
    MEM --> DOCKER
    INIT --> DOCKER
    TRAIN <--> MINIO
    ROBO --> LOCAL
    MINIO <--> S3

    %% Styling
    classDef ui fill:#90EE90
    classDef orchestration fill:#ADD8E6
    classDef processing fill:#FFB6C1
    classDef storage fill:#FFD700
    
    class GUI,CLI,VNC ui
    class DOCKER,MEM,INIT orchestration
    class TRAIN,ROBO,COACH,SAGE processing
    class MINIO,LOCAL,S3 storage

    %% Click Events
    click GUI "https://github.com/ARCC-RACE/deepracer-for-dummies/tree/master/gui"
    click DOCKER "https://github.com/ARCC-RACE/deepracer-for-dummies/blob/master/docker/docker-compose.yml"
    click MEM "https://github.com/ARCC-RACE/deepracer-for-dummies/blob/master/scripts/training/memory-manager.py"
    click INIT "https://github.com/ARCC-RACE/deepracer-for-dummies/blob/master/init.sh"
    click TRAIN "https://github.com/ARCC-RACE/deepracer-for-dummies/blob/master/scripts/training/start.sh"
    click COACH "https://github.com/ARCC-RACE/deepracer-for-dummies/tree/master/docker/dockerfiles/rl_coach/Dockerfile"
    click MINIO "https://github.com/ARCC-RACE/deepracer-for-dummies/blob/master/docker/.env"

    %% Legend
    subgraph Legend
        UI["User Interface"]:::ui
        ORCH["Orchestration"]:::orchestration
        PROC["Processing"]:::processing
        STOR["Storage"]:::storage
    end
```
