Skip to main content

A package to visualize AMR data from the RAMSES code

Project description

Osyris

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.

Documentation

The documentation for osyris is hosted on Readthedocs.

Installation

pip install osyris

A short example

You can download the sample data here.

Plot a 2D histogram of the cell magnetic field versus the gas density.

import osyris
data = osyris.Dataset(71, scale="au", path="data").load()
osyris.plot.histogram(data["hydro"]["density"], data["hydro"]["B_field"],
                      norm="log", loglog=True)

Create a 2D gas density slice 100 au wide through the plane normal to z, with velocity vectors overlayed as arrows, once agains using layers:

ind = np.argmax(data["hydro"]["density"])
center = data["amr"]["xyz"][ind.values]
osyris.plane({"data": data["hydro"]["density"], "norm": "log"}, # layer 1
             {"data": data["hydro"]["velocity"], "mode": "vec"}, # layer 2
             dx=50 * osyris.units("au"),
             origin=center,
             direction="z")

Have a problem or need a new feature?

Submit an issue on Github.

Contributors

  • Neil Vaytet (StarPlan/NBI)
  • Tommaso Grassi (StarPlan/NBI)
  • Matthias Gonzalez (CEA Saclay)
  • Troels Haugbolle (StarPlan/NBI)
  • Lucas Beeres

Logo credit

Icon vector created by frimufilms - www.freepik.com

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

osyris-2.2.0.tar.gz (29.1 kB view hashes)

Uploaded Source

Built Distribution

osyris-2.2.0-py3-none-any.whl (39.0 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page