diff options
author | Butui Hu | 2019-11-18 17:38:41 +0800 |
---|---|---|
committer | Butui Hu | 2019-11-18 17:38:41 +0800 |
commit | 91b720d119f243a9507023d439f0cf29b127e1c6 (patch) | |
tree | c3fdda7e81ecb9770b3d2efcb695427191c286e3 /PKGBUILD | |
download | aur-91b720d119f243a9507023d439f0cf29b127e1c6.tar.gz |
add python-batchgenerators
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..ff54196875ac --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,40 @@ +# Maintainer: Butui Hu <hot123tea123@gmail.com> + +_pkgname=batchgenerators +pkgname=python-batchgenerators +pkgver=0.19.5 +pkgrel=1 +pkgdesc='A framework for data augmentation for 2D and 3D image classification and segmentation' +arch=('any') +url='https://github.com/MIC-DKFZ/batchgenerators' +license=('Apache') +depends=( + 'python-numpy' + 'python-scikit-image' + 'python-scikit-learn' + 'python-scipy' + 'python-threadpoolctl' +) +makedepends=( + 'python-setuptools' +) +source=("${_pkgname}-${pkgver}.tar.gz::https://github.com/MIC-DKFZ/batchgenerators/archive/v${pkgver}.tar.gz") +sha512sums=('aa70b531b65c417e7ce30521b706c79f1677281f96389876e38800cb2e1a884fef4095d5aec969af3eee731880daee36c5e6b96e6bccd038bcb250996e7035ca') + +get_pyver () { + python -c 'import sys; print(str(sys.version_info[0]) + "." + str(sys.version_info[1]))' +} + +build() { + cd "${_pkgname}-${pkgver}" + python setup.py build +} + +package() { + cd "${_pkgname}-${pkgver}" + python setup.py install --root="${pkgdir}" --optimize=1 --skip-build + install -Dm644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}" + # delete test files + rm -rfv "${pkgdir}/usr/lib/python$(get_pyver)/site-packages/tests" +} +# vim:set ts=2 sw=2 et: |