git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #54934 from dotlambda/keras-preprocessing-1.0.6

python.pkgs.keras-preprocessing: 1.0.5 -> 1.0.8

commit62dedf12649dcb047029c7265b2b46446752af04 authorRobert Schütz <rschuetz17@gmail.com> dateFri 1 Feb 2019, 14:08 (8 years ago) parentc8e56dd677f8c1
2 files changed+17−17
pkgs/development/python-modules/keras-preprocessing/default.nix+17−9 pkgs/development/python-modules/keras/default.nix−8
pkgs/development/python-modules/keras-preprocessing/default.nix+17−9
@@ -1,24 +1,32 @@
1−{ lib, buildPythonPackage, fetchPypi, numpy, scipy, six }:
1+{ lib, buildPythonPackage, fetchPypi, numpy, six, scipy, pillow, pytest, Keras }:
22
33buildPythonPackage rec {
44 pname = "Keras_Preprocessing";
5− version = "1.0.5";
5+ version = "1.0.8";
66
77 src = fetchPypi {
88 inherit pname version;
9− sha256 = "ef2e482c4336fcf7180244d06f4374939099daa3183816e82aee7755af35b754";
9+ sha256 = "6e669aa713727f0bc08f756616f64e0dfa75d822226cfc0dcf33297ab05cef7d";
1010 };
1111
12− # Cyclic dependency: keras-preprocessing requires keras, which requires keras-preprocessing
13− postPatch = ''
14− sed -i "s/keras>=[^']*//" setup.py
12+ propagatedBuildInputs = [
13+ # required
14+ numpy six
15+ # optional
16+ scipy pillow
17+ ];
18+
19+ checkInputs = [
20+ pytest Keras
21+ ];
22+
23+ checkPhase = ''
24+ py.test tests/
1525 '';
1626
17− # No tests in PyPI tarball
27+ # Cyclic dependency: keras-preprocessing's tests require Keras, which requires keras-preprocessing
1828 doCheck = false;
1929
20− propagatedBuildInputs = [ numpy scipy six ];
21−
2230 meta = with lib; {
2331 description = "Easy data preprocessing and data augmentation for deep learning models";
2432 homepage = https://github.com/keras-team/keras-preprocessing;
pkgs/development/python-modules/keras/default.nix−8
@@ -25,14 +25,6 @@ buildPythonPackage rec {
2525 keras-applications keras-preprocessing
2626 ];
2727
28− # Keras 2.2.2 expects older versions of keras_applications
29− # and keras_preprocessing. These substitutions can be removed
30− # for for the next Keras release.
31− postPatch = ''
32− substituteInPlace setup.py --replace "keras_applications==1.0.4" "keras_applications==1.0.5"
33− substituteInPlace setup.py --replace "keras_preprocessing==1.0.2" "keras_preprocessing==1.0.3"
34− '';
35−
3628 # Couldn't get tests working
3729 doCheck = false;
3830