diff --git a/default.nix b/default.nix index e6b5d65..f5b48d3 100644 --- a/default.nix +++ b/default.nix @@ -22,6 +22,10 @@ rec { inherit adiak; inherit maintainers; }; + caliper-reader = pkgs.callPackage ./pkgs/hpc/caliper-reader { + inherit caliper; + inherit maintainers; + }; conduit = pkgs.callPackage ./pkgs/hpc/conduit { inherit maintainers; }; @@ -29,6 +33,10 @@ rec { inherit conduit; inherit maintainers; }; + hatchet = pkgs.callPackage ./pkgs/hpc/hatchet { + inherit caliper-reader; + inherit maintainers; + }; flux-core = pkgs.callPackage ./pkgs/hpc/flux-core { inherit maintainers; }; diff --git a/pkgs/hpc/caliper-reader/default.nix b/pkgs/hpc/caliper-reader/default.nix new file mode 100644 index 0000000..dc1d899 --- /dev/null +++ b/pkgs/hpc/caliper-reader/default.nix @@ -0,0 +1,34 @@ +{ lib +, stdenv +, python3Packages +, maintainers +, caliper +}: + +# TODO maybe should not build this from pypi + +python3Packages.buildPythonApplication rec { + pname = "caliper-reader"; + version = "0.3.0"; + + src = python3Packages.fetchPypi { + inherit pname version; + sha256 = "sha256-/AHf9SewztBRrcK9NeUIV7OfARRyZJwkGIStmhbZVxc="; + }; + + propagatedBuildInputs = [ caliper ]; + pythonImportsCheck = [ + "caliperreader" + ]; + + # Only support for Python 3 + doCheck = !python3Packages.isPy27; + + meta = with lib; { + description = "caliper-reader: A Python reader for Caliper files"; + homepage = "https://github.com/LLNL/Caliper"; + license = licenses.bsd3; + maintainers = [ maintainers.vsoch ]; + }; + +} diff --git a/pkgs/hpc/hatchet/default.nix b/pkgs/hpc/hatchet/default.nix new file mode 100644 index 0000000..da2b711 --- /dev/null +++ b/pkgs/hpc/hatchet/default.nix @@ -0,0 +1,46 @@ +{ lib +, stdenv +, pkgs +, maintainers +, fetchurl +, caliper-reader +}: + +pkgs.python3Packages.buildPythonApplication rec { + pname = "hatchet"; + version = "2022.2.2"; + + src = fetchurl { + url = "https://github.com/LLNL/hatchet/archive/v${version}.tar.gz"; + sha256 = "sha256-5dQJH45hcBAIjitS9tH4AOwpp4YcLy6WRktCMXD719Y="; + }; + + nativeBuildInputs = [ + pkgs.python3Packages.cython + pkgs.python3Packages.setuptools + ]; + + propagatedBuildInputs = [ + pkgs.python3Packages.multiprocess + pkgs.python3Packages.matplotlib + pkgs.python3Packages.pandas + pkgs.python3Packages.numpy + pkgs.python3Packages.pyyaml + pkgs.python3Packages.pydot + caliper-reader + ]; + + # Only support for Python 3 + doCheck = !pkgs.python3Packages.isPy27; + + pythonImportsCheck = [ + "hatchet" + ]; + + meta = with lib; { + description = "Graph-indexed Pandas DataFrames for analyzing hierarchical performance data"; + homepage = "https://github.com/LLNL/hatchet"; + license = licenses.mit; + maintainers = [ maintainers.vsoch ]; + }; +}