Parse PubChem PUG JSON into xsimple property and safety data.
Project description
x-pug-utils
Parse a PubChem PUG/PUG-View JSON document into the xsimple property and safety schema.
Environment setup
Python 3.10 or newer is required. Create and activate a virtual environment before installing the package:
python -m venv .venv
# Windows PowerShell
.venv\Scripts\Activate.ps1
# macOS/Linux
source .venv/bin/activate
Conda
conda create -n x-pug-utils python=3.12
conda activate x-pug-utils
Install
python -m pip install --upgrade pip
pip install x-pug-utils
# Upgrade to the latest release
pip install --upgrade x-pug-utils
x-pug-utils has no third-party runtime dependencies.
Usage
from x_pug_utils import parse_pug, parse_pug_file
result = parse_pug_file("COMPOUND_CID_2244.json")
# or: result = parse_pug(pug_json_dict)
The package uses only the Python standard library and always returns the xsimple schema.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file x_pug_utils-0.0.6.tar.gz.
File metadata
- Download URL: x_pug_utils-0.0.6.tar.gz
- Upload date:
- Size: 32.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d7369c65a79b6beab11b9ad46147abd175bad6c40dd65c87a131966382b26366
|
|
| MD5 |
165cf0397e515b52e90c3214a529cbed
|
|
| BLAKE2b-256 |
e5f69e7616a705f333a855b1cdec2cda029d6ffd1056bcf28de8ce72a98baf6c
|
File details
Details for the file x_pug_utils-0.0.6-py3-none-any.whl.
File metadata
- Download URL: x_pug_utils-0.0.6-py3-none-any.whl
- Upload date:
- Size: 32.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1e36d342d5922ee9c37804d0b596b300968511bbe4788f6b0ea51b4ade0bf82d
|
|
| MD5 |
c5ebd565438e2e1a1f49a7bffccfc6f2
|
|
| BLAKE2b-256 |
5c0c4e3b99dd4d7f5f69338e15a47c5ebd25a4a6e9db19217a898c9aea13e260
|