# lavishlohiya/avaranx-h2s architecture

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

- Interactive diagram: https://gitdiagram.com/lavishlohiya/avaranx-h2s
- Repository: https://github.com/lavishlohiya/avaranx-h2s

## Overview

This repository is a LAMMPS-based H₂S dosimeter-material comparison workflow. Its main path generates atomic systems for four metal oxides, runs molecular-dynamics inputs, then compares adsorption behavior and visualizes results. The runner coordinates these stages; analysis also offers demonstration plots and OVITO modes. Generator and runner behavior is visible in sampled source, while some LAMMPS input details are unsampled, so the graph omits uncertain simulation internals.

Main entry points: [`run_all.py`](https://github.com/lavishlohiya/avaranx-h2s/blob/main/run_all.py) (Pipeline runner), [`ovito_analysis.py`](https://github.com/lavishlohiya/avaranx-h2s/blob/main/ovito_analysis.py) (Analysis and visualization), [`generate_cuo_h2s_system.py`](https://github.com/lavishlohiya/avaranx-h2s/blob/main/generate_cuo_h2s_system.py) (CuO generator), [`generate_zno_h2s_system.py`](https://github.com/lavishlohiya/avaranx-h2s/blob/main/generate_zno_h2s_system.py) (ZnO generator)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_setup["System generation"]
  node_cuo_gen["CuO generator"]
  node_zno_gen["ZnO generator"]
  node_pbo_gen["PbO generator"]
  node_bi_gen["Bi₂O₃ generator"]
  node_cuo_data["CuO system data"]
  node_zno_data["ZnO system data"]
  node_pbo_data["PbO system data"]
  node_bi_data["Bi₂O₃ system data"]
end

subgraph group_simulation["LAMMPS simulations"]
  node_lammps["LAMMPS engine"]
  node_cuo_in["CuO simulation input<br/>[h2s_cuo_reaxff.in]"]
  node_zno_in["ZnO simulation input<br/>[h2s_zno.in]"]
  node_pbo_in["PbO simulation input<br/>[h2s_pbo.in]"]
  node_bi_in["Bi₂O₃ simulation input<br/>[h2s_bi2o3.in]"]
  node_sim_outputs["Simulation outputs"]
  node_log["LAMMPS log<br/>[log.lammps]"]
end

subgraph group_workflow["Workflow control"]
  node_runner["Pipeline runner<br/>[run_all.py]"]
end

subgraph group_analysis["Analysis and visualization"]
  node_analysis["Analysis and visualization<br/>[ovito_analysis.py]"]
  node_plots["Comparison plots"]
  node_ovito["OVITO tools"]
end

node_user(("Engineer"))

node_user -->|"starts workflow"| node_runner
node_user -->|"runs analysis"| node_analysis
node_runner -->|"runs generator"| node_cuo_gen
node_runner -->|"runs generator"| node_zno_gen
node_runner -->|"runs generator"| node_pbo_gen
node_runner -->|"runs generator"| node_bi_gen
node_cuo_gen -->|"writes data"| node_cuo_data
node_zno_gen -->|"writes data"| node_zno_data
node_pbo_gen -->|"writes data"| node_pbo_data
node_bi_gen -->|"writes data"| node_bi_data
node_runner -->|"launches simulations"| node_lammps
node_lammps -->|"runs input"| node_cuo_in
node_lammps -->|"runs input"| node_zno_in
node_lammps -->|"runs input"| node_pbo_in
node_lammps -->|"runs input"| node_bi_in
node_cuo_in -->|"uses system data"| node_cuo_data
node_zno_in -->|"uses system data"| node_zno_data
node_pbo_in -->|"uses system data"| node_pbo_data
node_bi_in -->|"uses system data"| node_bi_data
node_lammps -->|"writes results"| node_sim_outputs
node_lammps -->|"writes log"| node_log
node_runner -->|"runs matplotlib mode"| node_analysis
node_analysis -->|"reads simulation results"| node_sim_outputs
node_analysis -->|"generates plots"| node_plots
node_analysis -.->|"offers API mode"| node_ovito

click node_runner "https://github.com/lavishlohiya/avaranx-h2s/blob/main/run_all.py"
click node_cuo_gen "https://github.com/lavishlohiya/avaranx-h2s/blob/main/generate_cuo_h2s_system.py"
click node_zno_gen "https://github.com/lavishlohiya/avaranx-h2s/blob/main/generate_zno_h2s_system.py"
click node_pbo_gen "https://github.com/lavishlohiya/avaranx-h2s/blob/main/generate_pbo_h2s_system.py"
click node_bi_gen "https://github.com/lavishlohiya/avaranx-h2s/blob/main/generate_bi2o3_h2s_system.py"
click node_cuo_data "https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_cuo_system.data"
click node_zno_data "https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_zno_system.data"
click node_pbo_data "https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_pbo_system.data"
click node_bi_data "https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_bi2o3_system.data"
click node_cuo_in "https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_cuo_reaxff.in"
click node_zno_in "https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_zno.in"
click node_pbo_in "https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_pbo.in"
click node_bi_in "https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_bi2o3.in"
click node_analysis "https://github.com/lavishlohiya/avaranx-h2s/blob/main/ovito_analysis.py"
click node_log "https://github.com/lavishlohiya/avaranx-h2s/blob/main/log.lammps"

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_cuo_gen,node_zno_gen,node_pbo_gen,node_bi_gen,node_cuo_data,node_zno_data,node_pbo_data,node_bi_data toneBlue
class node_lammps,node_cuo_in,node_zno_in,node_pbo_in,node_bi_in,node_sim_outputs,node_log toneAmber
class node_runner toneMint
class node_analysis,node_plots,node_ovito toneRose
class node_user toneIndigo
```

## Components

### System generation

- [CuO generator](https://github.com/lavishlohiya/avaranx-h2s/blob/main/generate_cuo_h2s_system.py): `generate_cuo_h2s_system.py`
- [ZnO generator](https://github.com/lavishlohiya/avaranx-h2s/blob/main/generate_zno_h2s_system.py): `generate_zno_h2s_system.py`
- [PbO generator](https://github.com/lavishlohiya/avaranx-h2s/blob/main/generate_pbo_h2s_system.py): `generate_pbo_h2s_system.py`
- [Bi₂O₃ generator](https://github.com/lavishlohiya/avaranx-h2s/blob/main/generate_bi2o3_h2s_system.py): `generate_bi2o3_h2s_system.py`
- [CuO system data](https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_cuo_system.data): `h2s_cuo_system.data`
- [ZnO system data](https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_zno_system.data): `h2s_zno_system.data`
- [PbO system data](https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_pbo_system.data): `h2s_pbo_system.data`
- [Bi₂O₃ system data](https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_bi2o3_system.data): `h2s_bi2o3_system.data`

### LAMMPS simulations

- **LAMMPS engine**
- [CuO simulation input](https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_cuo_reaxff.in): `h2s_cuo_reaxff.in`
- [ZnO simulation input](https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_zno.in): `h2s_zno.in`
- [PbO simulation input](https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_pbo.in): `h2s_pbo.in`
- [Bi₂O₃ simulation input](https://github.com/lavishlohiya/avaranx-h2s/blob/main/h2s_bi2o3.in): `h2s_bi2o3.in`
- **Simulation outputs**
- [LAMMPS log](https://github.com/lavishlohiya/avaranx-h2s/blob/main/log.lammps): `log.lammps`

### Workflow control

- [Pipeline runner](https://github.com/lavishlohiya/avaranx-h2s/blob/main/run_all.py): `run_all.py`

### Analysis and visualization

- [Analysis and visualization](https://github.com/lavishlohiya/avaranx-h2s/blob/main/ovito_analysis.py): `ovito_analysis.py`
- **Comparison plots**
- **OVITO tools**

### Other components

- **Engineer**

## Connections

- Engineer → Pipeline runner: starts workflow
- Engineer → Analysis and visualization: runs analysis
- Pipeline runner → CuO generator: runs generator
- Pipeline runner → ZnO generator: runs generator
- Pipeline runner → PbO generator: runs generator
- Pipeline runner → Bi₂O₃ generator: runs generator
- CuO generator → CuO system data: writes data
- ZnO generator → ZnO system data: writes data
- PbO generator → PbO system data: writes data
- Bi₂O₃ generator → Bi₂O₃ system data: writes data
- Pipeline runner → LAMMPS engine: launches simulations
- LAMMPS engine → CuO simulation input: runs input
- LAMMPS engine → ZnO simulation input: runs input
- LAMMPS engine → PbO simulation input: runs input
- LAMMPS engine → Bi₂O₃ simulation input: runs input
- CuO simulation input → CuO system data: uses system data
- ZnO simulation input → ZnO system data: uses system data
- PbO simulation input → PbO system data: uses system data
- Bi₂O₃ simulation input → Bi₂O₃ system data: uses system data
- LAMMPS engine → Simulation outputs: writes results
- LAMMPS engine → LAMMPS log: writes log
- Pipeline runner → Analysis and visualization: runs matplotlib mode
- Analysis and visualization → Simulation outputs: reads simulation results
- Analysis and visualization → Comparison plots: generates plots
- Analysis and visualization → OVITO tools: offers API mode
