vizplugins
official plugins for VizTracer; currently support tracing cpu and memory usage through psutil.
Install
The prefered way to install vizplugins is via pip
pip install vizplugins
Basic Usage
The vizplugin should be used with viztracer.
You can use VizTracer and the plugin by
viztracer --plugin vizplugins.cpu_usage -- my_script.py arg1 arg2
which will record the cpu percent of the process and generate a result.html file in the directory you run this command, which you can open with Chrome.
The plugin samples cpu usage per 0.02s by default, but you can explicitly indicate the desired frequency at which to sample data per second
viztracer --plugin "vizplugins.cpu_usage -f 20" -- my_script.py arg1 arg2
which will sample data approximately 20 times per second, with a sampling interval of 0.05 second.
You can also trace the memory usage and cpu usage by
viztracer --plugin vizplugins --cpu_usage --memory_usage -- my_script.py arg1 arg2
which will record both the cpu and memory usage.
Example
The below image is an example of the resulting html, which is called on an recursively defined fibonacci funtion.
The "cpu_usage" on the top indicates the corresponding cpu usage at each time period. The "memory_usage" have two colors, representing rss(Resident Set Size, the non-swapped physical memory) and vms(Virtual Memory Size). You can see the details by clicking on one of the periods.
Metadata
Release files for vizplugins 0.1.3
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 |
|---|---|---|---|---|
| vizplugins-0.1.3.tar.gz | 9.2 kB | Without provenance | Details for vizplugins-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| vizplugins-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for vizplugins-0.1.3-py3-none-any.whl |
Total release size: 19.8 kB
Release files / vizplugins-0.1.3.tar.gz
| Download URL | vizplugins-0.1.3.tar.gz |
|---|---|
| Size | 9.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
734f434cfaa6178314cc4056b728dd9836652b1d3da14969d766f66d47e17a67
|
|
BLAKE2b-256 checksum How to use checksums |
432f8c817b9a49a7d82c9f98c79ea3588ed0d6250c10369d737c1d02d2701f95
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.9.15
|
Release files / vizplugins-0.1.3-py3-none-any.whl
| Download URL | vizplugins-0.1.3-py3-none-any.whl |
|---|---|
| Size | 10.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
35e512395607f2288592c0fdbda0c005ebea311ef9d1eeec8ddd83a8ca9a0f2f
|
|
BLAKE2b-256 checksum How to use checksums |
edf79121950290e59cd26e31f701400f37afaab3df4b7a10d456fe998c4c9d88
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.9.15
|
Security for vizplugins 0.1.3
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.