aboutsummaryrefslogtreecommitdiffstats
path: root/pysmctrl
Commit message (Collapse)AuthorAge
* Correctly pass arguments to Python's ctypes find_library() functionJoshua Bakita2024-12-23
| | | | | | | | | The prefix "lib" should not be included, per the documentation. This was not caught in local tests as the fallback was always used locally. Patch courtesy of Guanbin Xu <xugb@mail.ustc.edu.cn>.
* Introduce pysmctrl: A python interface to libsmctrlJoshua Bakita2023-03-16
Initially supports the GPU information functions via: - pysmctrl.get_gpc_info(dev_id) - pysmctrl.get_tpc_info(dev_id) - pysmctrl.get_tpc_info_cuda(cuda_dev_id) All functions are extensively documented. See pysmctrl/__init__.py for details. Device partitioning functions have yet to be mapped into Python, as these will require more testing. As part of this: - libsmctrl_get_*_info() functions have been modified to consistently return positive error codes. - libsmctrl_get_tpc_info() now uses nvdebug-style device numbering and uses libsmctrl_get_gpc_info() under the covers. This should be more reliable. - libsmctrl_get_tpc_info_cuda() has been introduced as an improved version of the old libsmctrl_get_tpc_info() function. This continues to use CUDA-style device numbering, but is now resiliant to CUDA failures. - Various minor style improvements in libsmctrl.c