{"id":24231,"library":"perturbopy","title":"PerturboPy","description":"Suite of Python scripts for Perturbo (first-principles electron-phonon coupling) testing and postprocessing. Version 0.7.2, requires Python >=3.7.12. Development appears slow/infrequent.","status":"active","version":"0.7.2","language":"python","source_language":"en","source_url":"https://github.com/perturbo-code/perturbopy","tags":["perturbo","electron-phonon","first-principles","material-science","hdf5"],"install":[{"cmd":"pip install perturbopy","lang":"bash","label":"PyPI"},{"cmd":"conda install -c conda-forge perturbopy","lang":"bash","label":"Conda"}],"dependencies":[{"reason":"Reading HDF5 output from Perturbo","package":"h5py","optional":false},{"reason":"Numerical operations","package":"numpy","optional":false},{"reason":"Plotting","package":"matplotlib","optional":false},{"reason":"Data handling","package":"pandas","optional":false},{"reason":"Reading/writing HDF5 with pandas","package":"pytables","optional":true}],"imports":[{"note":"PerturboCalc is in the calculator submodule, not top-level","wrong":"from perturbopy import PerturboCalc","symbol":"PerturboCalc","correct":"from perturbopy.calculator import PerturboCalc"},{"note":"read_phdisp is in io_utils, not top-level","wrong":"from perturbopy import read_phdisp","symbol":"read_phdisp","correct":"from perturbopy.io_utils import read_phdisp"}],"quickstart":{"code":"from perturbopy.calculator import PerturboCalc\n\ncalc = PerturboCalc.from_yaml('perturbo_input.yaml')\ncalc.run()\nresults = calc.results\nprint(results.keys())","lang":"python","description":"Initialize a Perturbo calculation from a YAML input file, run it, and print available result keys."},"warnings":[{"fix":"Use correct submodule paths: from perturbopy.calculator import PerturboCalc","message":"Top-level imports of classes/functions may fail. Always import from specific submodules (e.g., perturbopy.calculator, perturbopy.io_utils).","severity":"gotcha","affected_versions":"all"},{"fix":"Use io_utils to load data and matplotlib directly for plotting.","message":"Some plotting functions (e.g., plot_bands) are deprecated in favor of more flexible methods. Check documentation for latest API.","severity":"deprecated","affected_versions":"<=0.7.2"},{"fix":"Install Perturbo from https://perturbo.epfl.ch or build from source.","message":"The library interacts with the external 'Perturbo' binary (C++). Ensure Perturbo is installed and in PATH. perturbopy alone will not compute anything.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Use: from perturbopy.calculator import PerturboCalc","cause":"Incorrect import path: PerturboCalc is in the calculator submodule.","error":"ImportError: cannot import name 'PerturboCalc' from 'perturbopy'"},{"fix":"pip install tables or conda install pytables","cause":"Missing optional dependency pytables needed for reading HDF5 with pandas.","error":"ModuleNotFoundError: No module named 'pytables'"},{"fix":"Follow instructions at https://perturbo.epfl.ch to install Perturbo.","cause":"perturbopy is a wrapper; the actual Perturbo binary must be installed separately.","error":"RuntimeError: Perturbo executable not found. Please make sure it is installed and in your PATH."},{"fix":"Refer to the PerturboPy documentation for a valid YAML template or use the example files.","cause":"YAML input file for PerturboCal must follow a specific schema (e.g., has 'qpoints', 'bands', etc.).","error":"ValueError: Invalid YAML input file. Keys missing: ..."}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}