A dispatcher-based analytical and visualization suite for chemical physics
Project description
Table of Contents
About
A pure-python module of helpful scripts / CLIs I have written mostly for quick and dirty parsing / plotting of optimization methods. Loosely grouped. Not typically optimal at all.
Most of these rely heavily on optional dependencies, with the exception of the
_aux helpers (pure Python).
CLI Design Philosophy
The library is designed with the following principles in mind:
-
Dispatcher-Based Architecture: The top-level
rgpycrumbs.clicommand acts as a lightweight dispatcher. It does not contain the core logic of the tools itself. Instead, it parses user commands to identify the target script and then invokes it in an isolated subprocess using theuvrunner. This provides a unified command-line interface while keeping the tools decoupled. -
Isolated & Reproducible Execution: Each script is a self-contained unit that declares its own dependencies via PEP 723 metadata. The
uvrunner uses this information to resolve and install the exact required packages into a temporary, cached environment on-demand. This design guarantees reproducibility and completely eliminates the risk of dependency conflicts between different tools in the collection. -
Lightweight Core, On-Demand Dependencies: The installable
rgpycrumbspackage is minimal, with its only dependency being theclicklibrary for the CLI dispatcher. Heavy scientific libraries likematplotlibare not part of the base installation. They are fetched byuvonly when a script that needs them is executed, ensuring the user's base Python environment remains clean and lightweight. -
Modular & Extensible Tooling: Each utility is an independent script. This modularity simplifies development, testing, and maintenance, as changes to one tool cannot inadvertently affect another. New tools can be added to the collection without modifying the core dispatcher logic, making the system easily extensible.
Usage
CLI Tools
The general command structure is:
python -m rgpycrumbs.cli [subcommand-group] [script-name] [script-options]
You can see the list of available command groups:
$ python -m rgpycrumbs.cli --help
Usage: rgpycrumbs [OPTIONS] COMMAND [ARGS]...
A dispatcher that runs self-contained scripts using 'uv'.
Options:
--help Show this message and exit.
Commands:
eon Dispatches to a script within the 'eon' submodule.
EON
-
Plotting NEB Paths (
plt-neb)This script visualizes the energy profile of Nudged Elastic Band (NEB) calculations over optimization steps.
To see the help text for this specific script:
$ python -m rgpycrumbs eon plt-neb --help --> Dispatching to: uv run /path/to/rgpycrumbs/eon/plt_neb.py --help Usage: plt_neb.py [OPTIONS] Plots a series of NEB energy paths from .dat files. ... Options: --input-pattern TEXT Glob pattern for input data files. -o, --output-file PATH Output file name. --start INTEGER Starting file index to plot (inclusive). --end INTEGER Ending file index to plot (exclusive). --help Show this message and exit.To plot a specific range of
neb_*.datfiles and save the output:python -m rgpycrumbs eon plt-neb --start 100 --end 150 -o final_path.pdfTo show the plot interactively without saving:
python -m rgpycrumbs eon plt-neb --start 280 -
Splitting CON files (
con-splitter)This script takes a multi-image trajectory file (e.g., from a finished NEB calculation) and splits it into individual frame files, creating an input file for a new calculation.
To split a trajectory file:
rgpycrumbs eon con-splitter neb_final_path.con -o initial_imagesThis will create a directory named
initial_imagescontainingipath_000.con,ipath_001.con, etc., along with anipath.datfile listing their paths.
Contributing
All contributions are welcome, but for the CLI tools please follow established best practices.
Release notes
Generally this is a hatch project, so:
uvx hatch test
uvx towncrier build --version "v0.0.4"
git tag -a v0.0.4 -m "Version 0.0.4 release"
uvx hatch build
License
MIT. However, this is an academic resource, so please cite as much as possible via:
- The Zenodo DOI for general use.
- The
wailordpaper for ORCA usage
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 rgpycrumbs-0.1.1.tar.gz.
File metadata
- Download URL: rgpycrumbs-0.1.1.tar.gz
- Upload date:
- Size: 64.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
096b61d4364d6e4374636ebb41434a7470aee94584bb76b36cc67c8f00f93716
|
|
| MD5 |
9da51a8e78333254becf2c2fde4064de
|
|
| BLAKE2b-256 |
fc5cac41a91b10979ba428c7b48ceb9032e58ea4cc09877d247804e356d335b9
|
File details
Details for the file rgpycrumbs-0.1.1-py3-none-any.whl.
File metadata
- Download URL: rgpycrumbs-0.1.1-py3-none-any.whl
- Upload date:
- Size: 74.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c33d1773223bd922c54960c1d9acd738933692df71e72ae8b765f87e51ee28ac
|
|
| MD5 |
fc4b0b6a24657a013ce02ba15e6273fd
|
|
| BLAKE2b-256 |
0803480d86eb1347906f36c4a87b78f2a94adae46faf3b054cdade5be3fa6194
|