process-plot
Create plots of resource usage for a process (memory, CPU, etc).
Process statistics are polled at a set interval, in a cross-platform manner (i.e. supports Linux, OSX and Windows).
Information is collected on both the main process and any child processes, and can be plotted in a single graph.
Usage
Install the package with pip or pipx:
$ pipx install process-plot
then run:
$ pplot exec -i 0.1 "sleep 1"
PPLOT INFO: Output files will be written to: /user/pplot_out, with basename: 20210921125420
PPLOT INFO: Running process as PID: 5379
PPLOT INFO: Total run time: 0 hour(s), 00 minute(s), 01.034680 second(s)
PPLOT INFO: Plotting results to: pplot_out/20210921125420.png
PPLOT SUCCESS!
You will then find the output files in /user/pplot_out, with a plot for the process like:
If the process spawns child processes, by default, the values for the main process and all child processes are summed together.
When called with --stack-processes, the plot will stack the values per process:
Additional options are available:
$ pplot exec --help
Usage: pplot exec [OPTIONS] COMMAND
Execute a command and profile it.
Options:
-i, --interval FLOAT Polling interval (seconds)
-t, --timeout FLOAT Timeout process (seconds)
-c, --command-output [hide|screen|file]
Mode for stdout/stderr of command [default:
file]
--no-child Don't collect child process data
-o, --outfolder DIRECTORY Folder path for output files
-n, --basename TEXT Basename for output files (defaults to
datetime)
-p, --plot-cols [memory_rss|memory_vms|cpu_percent|cpu_time_user|cpu_time_sys|threads_num|files_num]
Columns to plot (comma-delimited) [default:
memory_rss,cpu_percent]
--stack-processes Stack values per process in plot
--title TEXT Plot title (defaults to command)
--grid / --no-grid Add grid to plots [default: grid]
-sw, --size-width FLOAT Width of plot in cm
-sh, --size-height FLOAT Height of plot in cm
-f, --format [png|pdf|svg] Plot file format
-v, --verbose Increase verbosity [x>=0]
-q, --quiet Quiet mode
--help Show this message and exit.
Acknowledgements
Initially adapted from: https://github.com/jeetsukumaran/Syrupy
Metadata
Release files for process_plot 0.4.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| process_plot-0.4.0.tar.gz | 72.2 kB | Without provenance | Details for process_plot-0.4.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| process_plot-0.4.0-py3-none-any.whl | Python 3 | none | any | Details for process_plot-0.4.0-py3-none-any.whl |
Total release size: 81.1 kB
Release files / process_plot-0.4.0.tar.gz
| Download URL | process_plot-0.4.0.tar.gz |
|---|---|
| Size | 72.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8f32ce90d5720fade4b6cae796e5393f9cf7b98e4b28e226c1cfe8a6f9e731b5
|
|
BLAKE2b-256 checksum How to use checksums |
67b2b0051ce0aa719a24a65a2e11d6d5a3b8b0a5e47aef7ceeaa490d57805d42
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-requests/2.32.3
|
Release files / process_plot-0.4.0-py3-none-any.whl
| Download URL | process_plot-0.4.0-py3-none-any.whl |
|---|---|
| Size | 8.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
336845225e9f11e9676b353d89819b61d8c72c9c3cae709fcfcbe292445ade46
|
|
BLAKE2b-256 checksum How to use checksums |
69fb8d914a3e87e4b9c5f710e58d75aadd8fc2a0a537af9dc9d75650a9dba42c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-requests/2.32.3
|
Security for process_plot 0.4.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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
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.