Skip to main content

libpypsg

A Python library to interact with the Planetary Spectrum Generator.

The goal of this package is to make PSG more accessible to new users, but still be powerful enough that expert users will find it useful.

In the simplest use case, users can create a PSG config file from scratch using the PyConfig class.

import libpypsg

cfg = libpypsg.cfg.PyConfig(
    target=libpypsg.cfg.Target(object='Exoplanet',name='Proxima Cen b')
    )
print(cfg.content)
b'<OBJECT-NAME>Proxima Cen b\n<OBJECT>Exoplanet'

We can then call PSG with our setup.

psg = libpypsg.APICall(
        cfg=cfg,
        output_type='rad',
    )
response = psg()

Now let’s take a look at the rad file we get back. The PyRad class inherits from astropy.table.QTable.

rad = response.rad

rad
Wave/freq     Total          Object       Reflected       Thermal
    um    W / (sr um m2) W / (sr um m2) W / (sr um m2) W / (sr um m2)
float64     float64        float64        float64        float64
--------- -------------- -------------- -------------- --------------
    1.0      231.99203        231.992        231.992    1.76851e-13
    1.1      184.89523        184.895        184.895    8.59289e-12
    ...            ...            ...            ...            ...
    1.8       45.45587        45.4559        45.4559    1.69172e-05
    1.9      38.276023         38.276         38.276    5.24737e-05

Metadata

Release files for libpypsg 0.5.0

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

Source distribution (sdist)

Source distribution for libpypsg 0.5.0
File Size Uploaded Provenance Actions
libpypsg-0.5.0.tar.gz 55.7 kB With provenance Details for libpypsg-0.5.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for libpypsg 0.5.0
File Interpreter ABI Platform Actions
libpypsg-0.5.0-py3-none-any.whl Python 3 none any Details for libpypsg-0.5.0-py3-none-any.whl

Total release size: 114.3 kB

Release files / libpypsg-0.5.0.tar.gz

Download URL libpypsg-0.5.0.tar.gz
Size 55.7 kB
Tags Source
SHA-256 checksum
How to use checksums
e4706cb5fb7772934779606fa4234cd8b7dfbfd20844f37b03cd935b9ae03640
BLAKE2b-256 checksum
How to use checksums
7e666b2a755fb3082ef37da356a58ec0a9674e7b699db7f990279bf5378b1d5a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jun 26, 2025.

Transparency log

Release files / libpypsg-0.5.0-py3-none-any.whl

Download URL libpypsg-0.5.0-py3-none-any.whl
Size 58.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f5a7dbaa0e0e1a34cf19d92b9a3b4ed66e7c958b29d26bfaa38b87ff83969e67
BLAKE2b-256 checksum
How to use checksums
1e49241e6f07f193c5d3c5308a2baa9d04e4667142b14421372f2ebb656dd020
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jun 26, 2025.

Transparency log

Security for libpypsg 0.5.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for libpypsg-0.5.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jun 26, 2025.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.5.0 This release

2 release files Full provenance

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