# mthogeon0731/cvd-reconstruction architecture

> Architecture diagram of the GitHub repository mthogeon0731/cvd-reconstruction, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-10). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/mthogeon0731/cvd-reconstruction
- Repository: https://github.com/mthogeon0731/cvd-reconstruction

## Overview

cvd-reconstruction is a research workflow for estimating coating thickness and trench step coverage by combining physical calibration, registered optical metrology, condition-held-out regression, theory comparisons, and uncertainty analysis. The principal user workflow starts the study CLI, which coordinates synthetic-input generation and analysis; individual modules also support separate stages. The README documents these capabilities, while source excerpts and the index support the implementation links shown. Some unsampled modules are represented by their exact paths, and their internal calls are not inferred beyond indexed references.

Main entry points: [`cvd_cbd/study_cli.py`](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/study_cli.py) (Study CLI), [`cvd_cbd/workflow.py`](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/workflow.py) (Study workflow), [`cvd_cbd/physics.py`](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/physics.py) (Transport physics), [`cvd_cbd/dataset.py`](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/dataset.py) (Feature dataset)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_orchestration["Study orchestration"]
  node_study_cli["Study CLI<br/>[study_cli.py]"]
  node_workflow["Study workflow<br/>[workflow.py]"]
  node_study_config["Study configuration<br/>[study_config.py]"]
  node_synthetic["Synthetic inputs<br/>[synthetic.py]"]
end

subgraph group_physical["Physical model"]
  node_calibration["Physical calibration<br/>[calibration.py]"]
  node_physics["Transport physics<br/>[physics.py]"]
  node_data["Calibration data<br/>[data.py]"]
end

subgraph group_metrology["Data and metrology"]
  node_manifest["Manifest and provenance<br/>[manifest.py]"]
  node_dataset["Feature dataset<br/>[dataset.py]"]
  node_imaging["Image features<br/>[imaging.py]"]
  node_metrology_checks["Image metrology<br/>[metrology.py]"]
  node_input_contracts["Input contracts<br/>[input_contracts.py]"]
end

subgraph group_prediction["Prediction and comparison"]
  node_modeling["Thickness evaluation<br/>[modeling.py]"]
  node_thickness["Thickness modeling<br/>[thickness.py]"]
  node_inference["Step coverage inference<br/>[infer.py]"]
  node_similitude["Theory comparison<br/>[similitude.py]"]
end

subgraph group_analysis["Study analysis"]
  node_uncertainty["Uncertainty propagation<br/>[uncertainty.py]"]
  node_monte_carlo["Monte Carlo tools<br/>[monte_carlo.py]"]
  node_study_design["Study design<br/>[study_design.py]"]
  node_surrogate["Reference surrogate<br/>[surrogate.py]"]
end

node_user(("Research user"))

node_user -->|"runs study"| node_study_cli
node_study_cli -->|"loads settings"| node_study_config
node_study_cli -->|"runs workflow"| node_workflow
node_study_cli -->|"generates inputs"| node_synthetic
node_study_cli -->|"invokes calibration"| node_calibration
node_study_cli -->|"builds features"| node_dataset
node_study_cli -->|"evaluates models"| node_modeling
node_study_cli -->|"derives coverage"| node_inference
node_study_cli -->|"compares theory"| node_similitude
node_study_cli -->|"designs study"| node_study_design
node_study_cli -->|"estimates uncertainty"| node_uncertainty
node_workflow -->|"invokes calibration"| node_calibration
node_workflow -->|"builds features"| node_dataset
node_workflow -->|"evaluates thickness"| node_modeling
node_workflow -->|"derives coverage"| node_inference
node_workflow -->|"compares theory"| node_similitude
node_workflow -->|"builds design"| node_study_design
node_workflow -->|"propagates uncertainty"| node_uncertainty
node_calibration -->|"uses coefficients"| node_physics
node_data -->|"uses configuration"| node_physics
node_dataset -->|"reads provenance"| node_manifest
node_dataset -->|"extracts features"| node_imaging
node_dataset -->|"checks images"| node_metrology_checks
node_imaging -->|"validates inputs"| node_input_contracts
node_manifest -->|"validates evidence"| node_input_contracts
node_modeling -->|"uses thickness tools"| node_thickness
node_similitude -->|"evaluates theory"| node_physics
node_uncertainty -->|"samples parameters"| node_physics
node_uncertainty -->|"propagates coverage"| node_similitude
node_synthetic -->|"creates manifest"| node_manifest
node_synthetic -->|"uses physics"| node_physics
node_study_design -->|"uses theory"| node_physics
node_study_design -->|"uses sampling"| node_monte_carlo
node_study_design -->|"uses process maps"| node_similitude

click node_study_cli "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/study_cli.py"
click node_workflow "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/workflow.py"
click node_study_config "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/study_config.py"
click node_synthetic "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/synthetic.py"
click node_calibration "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/calibration.py"
click node_physics "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/physics.py"
click node_data "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/data.py"
click node_manifest "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/manifest.py"
click node_dataset "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/dataset.py"
click node_imaging "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/imaging.py"
click node_metrology_checks "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/metrology.py"
click node_input_contracts "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/input_contracts.py"
click node_modeling "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/modeling.py"
click node_thickness "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/thickness.py"
click node_inference "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/infer.py"
click node_similitude "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/similitude.py"
click node_uncertainty "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/uncertainty.py"
click node_monte_carlo "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/monte_carlo.py"
click node_study_design "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/study_design.py"
click node_surrogate "https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/surrogate.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_study_cli,node_workflow,node_study_config,node_synthetic,node_user toneBlue
class node_calibration,node_physics,node_data toneAmber
class node_manifest,node_dataset,node_imaging,node_metrology_checks,node_input_contracts toneMint
class node_modeling,node_thickness,node_inference,node_similitude toneRose
class node_uncertainty,node_monte_carlo,node_study_design,node_surrogate toneIndigo
```

## Components

### Study orchestration

- [Study CLI](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/study_cli.py): `cvd_cbd/study_cli.py`
- [Study workflow](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/workflow.py): `cvd_cbd/workflow.py`
- [Study configuration](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/study_config.py): `cvd_cbd/study_config.py`
- [Synthetic inputs](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/synthetic.py): `cvd_cbd/synthetic.py`

### Physical model

- [Physical calibration](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/calibration.py): `cvd_cbd/calibration.py`
- [Transport physics](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/physics.py): `cvd_cbd/physics.py`
- [Calibration data](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/data.py): `cvd_cbd/data.py`

### Data and metrology

- [Manifest and provenance](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/manifest.py): `cvd_cbd/manifest.py`
- [Feature dataset](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/dataset.py): `cvd_cbd/dataset.py`
- [Image features](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/imaging.py): `cvd_cbd/imaging.py`
- [Image metrology](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/metrology.py): `cvd_cbd/metrology.py`
- [Input contracts](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/input_contracts.py): `cvd_cbd/input_contracts.py`

### Prediction and comparison

- [Thickness evaluation](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/modeling.py): `cvd_cbd/modeling.py`
- [Thickness modeling](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/thickness.py): `cvd_cbd/thickness.py`
- [Step coverage inference](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/infer.py): `cvd_cbd/infer.py`
- [Theory comparison](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/similitude.py): `cvd_cbd/similitude.py`

### Study analysis

- [Uncertainty propagation](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/uncertainty.py): `cvd_cbd/uncertainty.py`
- [Monte Carlo tools](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/monte_carlo.py): `cvd_cbd/monte_carlo.py`
- [Study design](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/study_design.py): `cvd_cbd/study_design.py`
- [Reference surrogate](https://github.com/mthogeon0731/cvd-reconstruction/blob/main/cvd_cbd/surrogate.py): `cvd_cbd/surrogate.py`

### Other components

- **Research user**

## Connections

- Research user → Study CLI: runs study (evidence: `README.md`)
- Study CLI → Study configuration: loads settings (evidence: `cvd_cbd/study_cli.py`)
- Study CLI → Study workflow: runs workflow (evidence: `cvd_cbd/study_cli.py`)
- Study CLI → Synthetic inputs: generates inputs (evidence: `cvd_cbd/study_cli.py`)
- Study CLI → Physical calibration: invokes calibration (evidence: `cvd_cbd/study_cli.py`)
- Study CLI → Feature dataset: builds features (evidence: `cvd_cbd/study_cli.py`)
- Study CLI → Thickness evaluation: evaluates models (evidence: `cvd_cbd/study_cli.py`)
- Study CLI → Step coverage inference: derives coverage (evidence: `cvd_cbd/study_cli.py`)
- Study CLI → Theory comparison: compares theory (evidence: `cvd_cbd/study_cli.py`)
- Study CLI → Study design: designs study (evidence: `cvd_cbd/study_cli.py`)
- Study CLI → Uncertainty propagation: estimates uncertainty (evidence: `cvd_cbd/study_cli.py`)
- Study workflow → Physical calibration: invokes calibration (evidence: `cvd_cbd/workflow.py`)
- Study workflow → Feature dataset: builds features (evidence: `cvd_cbd/workflow.py`)
- Study workflow → Thickness evaluation: evaluates thickness (evidence: `cvd_cbd/workflow.py`)
- Study workflow → Step coverage inference: derives coverage (evidence: `cvd_cbd/workflow.py`)
- Study workflow → Theory comparison: compares theory (evidence: `cvd_cbd/workflow.py`)
- Study workflow → Study design: builds design (evidence: `cvd_cbd/workflow.py`)
- Study workflow → Uncertainty propagation: propagates uncertainty (evidence: `cvd_cbd/workflow.py`)
- Physical calibration → Transport physics: uses coefficients (evidence: `cvd_cbd/calibration.py`)
- Calibration data → Transport physics: uses configuration (evidence: `cvd_cbd/data.py`)
- Feature dataset → Manifest and provenance: reads provenance (evidence: `cvd_cbd/dataset.py`)
- Feature dataset → Image features: extracts features (evidence: `cvd_cbd/dataset.py`)
- Feature dataset → Image metrology: checks images (evidence: `cvd_cbd/dataset.py`)
- Image features → Input contracts: validates inputs (evidence: `cvd_cbd/imaging.py`)
- Manifest and provenance → Input contracts: validates evidence (evidence: `cvd_cbd/manifest.py`)
- Thickness evaluation → Thickness modeling: uses thickness tools (evidence: `cvd_cbd/modeling.py`)
- Theory comparison → Transport physics: evaluates theory (evidence: `cvd_cbd/similitude.py`)
- Uncertainty propagation → Transport physics: samples parameters (evidence: `cvd_cbd/uncertainty.py`)
- Uncertainty propagation → Theory comparison: propagates coverage (evidence: `cvd_cbd/uncertainty.py`)
- Synthetic inputs → Manifest and provenance: creates manifest (evidence: `cvd_cbd/synthetic.py`)
- Synthetic inputs → Transport physics: uses physics (evidence: `cvd_cbd/synthetic.py`)
- Study design → Transport physics: uses theory (evidence: `cvd_cbd/study_design.py`)
- Study design → Monte Carlo tools: uses sampling (evidence: `cvd_cbd/study_design.py`)
- Study design → Theory comparison: uses process maps (evidence: `cvd_cbd/study_design.py`)
