A python visualization utility for RAMSES astrophysical simulations data. Osyris aims to remain portable, lightweight and fast, to allow users to quickly explore and understand their simulation data, as well as produce publication grade figures.
The documentation for osyris
can be found at https://osyris.readthedocs.io.
pip install osyris
You can download the sample data here.
Plot a 2D histogram of the cell magnetic field versus the gas density.
import numpy as np
import osyris
data = osyris.RamsesDataset(8, path="data").load()
osyris.hist2d(data["mesh"]["density"], data["mesh"]["B_field"],
norm="log", loglog=True)
Create a 2D gas density map 2000 au wide through the plane normal to z
,
with velocity vectors overlayed as arrows, once again using layers
:
ind = np.argmax(data["mesh"]["density"])
center = data["mesh"]["position"][ind]
osyris.map(
data["mesh"].layer("density", norm="log"),
data["mesh"].layer("velocity", mode="vec"),
dx=2000 * osyris.units("au"),
origin=center,
direction="z",
)
- Bug reports or feature requests should be submitted by opening an issue
- For general discussions or questions about how to do something with
osyris
, start a new discussion