How osyris-project/osyris works
Osyris is a Python utility for loading RAMSES astrophysical simulation data, exploring it with unit-aware data structures and spatial selections, and producing scientific visualizations. The main workflow loads a selected simulation output into grouped data, then passes fields or layers to histogram or map plotting and returns a plot result. The map implementation shows projection, binning, and rendering; other plotting internals and the dataset-loading entry point were not sampled, so those links are limited to documented behavior and visible module boundaries.
Main entry points: loader.py Output loader · dataset.py Dataset groups · hist2d.py Histograms · map.py Maps and projection
Components 19
RAMSES loading
- RamsesDataset
src/osyris/io/ramses.py - Output loader
src/osyris/io/loader.py - Format readers
src/osyris/io/reader.py - AMR and Hilbert
src/osyris/io/hilbert.py
Data and units
- Dataset groups
src/osyris/core/dataset.py - Datagroup fields
src/osyris/core/datagroup.py - Unit-aware arrays
src/osyris/core/array.py - Vectors
src/osyris/core/vector.py - Derived variables
src/osyris/config/defaults.py - Units
src/osyris/units/units.py
Spatial analysis
- Subdomain extraction
src/osyris/spatial/subdomain.py
Visualization
- Plot layers
src/osyris/core/layer.py - Histograms
src/osyris/plot/hist2d.py - Maps and projection
src/osyris/plot/map.py - Layer parsing
src/osyris/plot/parser.py - Rendering
src/osyris/plot/render.py - Plot result
src/osyris/core/plot.py
Other components
- Researcher
- RAMSES output
Connections 22
- Researcher → RamsesDataset: requests load
- RAMSES output → Output loader: reads output
- RamsesDataset → Output loader: loads output
- Output loader → Format readers: dispatches reads
- Output loader → AMR and Hilbert: selects CPU domains
- Output loader → Dataset groups: assembles groups
- Format readers → Dataset groups: provides fields
- Dataset groups → Datagroup fields: holds groups
- Datagroup fields → Unit-aware arrays: holds fields
- Unit-aware arrays → Units: converts units
- Vectors → Unit-aware arrays: wraps components
- Derived variables → Dataset groups: adds derived fields
- Researcher → Subdomain extraction: selects region
- Subdomain extraction → Dataset groups: returns subset
- Researcher → Histograms: requests histogram
- Researcher → Maps and projection: requests map
- Histograms → Layer parsing: parses layers
- Maps and projection → Layer parsing: parses layers
- Maps and projection → Rendering: renders projection
- Histograms → Rendering: renders histogram
- Rendering → Plot result: returns figure
- Researcher → Plot layers: configures fields