python.pkgs.tensorflow-probability: 0.7 -> 0.8.0
This unbreaks the build by updating to a newer version, adding new dependencies and backporting some patches. 0.9 is released already, but that version is no longer compatible with tf1. 0.8.0 is compatible with tf1 and tf2.
This commit is contained in:
@@ -1,15 +1,18 @@
|
||||
{ lib
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, buildBazelPackage
|
||||
, buildPythonPackage
|
||||
, python
|
||||
, setuptools
|
||||
, wheel
|
||||
, absl-py
|
||||
, tensorflow
|
||||
, six
|
||||
, numpy
|
||||
, decorator
|
||||
, cloudpickle
|
||||
, gast
|
||||
, hypothesis
|
||||
, scipy
|
||||
, matplotlib
|
||||
@@ -18,7 +21,7 @@
|
||||
}:
|
||||
|
||||
let
|
||||
version = "0.7";
|
||||
version = "0.8.0";
|
||||
pname = "tensorflow_probability";
|
||||
|
||||
# first build all binaries and generate setup.py using bazel
|
||||
@@ -28,21 +31,37 @@ let
|
||||
src = fetchFromGitHub {
|
||||
owner = "tensorflow";
|
||||
repo = "probability";
|
||||
rev = "v${version}";
|
||||
sha256 = "0sy9gmjcvmwciamqvd7kd9qw2wd7ksklk80815fsn7sj0wiqxjyd";
|
||||
rev = "${version}";
|
||||
sha256 = "07cm8zba8n0ihzdm3k4a4rsg5v62xxsfvcw4h0niz91c0parqjqy";
|
||||
};
|
||||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
name = "gast-0.3.patch";
|
||||
url = "https://github.com/tensorflow/probability/commit/ae7a9d9771771ec1e7755a3588b9325f050a84cc.patch";
|
||||
sha256 = "0kfhx30gshm8f3945na9yjjik71r20qmjzifbigaj4l8dwd9dz1a";
|
||||
excludes = ["testing/*"];
|
||||
})
|
||||
(fetchpatch {
|
||||
name = "cloudpickle-1.2.patch";
|
||||
url = "https://github.com/tensorflow/probability/commit/78ef12b5afe3f567d16c70b74015ed1ddff1b0c8.patch";
|
||||
sha256 = "12ms2xcljvvrnig0j78s3wfv4yf3bm5ps4rgfgv5lg2a8mzpc1ga";
|
||||
})
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
# needed to create the output wheel in installPhase
|
||||
python
|
||||
setuptools
|
||||
wheel
|
||||
absl-py
|
||||
tensorflow
|
||||
];
|
||||
|
||||
bazelTarget = ":pip_pkg";
|
||||
|
||||
fetchAttrs = {
|
||||
sha256 = "0sjjj9z1dhilhpc8pq4154czrb79z9cm044jvn75kxcjv6v5l2m5";
|
||||
sha256 = "0135nxxvkmjzpd80r1g9fdkk9h62g0xlvp32g5zgk0hkma5kq0bx";
|
||||
};
|
||||
|
||||
buildAttrs = {
|
||||
@@ -75,6 +94,7 @@ in buildPythonPackage {
|
||||
numpy
|
||||
decorator
|
||||
cloudpickle
|
||||
gast
|
||||
];
|
||||
|
||||
# Listed here:
|
||||
|
||||
Reference in New Issue
Block a user