Install
plesty-lib needs Python 3.12 or later. Add it to your project with uv or pip:
uv add plesty-lib # or: pip install plesty-lib
The basic install is enough to write and use devices, experiments and analyzers
(see Quick Start). It brings the packages those need:
numpy for arrays, pyvisa, pyserial and pyusb to reach instruments, pyzmq
to use them over the network, and pyyaml to read settings files.
Extras
Some features need large packages that most computers running plesty-lib do not want. A computer that only runs an instrument, for example, has no use for a GUI toolkit. These features are extras: you install them only by naming them in square brackets.
Extra |
Installs |
For |
|---|---|---|
|
|
windows: device control panels and the viewer that plots a running measurement |
|
|
saving a measurement’s plots as a video (MP4, or GIF with Pillow alone) |
|
|
showing equations in reports opened as HTML; without it they appear as LaTeX source |
|
|
fitting peaks in a spectrum ( |
|
|
converting saved results into one HDF5 file ( |
Name one or several:
uv add "plesty-lib[gui]"
uv add "plesty-lib[gui,record]"
pip install "plesty-lib[gui,record]"
If you use a feature without its extra, plesty-lib stops with an error that names the extra to install.
Tools for publishing a module
To publish your own device, experiment or analyzer as a PLESTY module, you also need plesty-sdk, PLESTY’s developer tool. It creates the files a new module starts with and checks a module against the PLESTY standard before it is published. You only need it while developing, not to run anything:
uv add --dev plesty-sdk