Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

TauREx-petitRADTRANS plugin

Current version: 0.3.0-alpha

TauREx-petitRADTRANS is a plugin that allows for the use of petitRADTRANS opacities and forward models in TauREx

Installing

Installing the plugin from PyPI requires only a single command:

pip install taurex_petitrad

You can also install from source by doing:

git clone https://github.com/ucl-exoplanets/taurex-petitrad
cd taurex-petitrad
pip install .

Using opacities

Once installed you have access to both petitRADTRANS line-by-line cross-sections and k-tables. You can either set the xsec_path or ktable_path to the input_data folder in petitRADTRANS:

[Global]
xsec_path = /path/to/petitRADTRANS/petitRADTRANS/input_data/
ktable_path = /path/to/petitRADTRANS/petitRADTRANS/input_data/

Or by setting petitrad_path to the root petitRADTRANS folder

[Global]
petitrad_path = /path/to/petitRADTRANS/petitRADTRANS/

You can include both if you desire, petitrad_path will be prioritized.

Using forward models

To use the forward models, the petitrad_path must be set to the root petitRADTRANS folder. TauREx 3 will automatically include the package into Python so there is no need to modify system paths.

Once done, you will have access to three new forward models:

Transmission

Transmission spectra can be accessed through the model_type keyword by setting it as either transmission-petitrad or transit-petitrad

[Model]
model_type = transmission-petitrad
continuum_opacities = H2-H2, H2-He
wlen_bords_micron = 0.3,15.0

The available arguments are:

Argument Description Type Default Required
rayleigh_species Rayleigh species to include list of molecules None
continuum_species CIA species list of molecule pairs None
wlen_bords_micron Wavelength range in um array 0.3, 15
Pcloud Grey cloud deck pressure in Pa float None
gamma_scat Powerlaw index integer None
kappa_zero Powerlaw cloud opacity term in cm2/g float None
haze_factor Rayleigh opacity scale term float None

For the more through explaination of cloud terms please refer to this documentation.

The available retrieval parameters are:

|Fitting Parameter| Description| Pcloud | Grey cloud deck pressure in Pa | gamma_scat | Powerlaw index | kappa_zero | Powerlaw cloud opacity term in cm2/g | haze_factor | Rayleigh opacity scale term |

Eclipse and Direct imaging

The eclipse spectra can be generated using the emission-petitrad or eclipse-petitrad keyword

[Model]
model_type = eclipse-petitrad
continuum_opacities = H2-H2, H2-He
wlen_bords_micron = 0.3,15.0

And direct imaging as through by directimage-petitrad or direct-petitrad:

[Model]
model_type = directimage-petitrad
continuum_opacities = H2-H2, H2-He
wlen_bords_micron = 0.3,15.0

Both have the same arguments available:

Argument Description Type Default Required
rayleigh_species Rayleigh species to include list of molecules None
continuum_species CIA species list of molecule pairs None
wlen_bords_micron Wavelength range in um array 0.3, 15

There are no extra retrieval parameters provided by these forward models

Limitations

Currently no condensate opacities are supported as the current release of TauREx does not have a comprehensive enough scattering framework to prevent incompatibility with other models. Future releases will allow for their inclusion.

The majority of TauREx and its plugins can be used with the petitRADTRANS models such as chemistries, temeperature profiles, samplers, non-uniform priors etc. The only exception are the contributions. This is because the integral is being performed by petitRADTRANS itself, therefore some plugins (such as TauREx-CUDA) cannot be used. Attempting to add any TauREx contribution object such as:

[Model]
model_type = transmission-petitrad
continuum_opacities = H2-H2, H2-He
wlen_bords_micron = 0.3,15.0
    [[Absorption]]

    [[HydrogenIon]]

    [[Rayleigh]]

Will result in the error:

ValueError: TauREx 3 contributions are not supported with the petitRADTRANS forward models

Metadata

Release files for taurex-petitrad 0.3.0a0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for taurex-petitrad 0.3.0a0
File Size Uploaded
taurex_petitrad-0.3.0a0.tar.gz 12.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for taurex-petitrad 0.3.0a0
File Interpreter ABI Platform
taurex_petitrad-0.3.0a0-py3-none-any.whl Python 3 none any Details

Total release size: 26.8 kB

Release files / taurex_petitrad-0.3.0a0.tar.gz

Download URL taurex_petitrad-0.3.0a0.tar.gz
Size 12.8 kB
Tags Source
SHA-256 checksum
How to use checksums
c818349d9a6a91354cee1ae1bf4b8aea02ce315fde5a5498dc05941924cfa92e
BLAKE2b-256 checksum
How to use checksums
276661a7bb57b8cc92bd2fd3a1faa7a57ea25d2cb2ba8c1622122e8e43dc6b0e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.2 importlib_metadata/3.10.0 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.61.1 CPython/3.8.10

Release files / taurex_petitrad-0.3.0a0-py3-none-any.whl

Download URL taurex_petitrad-0.3.0a0-py3-none-any.whl
Size 14.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ad89385455303b7f85404d2124cd89254398127f4b2a10f9e7e5a1adc8c9fcc8
BLAKE2b-256 checksum
How to use checksums
b141978c260b67d1f3e9246cf940839efc4efdadbc07f116e4fbece9aa8027c1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.2 importlib_metadata/3.10.0 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.61.1 CPython/3.8.10

Release history Release notifications | RSS feed

This release

0.3.0a0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page