1{ lib, fetchPypi, buildPythonPackage, isPy3k
2, numpy
3, wheel
4, werkzeug
5, protobuf
6, grpcio
7, markdown
8, absl-py
9, google-auth-oauthlib
10, tensorboard-plugin-wit
11, tensorboard-plugin-profile
12}:
13
14# tensorflow/tensorboard is built from a downloaded wheel, because
15# https://github.com/tensorflow/tensorboard/issues/719 blocks
16# buildBazelPackage.
17
18buildPythonPackage rec {
19 pname = "tensorflow-tensorboard";
20 version = "2.4.0";
21 format = "wheel";
22 disabled = !isPy3k;
23
24 src = fetchPypi {
25 pname = "tensorboard";
26 inherit version format;
27 python = "py3";
28 sha256 = "0f17h6i398n8maam0r3rssqvdqnqbwjyf96nnhf482anm1iwdq6d";
29 };
30
31 propagatedBuildInputs = [
32 numpy
33 werkzeug
34 protobuf
35 markdown
36 grpcio
37 absl-py
38 google-auth-oauthlib
39 tensorboard-plugin-profile
40 tensorboard-plugin-wit
41 # not declared in install_requires, but used at runtime
42 # https://github.com/NixOS/nixpkgs/issues/73840
43 wheel
44 ];
45
46 # in the absence of a real test suite, run cli and imports
47 checkPhase = ''
48 $out/bin/tensorboard --help > /dev/null
49 '';
50
51 pythonImportsCheck = [
52 "tensorboard"
53 "tensorboard.backend"
54 "tensorboard.compat"
55 "tensorboard.data"
56 "tensorboard.plugins"
57 "tensorboard.summary"
58 "tensorboard.util"
59 ];
60
61 meta = with lib; {
62 description = "TensorFlow's Visualization Toolkit";
63 homepage = "http://tensorflow.org";
64 license = licenses.asl20;
65 maintainers = with maintainers; [ abbradar ];
66 };
67}