# Contributor: Iztok Fister, Jr. # Maintainer: Iztok Fister, Jr. pkgname=py3-imbalanced-learn _pkgorig=imbalanced-learn pkgver=0.11.0 pkgrel=0 pkgdesc="Toolbox for imbalanced dataset in machine learning" url="https://imbalanced-learn.org" # py3-scikit-learn is missing on s390x arch="noarch !s390x" license="MIT" depends=" py3-numpy py3-pandas py3-scikit-learn py3-scipy " makedepends=" py3-gpep517 py3-setuptools py3-wheel " checkdepends=" py3-pytest py3-pytest-xdist " subpackages="$pkgname-pyc" source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/i/imbalanced-learn/imbalanced-learn-$pkgver.tar.gz exclude-tests.patch" builddir="$srcdir/$_pkgorig-$pkgver" build() { gpep517 build-wheel \ --wheel-dir .dist \ --output-fd 3 3>&1 >&2 } check() { python3 -m venv --clear --without-pip --system-site-packages .testenv .testenv/bin/python3 -m installer .dist/*.whl local skipped_tests=" test_all_estimators and not test_classification_report_imbalanced_multiclass_with_unicode_label and not test_rusboost and not test_cluster_centroids_n_jobs and not test_fit_docstring and not keras and not test_function_sampler_validate and not test_fetch and not check_samplers_preserve_dtype and not test_pipeline_fit_then_sample_with_sampler_last_estimator and not test_pipeline_fit_then_sample_3_samplers_with_sampler_last_estimator" # shellcheck disable=SC2116 .testenv/bin/python3 -m pytest -k "not $(echo $skipped_tests)" -n auto } package() { python3 -m installer -d "$pkgdir" \ .dist/*.whl } sha512sums=" 8788bc6d659402292bde578a0f38fa35b83c63496337a440dbe63294044d503da8876a1492fb9a45bf6283e2d1af3383e08fdcb317ae170c364f71405d643fb6 py3-imbalanced-learn-0.11.0.tar.gz 57a181476c728451b4c54ae535d0f236ac7228b525c8dcbe118bfc8837f1f270fd8185beef59dcbf8fe9c12a67af9c4064339de5df1caf18743c1a4c475db9b0 exclude-tests.patch "