1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
|
{
lib,
buildPythonPackage,
fetchFromGitHub,
# build-system
setuptools,
# dependencies
dotmap,
flax,
jax,
matplotlib,
numpy,
# tests
# brax, (unpackaged)
# gymnax, (unpackaged)
pytestCheckHook,
torch,
torchvision,
writableTmpDirAsHomeHook,
}:
buildPythonPackage rec {
pname = "evosax";
version = "0.2.0";
pyproject = true;
src = fetchFromGitHub {
owner = "RobertTLange";
repo = "evosax";
tag = "v.${version}";
hash = "sha256-ye5IHM8Pn/+BXI9kcB3W281Gna9hXV8DwsaJ9Xu06fU=";
};
build-system = [ setuptools ];
dependencies = [
dotmap
flax
jax
matplotlib
numpy
];
pythonImportsCheck = [ "evosax" ];
nativeCheckInputs = [
# brax
# gymnax
pytestCheckHook
torch
torchvision
writableTmpDirAsHomeHook
];
disabledTests = [
# Requires unpackaged gymnax
"test_env_ffw_rollout"
# TypeError: ShapedArray.__init__() got an unexpected keyword argument 'named_shape'
"test_base_api"
"test_run"
"test_run_scan"
# Tries to download a data set from the internet
"test_brax_problem_eval"
"test_brax_problem_init"
"test_brax_problem_sample"
"test_gymnax_problem_eval"
"test_gymnax_problem_init"
"test_gymnax_problem_sample"
"test_torchvision_problem_eval"
"test_torchvision_problem_init"
"test_torchvision_problem_sample"
"test_vision_fitness"
];
meta = {
description = "Evolution Strategies in JAX";
homepage = "https://github.com/RobertTLange/evosax";
changelog = "https://github.com/RobertTLange/evosax/releases/tag/v.${version}";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ GaetanLepage ];
};
}
|