depot/third_party/nixpkgs/pkgs/development/python-modules/nvidia-ml-py/default.nix
Default email 5ca88bfbb9 Project import generated by Copybara.
GitOrigin-RevId: 9f918d616c5321ad374ae6cb5ea89c9e04bf3e58
2024-07-31 10:19:44 +00:00

39 lines
828 B
Nix

{
lib,
fetchPypi,
buildPythonPackage,
substituteAll,
addDriverRunpath,
}:
buildPythonPackage rec {
pname = "nvidia-ml-py";
version = "12.555.43";
format = "setuptools";
src = fetchPypi {
inherit pname version;
extension = "tar.gz";
hash = "sha256-6efxLvHsI0uw3CLSvcdi/6+rOUvcRyoHpDd8lbv5Ov4=";
};
patches = [
(substituteAll {
src = ./0001-locate-libnvidia-ml.so.1-on-NixOS.patch;
inherit (addDriverRunpath) driverLink;
})
];
# no tests
doCheck = false;
pythonImportsCheck = [ "pynvml" ];
meta = {
description = "Python Bindings for the NVIDIA Management Library";
homepage = "https://pypi.org/project/nvidia-ml-py";
license = lib.licenses.bsd3;
platforms = [ "x86_64-linux" ];
maintainers = with lib.maintainers; [ GaetanLepage ];
};
}