Merge pull request #5743 from smalltalkman/mingw-w64-python-keras
python-keras: Update to 2.2.5
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
--- keras-2.2.4.orig/keras/backend/__init__.py 2019-01-21 14:13:39.446288200 +0800
|
||||
+++ keras-2.2.4/keras/backend/__init__.py 2019-01-21 14:14:43.204935000 +0800
|
||||
@@ -23,8 +23,8 @@
|
||||
diff --git a/keras/backend/load_backend.py b/keras/backend/load_backend.py
|
||||
index 4942f613d..f7256b191 100644
|
||||
--- a/keras/backend/load_backend.py
|
||||
+++ b/keras/backend/load_backend.py
|
||||
@@ -23,8 +23,8 @@ else:
|
||||
_keras_base_dir = '/tmp'
|
||||
_keras_dir = os.path.join(_keras_base_dir, '.keras')
|
||||
|
||||
|
||||
@@ -3,21 +3,21 @@
|
||||
_realname=keras
|
||||
pkgbase=mingw-w64-python-${_realname}
|
||||
pkgname=("${MINGW_PACKAGE_PREFIX}-python2-${_realname}" "${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
|
||||
pkgver=2.2.4
|
||||
pkgver=2.2.5
|
||||
pkgrel=1
|
||||
pkgdesc="Keras is a high-level neural networks API, written in Python and capable of running on top of TensorFlow, CNTK, or Theano. (mingw-w64)"
|
||||
arch=('any')
|
||||
url="http://keras.io/"
|
||||
license=('MIT')
|
||||
_archive=${_realname}-${pkgver}
|
||||
source=(${_archive}.tar.gz::https://github.com/keras-team/keras/archive/${pkgver}.tar.gz
|
||||
makedepends=("patch"
|
||||
"${MINGW_PACKAGE_PREFIX}-python3-setuptools"
|
||||
"${MINGW_PACKAGE_PREFIX}-python2-setuptools")
|
||||
source=(${_realname}-${pkgver}.tar.gz::https://github.com/keras-team/keras/archive/${pkgver}.tar.gz
|
||||
0001-change-backend-to-theano.patch)
|
||||
sha256sums=('46F8E5BD66F778ABD8D5A62B3C3D749FBD41854176FCF0DF5258CF94C3FD1B28'
|
||||
'13CEDF9FD8636A3AC472671B8F07D118F6708BDD63CE3F3614923C18B35E3D7D')
|
||||
sha256sums=('149c281194976e2799bea423d192d8520606d5ddec5bf776d7dd30244f67d94f'
|
||||
'2e53d3c474d0d797ef7c6faf3ecdc77dfe123fa43bd19a151caaf894baadb47e')
|
||||
|
||||
_deps=('numpy' 'scipy' 'six' 'yaml' 'h5py' 'keras_applications' 'keras_preprocessing' 'theano')
|
||||
makedepends=("${MINGW_PACKAGE_PREFIX}-python3-setuptools"
|
||||
"${MINGW_PACKAGE_PREFIX}-python2-setuptools")
|
||||
|
||||
# Helper macros to help make tasks easier #
|
||||
apply_patch_with_msg() {
|
||||
@@ -29,7 +29,7 @@ apply_patch_with_msg() {
|
||||
}
|
||||
|
||||
prepare() {
|
||||
cd "${srcdir}/${_archive}"
|
||||
cd "${srcdir}/${_realname}-${pkgver}"
|
||||
apply_patch_with_msg \
|
||||
0001-change-backend-to-theano.patch
|
||||
}
|
||||
@@ -38,9 +38,9 @@ build() {
|
||||
cd "${srcdir}"
|
||||
rm -rf python{2,3}-build
|
||||
for builddir in python{2,3}-build; do
|
||||
cp -r ${_archive} ${builddir}
|
||||
cp -r ${_realname}-${pkgver} ${builddir}
|
||||
pushd $builddir
|
||||
${MINGW_PREFIX}/bin/${builddir%-build} setup.py build
|
||||
${MINGW_PREFIX}/bin/${builddir%-build} setup.py --quiet build
|
||||
popd
|
||||
done
|
||||
}
|
||||
@@ -50,7 +50,7 @@ package_python3-keras() {
|
||||
|
||||
cd "${srcdir}/python3-build"
|
||||
MSYS2_ARG_CONV_EXCL="--prefix=;--install-scripts=;--install-platlib=" \
|
||||
${MINGW_PREFIX}/bin/python3 setup.py install --prefix=${MINGW_PREFIX} --root="${pkgdir}" -O1
|
||||
${MINGW_PREFIX}/bin/python3 setup.py --quiet install --prefix=${MINGW_PREFIX} --root="${pkgdir}" -O1
|
||||
|
||||
install -Dm644 LICENSE "${pkgdir}${MINGW_PREFIX}/share/licenses/python3-${_realname}/LICENSE"
|
||||
}
|
||||
@@ -60,7 +60,7 @@ package_python2-keras() {
|
||||
|
||||
cd "${srcdir}/python2-build"
|
||||
MSYS2_ARG_CONV_EXCL="--prefix=;--install-scripts=;--install-platlib=" \
|
||||
${MINGW_PREFIX}/bin/python2 setup.py install --prefix=${MINGW_PREFIX} --root="${pkgdir}" -O1
|
||||
${MINGW_PREFIX}/bin/python2 setup.py --quiet install --prefix=${MINGW_PREFIX} --root="${pkgdir}" -O1
|
||||
|
||||
install -Dm644 LICENSE "${pkgdir}${MINGW_PREFIX}/share/licenses/python2-${_realname}/LICENSE"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user