2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
2024-10-04 16:56:33 +00:00
|
|
|
|
|
|
|
# build-system
|
2024-06-05 15:53:02 +00:00
|
|
|
setuptools,
|
2024-10-04 16:56:33 +00:00
|
|
|
|
|
|
|
# dependencies
|
2024-06-05 15:53:02 +00:00
|
|
|
absl-py,
|
|
|
|
jax,
|
|
|
|
jaxlib,
|
|
|
|
numpy,
|
|
|
|
toolz,
|
|
|
|
typing-extensions,
|
2024-10-04 16:56:33 +00:00
|
|
|
|
|
|
|
# tests
|
|
|
|
cloudpickle,
|
|
|
|
dm-tree,
|
|
|
|
pytestCheckHook,
|
2022-01-03 16:56:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "chex";
|
2024-10-04 16:56:33 +00:00
|
|
|
version = "0.1.87";
|
2024-04-21 15:54:59 +00:00
|
|
|
pyproject = true;
|
2022-01-03 16:56:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "deepmind";
|
2023-11-16 04:20:00 +00:00
|
|
|
repo = "chex";
|
2022-08-12 12:06:08 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2024-10-04 16:56:33 +00:00
|
|
|
hash = "sha256-TPh7XLWHk0y/VLXxHLANUiDmfveHPeMLks9QKf16doo=";
|
2022-01-03 16:56:52 +00:00
|
|
|
};
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
build-system = [ setuptools ];
|
2024-04-21 15:54:59 +00:00
|
|
|
|
|
|
|
dependencies = [
|
2022-01-03 16:56:52 +00:00
|
|
|
absl-py
|
|
|
|
jax
|
2024-10-04 16:56:33 +00:00
|
|
|
jaxlib
|
2022-01-03 16:56:52 +00:00
|
|
|
numpy
|
|
|
|
toolz
|
2023-08-22 20:05:09 +00:00
|
|
|
typing-extensions
|
2022-01-03 16:56:52 +00:00
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "chex" ];
|
2022-01-03 16:56:52 +00:00
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2023-08-22 20:05:09 +00:00
|
|
|
cloudpickle
|
|
|
|
dm-tree
|
2022-01-03 16:56:52 +00:00
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2024-10-04 16:56:33 +00:00
|
|
|
meta = {
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "Chex is a library of utilities for helping to write reliable JAX code";
|
2022-01-03 16:56:52 +00:00
|
|
|
homepage = "https://github.com/deepmind/chex";
|
2023-10-19 13:55:26 +00:00
|
|
|
changelog = "https://github.com/google-deepmind/chex/releases/tag/v${version}";
|
2024-10-04 16:56:33 +00:00
|
|
|
license = lib.licenses.asl20;
|
|
|
|
maintainers = with lib.maintainers; [ ndl ];
|
2022-01-03 16:56:52 +00:00
|
|
|
};
|
|
|
|
}
|