summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/augmax/default.nix
blob: 9573bd29a8708b675a2ffdaba530880b6383c8b3 (plain)
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
{
  buildPythonPackage,
  einops,
  fetchFromGitHub,
  jax,
  jaxlib,
  lib,
  setuptools,
}:

buildPythonPackage rec {
  pname = "augmax";
  version = "0.3.3";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "khdlr";
    repo = "augmax";
    tag = "v${version}";
    hash = "sha256-FXgkhZEAR1Y2LvVvV+IWMSQDWrLulLDsSKKuw4ER5wg=";
  };

  build-system = [ setuptools ];

  dependencies = [
    einops
    jax
  ];

  # augmax does not have any tests at the time of writing (2022-02-19), but
  # jaxlib is necessary for the pythonImportsCheckPhase.
  nativeCheckInputs = [ jaxlib ];

  pythonImportsCheck = [ "augmax" ];

  meta = {
    description = "Efficiently Composable Data Augmentation on the GPU with Jax";
    homepage = "https://github.com/khdlr/augmax";
    changelog = "https://github.com/khdlr/augmax/blob/v${version}/CHANGELOG.md";
    license = lib.licenses.asl20;
    maintainers = with lib.maintainers; [ samuela ];
  };
}