# wisdem/ard architecture

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

- Interactive diagram: https://gitdiagram.com/wisdem/ard
- Repository: https://github.com/wisdem/ard

## Overview

##### Project type and purpose
- Ard is a modular, full-stack, multidisciplinary optimization toolkit for wind farm design.
- It combines layout generation, aerodynamic analysis (via FLORIS), cost modeling (via WISDEM wraps), and LCOE finance estimation into a single pipeline, supporting both one-off analyses and optimization loops.

##### File structure analysis
Top-level directories and key files:
- ard/           → core Python package
– cost/            : wraps WISDEM cost components
– farm_aero/       : wraps FLORIS for aerodynamic AEP estimation
– layout/          : layout templates and layout-generation logic
– offshore/        : Jupyter sandbox for mooring constraints
– glue/            : prototype harnesses or orchestration code
– viz/             : plotting utilities for layouts
– wind_query.py    : wind-resource data access
– utils.py, test_utils.py : shared helpers
- examples/      → end-user demonstration scripts & notebooks
- assets/        → static assets (e.g. XDSM PDF)
- test/          → unit and system tests, CI scripts
- .github/       → CI/CD workflows (linting, unit/system tests, deploy pages)
- pyproject.toml → build and dependency configuration

##### README insights
- Focus: LCOE-stack demonstration (`examples/LCOE_stack`) integrating layout → AEP → cost → finance.
- Emphasis on modularity, test coverage, and future extensibility for discipline-specific research.
- Key external dependencies: FLORIS, WISDEM components.

## Diagram (Mermaid)

```mermaid
flowchart TD
    subgraph "Entry Points"
        EX_LCOE["LCOE Finance Stack Example"]:::examples
        EX_POWER["FLORIS Power Comparison Example"]:::examples
        EX_OFFSHORE["Offshore Mooring Sandbox"]:::examples
        GLUE["Glue Orchestration (prototype.py)"]:::core
    end

    subgraph "Core Modules"
        LAYOUT["Layout Module"]:::core
        AERO["Farm Aero Module (FLORIS)"]:::core
        COST["Cost Module (WISDEM Wrap)"]:::core
        VIZ["Visualization Module"]:::core
        UTILS["Utilities"]:::core
    end

    subgraph "External Dependencies"
        FLORIS_LIB["FLORIS Library"]:::external
        WISDEM_LIB["WISDEM Components"]:::external
    end

    subgraph "Documentation & Assets"
        DOCS["Documentation & Tutorials"]:::docs
        ASSETS["XDSM Diagram Assets"]:::docs
    end

    subgraph "CI/CD & Configuration"
        WORKFLOWS["GitHub Workflows"]:::ci
        CONFIG["pyproject.toml"]:::ci
    end

    EX_LCOE --> LAYOUT
    EX_LCOE --> AERO
    EX_LCOE --> COST
    EX_POWER --> AERO
    EX_POWER --> COST
    EX_OFFSHORE --> LAYOUT
    GLUE --> LAYOUT
    GLUE --> AERO
    GLUE --> COST

    LAYOUT --> AERO
    AERO --> COST
    COST --> EX_LCOE
    COST --> VIZ
    LAYOUT --> VIZ

    FLORIS_LIB -.-> AERO
    WISDEM_LIB -.-> COST

    DOCS --> EX_LCOE
    ASSETS --> DOCS

    CONFIG --> WORKFLOWS

    classDef core fill:#ADD8E6,stroke:#000,stroke-width:1px
    classDef external fill:#D3D3D3,stroke:#000,stroke-width:1px
    classDef ci fill:#FFA500,stroke:#000,stroke-width:1px
    classDef docs fill:#90EE90,stroke:#000,stroke-width:1px
    classDef examples fill:#98FB98,stroke:#000,stroke-width:1px

    click LAYOUT "https://github.com/wisdem/ard/tree/main/ard/layout/"
    click AERO "https://github.com/wisdem/ard/tree/main/ard/farm_aero/"
    click COST "https://github.com/wisdem/ard/blob/main/ard/cost/wisdem_wrap.py"
    click VIZ "https://github.com/wisdem/ard/blob/main/ard/viz/plot_layout.py"
    click UTILS "https://github.com/wisdem/ard/blob/main/ard/utils.py"
    click GLUE "https://github.com/wisdem/ard/blob/main/ard/glue/prototype.py"
    click EX_LCOE "https://github.com/wisdem/ard/tree/main/examples/LCOE_stack/"
    click EX_POWER "https://github.com/wisdem/ard/tree/main/examples/FLORIS_power_comp/"
    click EX_OFFSHORE "https://github.com/wisdem/ard/blob/main/ard/offshore/mooring_constraint_sandbox.ipynb"
    click DOCS "https://github.com/wisdem/ard/tree/main/docs/"
    click ASSETS "https://github.com/wisdem/ard/tree/main/assets/ard_xdsm/"
    click WORKFLOWS "https://github.com/wisdem/ard/tree/main/.github/workflows/"
    click CONFIG "https://github.com/wisdem/ard/blob/main/pyproject.toml"
```
