diff options
author | Bas van Dijk <v.dijk.bas@gmail.com> | 2018-09-06 09:28:50 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-09-06 09:28:50 +0200 |
commit | 7158e7442f9e28d3b9cad9264063a76657fad070 (patch) | |
tree | 57c049f06acc1070e4b77bfc5d33b424f57ff84e /pkgs | |
parent | df2cc4121b566a16c3400778756862ddf2df3f1a (diff) | |
parent | 1fc5a6d2b6bf3acfd5e4761fd2cb0c549c6045f0 (diff) | |
download | nixlib-7158e7442f9e28d3b9cad9264063a76657fad070.tar nixlib-7158e7442f9e28d3b9cad9264063a76657fad070.tar.gz nixlib-7158e7442f9e28d3b9cad9264063a76657fad070.tar.bz2 nixlib-7158e7442f9e28d3b9cad9264063a76657fad070.tar.lz nixlib-7158e7442f9e28d3b9cad9264063a76657fad070.tar.xz nixlib-7158e7442f9e28d3b9cad9264063a76657fad070.tar.zst nixlib-7158e7442f9e28d3b9cad9264063a76657fad070.zip |
Merge pull request #46103 from teto/haskell_mnist
haskellPackages.tensorflow-mnist-input-data: fetch
Diffstat (limited to 'pkgs')
3 files changed, 25 insertions, 12 deletions
diff --git a/pkgs/development/haskell-modules/configuration-hackage2nix.yaml b/pkgs/development/haskell-modules/configuration-hackage2nix.yaml index 3aee4857f993..4a26fcbffc17 100644 --- a/pkgs/development/haskell-modules/configuration-hackage2nix.yaml +++ b/pkgs/development/haskell-modules/configuration-hackage2nix.yaml @@ -9054,12 +9054,6 @@ dont-distribute-packages: temporary-resourcet: [ i686-linux, x86_64-linux, x86_64-darwin ] tempus: [ i686-linux, x86_64-linux, x86_64-darwin ] tensor: [ i686-linux, x86_64-linux, x86_64-darwin ] - tensorflow-core-ops: [ i686-linux, x86_64-linux, x86_64-darwin ] - tensorflow-logging: [ i686-linux, x86_64-linux, x86_64-darwin ] - tensorflow-opgen: [ i686-linux, x86_64-linux, x86_64-darwin ] - tensorflow-ops: [ i686-linux, x86_64-linux, x86_64-darwin ] - tensorflow-proto: [ i686-linux, x86_64-linux, x86_64-darwin ] - tensorflow: [ i686-linux, x86_64-linux, x86_64-darwin ] term-rewriting: [ i686-linux, x86_64-linux, x86_64-darwin ] termbox-bindings: [ i686-linux, x86_64-linux, x86_64-darwin ] termcolor: [ i686-linux, x86_64-linux, x86_64-darwin ] diff --git a/pkgs/development/haskell-modules/configuration-tensorflow.nix b/pkgs/development/haskell-modules/configuration-tensorflow.nix index dfc93686405c..43a3b82923ba 100644 --- a/pkgs/development/haskell-modules/configuration-tensorflow.nix +++ b/pkgs/development/haskell-modules/configuration-tensorflow.nix @@ -55,13 +55,29 @@ in tensorflow-logging = super.tensorflow-logging.override { inherit proto-lens; }; - tensorflow-mnist = super.tensorflow-mnist.override { + tensorflow-mnist = overrideCabal (super.tensorflow-mnist.override { inherit proto-lens; - }; + # https://github.com/tensorflow/haskell/issues/215 + tensorflow-mnist-input-data = self.tensorflow-mnist-input-data; + }) (_drv: { broken = false; }); tensorflow-mnist-input-data = setSourceRoot "tensorflow-mnist-input-data" (super.callPackage ( { mkDerivation, base, bytestring, Cabal, cryptonite, directory , filepath, HTTP, network-uri, stdenv }: + + let + fileInfos = { + "train-images-idx3-ubyte.gz" = "440fcabf73cc546fa21475e81ea370265605f56be210a4024d2ca8f203523609"; + "train-labels-idx1-ubyte.gz" = "3552534a0a558bbed6aed32b30c495cca23d567ec52cac8be1a0730e8010255c"; + "t10k-images-idx3-ubyte.gz" = "8d422c7b0a1c1c79245a5bcf07fe86e33eeafee792b84584aec276f5a2dbc4e6"; + "t10k-labels-idx1-ubyte.gz" = "f7ae60f92e00ec6debd23a6088c31dbd2371eca3ffa0defaefb259924204aec6"; + }; + downloads = with pkgs.lib; flip mapAttrsToList fileInfos (name: sha256: + pkgs.fetchurl { + url = "http://yann.lecun.com/exdb/mnist/${name}"; + inherit sha256; + }); + in mkDerivation { pname = "tensorflow-mnist-input-data"; version = "0.1.0.0"; @@ -71,6 +87,9 @@ in base bytestring Cabal cryptonite directory filepath HTTP network-uri ]; + preConfigure = pkgs.lib.strings.concatStringsSep "\n" ( + map (x: "ln -s ${x} data/$(stripHash ${x})") downloads + ); libraryHaskellDepends = [ base ]; homepage = "https://github.com/tensorflow/haskell#readme"; description = "Downloader of input data for training MNIST"; diff --git a/pkgs/development/libraries/libtensorflow/default.nix b/pkgs/development/libraries/libtensorflow/default.nix index b4e616409c4f..e6cd140c4e4b 100644 --- a/pkgs/development/libraries/libtensorflow/default.nix +++ b/pkgs/development/libraries/libtensorflow/default.nix @@ -31,19 +31,19 @@ let in stdenv.mkDerivation rec { pname = "libtensorflow"; - version = "1.10.0"; + version = "1.9.0"; name = "${pname}-${version}"; src = fetchurl { url = "https://storage.googleapis.com/tensorflow/${pname}/${pname}-${tfType}-${system}-${version}.tar.gz"; sha256 = if system == "linux-x86_64" then if cudaSupport - then "0v66sscxpyixjrf9yjshl001nix233i6chc61akx0kx7ial4l1wn" - else "11sbpcbgdzj8v17mdppfv7v1fn3nbzkdad60gc42y2j6knjbmwxb" + then "1q3mh06x344im25z7r3vgrfksfdsi8fh8ldn6y2mf86h4d11yxc3" + else "0l9ps115ng5ffzdwphlqmj3jhidps2v5afppdzrbpzmy41xz0z21" else if system == "darwin-x86_64" then if cudaSupport then unavailable - else "11p0f77m4wycpc024mh7jx0kbdhgm0wp6ir6dsa8lkcpdb59bn59" + else "1qj0v1706w6mczycdsh38h2glyv5d25v62kdn98wxd5rw8f9v657" else unavailable; }; |