atmodeller


Nameatmodeller JSON
Version 0.8.0 PyPI version JSON
download
home_pageNone
SummaryVolatile partitioning between a rocky interior and atmosphere
upload_time2025-07-08 10:35:17
maintainerNone
docs_urlNone
authorDan J Bower
requires_python<4.0,>=3.10
licenseGPL-3.0-or-later
keywords planetary-science volatile-partitioning chemical-equilibrium magma-ocean atmospheres jax equinox thermodynamics numerical-modeling exoplanets habitability geochemistry degassing astrobiology
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <p align="center">
<img src="https://github.com/ExPlanetology/atmodeller/blob/main/docs/logo.png" alt="atmodeller logo" width="300"/>
</p>

# Atmodeller

[![Release 0.8.0](https://img.shields.io/badge/Release-0.8.0-blue.svg)](https://github.com/ExPlanetology/atmodeller/releases/tag/v0.8.0)
[![Python 3.10+](https://img.shields.io/badge/Python-3.10+-blue.svg)](https://www.python.org/downloads/release/python-3100/)
[![License: GPL v3](https://img.shields.io/badge/License-GPLv3-yellow.svg)](https://www.gnu.org/licenses/gpl-3.0)
[![Python package](https://github.com/ExPlanetology/atmodeller/actions/workflows/python-package.yml/badge.svg)](https://github.com/ExPlanetology/atmodeller/actions/workflows/python-package.yml)
[![Test coverage](https://img.shields.io/badge/Coverage-88%25-brightgreen)](https://github.com/ExPlanetology/atmodeller)

## About
Atmodeller is a Python package that uses [JAX](https://jax.readthedocs.io/en/latest/index.html) to compute the partitioning of volatiles between a planetary atmosphere and its rocky interior. It is released under [The GNU General Public License v3.0 or later](https://www.gnu.org/licenses/gpl-3.0.en.html).

## Documentation

The documentation is available online, with options to download it in EPUB or PDF format:

[https://atmodeller.readthedocs.io/en/latest/](https://atmodeller.readthedocs.io/en/latest/)

## Quick install

Atmodeller is a Python package that can be installed on a variety of platforms (e.g. Mac, Windows, Linux). It is recommended to install Atmodeller in a dedicated Python environment. Before installation, create and activate the environment, then run:

```pip install atmodeller```

Downloading the source code is also recommended if you'd like access to the example notebooks in `notebooks/`.

## Citation

If you use Atmodeller, or data from Atmodeller, please cite:

- Bower, D. J., Thompson, M. A., Hakim, K., Tian, M., and Sossi, P. A. (2025), Diversity of rocky planet atmospheres in the C-H-O-N-S-Cl system with interior dissolution, non-ideality and condensation: Application to TRAPPIST-1e and sub-Neptunes, The Astrophysical Journal, submitted. ArXiv e-print [2507.00499](https://arxiv.org/abs/2507.00499).

The data from the above study are also available for download at https://doi.org/10.17605/OSF.IO/PC5TD.

## Basic usage

Jupyter notebooks in the `notebooks/` directory demonstrate how to perform single and batch calculations, and how to integrate Atmodeller into time-dependent simulations. A simple example of how to use Atmodeller is provided below:

```
from atmodeller import (
    InteriorAtmosphere,
    Planet,
    Species,
    SpeciesCollection,
    earth_oceans_to_hydrogen_mass,
)
from atmodeller.solubility import get_solubility_models

solubility_models = get_solubility_models()
# Get the available solubility models
print("solubility models = ", solubility_models.keys())

H2_g = Species.create_gas("H2")
H2O_g = Species.create_gas("H2O", solubility=solubility_models["H2O_peridotite_sossi23"])
O2_g = Species.create_gas("O2")

species = SpeciesCollection((H2_g, H2O_g, O2_g))
planet = Planet()
interior_atmosphere = InteriorAtmosphere(species)

oceans = 1
h_kg = earth_oceans_to_hydrogen_mass(oceans)
o_kg = 6.25774e20
mass_constraints = {
    "H": h_kg,
    "O": o_kg,
}

# If you do not specify an initial solution guess then a default will be used
# Initial solution guess number density (molecules/m^3)
initial_log_number_density = 50

interior_atmosphere.solve(
    planet=planet,
    initial_log_number_density=initial_log_number_density,
    mass_constraints=mass_constraints,
)
output = interior_atmosphere.output

# Quick look at the solution
solution = output.quick_look()

# Get complete solution as a dictionary
solution_asdict = output.asdict()
print("solution_asdict =", solution_asdict)

# Write the complete solution to Excel
output.to_excel("example_single")
```

## Funding
Atmodeller was created as part of a SERI-funded ERC Starting grant '2ATMO' granted to P. Sossi (Contract no. MB22.00033), with additional funding provided through a Swiss National Science Foundation (SNSF) Eccellenza Professorship (#203668).

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "atmodeller",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.10",
    "maintainer_email": null,
    "keywords": "planetary-science, volatile-partitioning, chemical-equilibrium, magma-ocean, atmospheres, jax, equinox, thermodynamics, numerical-modeling, exoplanets, habitability, geochemistry, degassing, astrobiology",
    "author": "Dan J Bower",
    "author_email": "dbower@eaps.ethz.ch",
    "download_url": "https://files.pythonhosted.org/packages/5c/9d/545b8d79f75b75542843673b4821f6cd7359e658446fba3c8cc66c20c64a/atmodeller-0.8.0.tar.gz",
    "platform": null,
    "description": "<p align=\"center\">\n<img src=\"https://github.com/ExPlanetology/atmodeller/blob/main/docs/logo.png\" alt=\"atmodeller logo\" width=\"300\"/>\n</p>\n\n# Atmodeller\n\n[![Release 0.8.0](https://img.shields.io/badge/Release-0.8.0-blue.svg)](https://github.com/ExPlanetology/atmodeller/releases/tag/v0.8.0)\n[![Python 3.10+](https://img.shields.io/badge/Python-3.10+-blue.svg)](https://www.python.org/downloads/release/python-3100/)\n[![License: GPL v3](https://img.shields.io/badge/License-GPLv3-yellow.svg)](https://www.gnu.org/licenses/gpl-3.0)\n[![Python package](https://github.com/ExPlanetology/atmodeller/actions/workflows/python-package.yml/badge.svg)](https://github.com/ExPlanetology/atmodeller/actions/workflows/python-package.yml)\n[![Test coverage](https://img.shields.io/badge/Coverage-88%25-brightgreen)](https://github.com/ExPlanetology/atmodeller)\n\n## About\nAtmodeller is a Python package that uses [JAX](https://jax.readthedocs.io/en/latest/index.html) to compute the partitioning of volatiles between a planetary atmosphere and its rocky interior. It is released under [The GNU General Public License v3.0 or later](https://www.gnu.org/licenses/gpl-3.0.en.html).\n\n## Documentation\n\nThe documentation is available online, with options to download it in EPUB or PDF format:\n\n[https://atmodeller.readthedocs.io/en/latest/](https://atmodeller.readthedocs.io/en/latest/)\n\n## Quick install\n\nAtmodeller is a Python package that can be installed on a variety of platforms (e.g. Mac, Windows, Linux). It is recommended to install Atmodeller in a dedicated Python environment. Before installation, create and activate the environment, then run:\n\n```pip install atmodeller```\n\nDownloading the source code is also recommended if you'd like access to the example notebooks in `notebooks/`.\n\n## Citation\n\nIf you use Atmodeller, or data from Atmodeller, please cite:\n\n- Bower, D. J., Thompson, M. A., Hakim, K., Tian, M., and Sossi, P. A. (2025), Diversity of rocky planet atmospheres in the C-H-O-N-S-Cl system with interior dissolution, non-ideality and condensation: Application to TRAPPIST-1e and sub-Neptunes, The Astrophysical Journal, submitted. ArXiv e-print [2507.00499](https://arxiv.org/abs/2507.00499).\n\nThe data from the above study are also available for download at https://doi.org/10.17605/OSF.IO/PC5TD.\n\n## Basic usage\n\nJupyter notebooks in the `notebooks/` directory demonstrate how to perform single and batch calculations, and how to integrate Atmodeller into time-dependent simulations. A simple example of how to use Atmodeller is provided below:\n\n```\nfrom atmodeller import (\n    InteriorAtmosphere,\n    Planet,\n    Species,\n    SpeciesCollection,\n    earth_oceans_to_hydrogen_mass,\n)\nfrom atmodeller.solubility import get_solubility_models\n\nsolubility_models = get_solubility_models()\n# Get the available solubility models\nprint(\"solubility models = \", solubility_models.keys())\n\nH2_g = Species.create_gas(\"H2\")\nH2O_g = Species.create_gas(\"H2O\", solubility=solubility_models[\"H2O_peridotite_sossi23\"])\nO2_g = Species.create_gas(\"O2\")\n\nspecies = SpeciesCollection((H2_g, H2O_g, O2_g))\nplanet = Planet()\ninterior_atmosphere = InteriorAtmosphere(species)\n\noceans = 1\nh_kg = earth_oceans_to_hydrogen_mass(oceans)\no_kg = 6.25774e20\nmass_constraints = {\n    \"H\": h_kg,\n    \"O\": o_kg,\n}\n\n# If you do not specify an initial solution guess then a default will be used\n# Initial solution guess number density (molecules/m^3)\ninitial_log_number_density = 50\n\ninterior_atmosphere.solve(\n    planet=planet,\n    initial_log_number_density=initial_log_number_density,\n    mass_constraints=mass_constraints,\n)\noutput = interior_atmosphere.output\n\n# Quick look at the solution\nsolution = output.quick_look()\n\n# Get complete solution as a dictionary\nsolution_asdict = output.asdict()\nprint(\"solution_asdict =\", solution_asdict)\n\n# Write the complete solution to Excel\noutput.to_excel(\"example_single\")\n```\n\n## Funding\nAtmodeller was created as part of a SERI-funded ERC Starting grant '2ATMO' granted to P. Sossi (Contract no. MB22.00033), with additional funding provided through a Swiss National Science Foundation (SNSF) Eccellenza Professorship (#203668).\n",
    "bugtrack_url": null,
    "license": "GPL-3.0-or-later",
    "summary": "Volatile partitioning between a rocky interior and atmosphere",
    "version": "0.8.0",
    "project_urls": {
        "Documentation": "https://atmodeller.readthedocs.io/en/latest",
        "Homepage": "https://planetology.ethz.ch",
        "Repository": "https://github.com/ExPlanetology/atmodeller",
        "issues": "https://github.com/ExPlanetology/atmodeller/issues"
    },
    "split_keywords": [
        "planetary-science",
        " volatile-partitioning",
        " chemical-equilibrium",
        " magma-ocean",
        " atmospheres",
        " jax",
        " equinox",
        " thermodynamics",
        " numerical-modeling",
        " exoplanets",
        " habitability",
        " geochemistry",
        " degassing",
        " astrobiology"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "4a99f7bf9fe17a346d55ee3c06a5acfbbb88b93431e3bbfe4a3dde3eb9cf17f0",
                "md5": "4df5eaac956ccdf55578c3b0d8e7e0c3",
                "sha256": "110a7f73b9d31ff636d6b3d09cb0e616e87310278175951c5d5a945d29d881cb"
            },
            "downloads": -1,
            "filename": "atmodeller-0.8.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "4df5eaac956ccdf55578c3b0d8e7e0c3",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.10",
            "size": 9191269,
            "upload_time": "2025-07-08T10:35:15",
            "upload_time_iso_8601": "2025-07-08T10:35:15.371252Z",
            "url": "https://files.pythonhosted.org/packages/4a/99/f7bf9fe17a346d55ee3c06a5acfbbb88b93431e3bbfe4a3dde3eb9cf17f0/atmodeller-0.8.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "5c9d545b8d79f75b75542843673b4821f6cd7359e658446fba3c8cc66c20c64a",
                "md5": "3f1f394df9be44435cc584d2da75d70b",
                "sha256": "f3133147074f31d54ed705e2bf70c885a08b261eca6aa3ba7d243d83c8bd6e94"
            },
            "downloads": -1,
            "filename": "atmodeller-0.8.0.tar.gz",
            "has_sig": false,
            "md5_digest": "3f1f394df9be44435cc584d2da75d70b",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.10",
            "size": 8962725,
            "upload_time": "2025-07-08T10:35:17",
            "upload_time_iso_8601": "2025-07-08T10:35:17.293291Z",
            "url": "https://files.pythonhosted.org/packages/5c/9d/545b8d79f75b75542843673b4821f6cd7359e658446fba3c8cc66c20c64a/atmodeller-0.8.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-08 10:35:17",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "ExPlanetology",
    "github_project": "atmodeller",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "atmodeller"
}
        
Elapsed time: 1.70282s