3 |
3 |
|
4 |
4 |
EAPI=8
|
5 |
5 |
|
6 |
|
PYTHON_COMPAT=( python3_{9..10} )
|
|
6 |
DISTUTILS_EXT=1
|
|
7 |
DISTUTILS_USE_PEP517=setuptools
|
|
8 |
PYTHON_COMPAT=( python3_{9..11} )
|
7 |
9 |
|
8 |
10 |
inherit distutils-r1 multiprocessing optfeature pypi
|
9 |
11 |
|
10 |
12 |
DESCRIPTION="Statistical computations and models for use with SciPy"
|
11 |
|
HOMEPAGE="https://www.statsmodels.org/stable/index.html"
|
|
13 |
HOMEPAGE="
|
|
14 |
https://www.statsmodels.org/stable/index.html
|
|
15 |
https://github.com/statsmodels/statsmodels/
|
|
16 |
https://pypi.org/project/statsmodels/
|
|
17 |
"
|
12 |
18 |
|
13 |
19 |
LICENSE="BSD"
|
14 |
20 |
SLOT="0"
|
15 |
|
KEYWORDS="amd64 arm arm64 ~ppc ppc64 ~riscv ~s390 x86 ~amd64-linux ~x86-linux"
|
|
21 |
KEYWORDS="amd64 ~arm arm64 ~ia64 ~ppc ppc64 ~riscv ~s390 ~sparc x86 ~amd64-linux ~x86-linux"
|
16 |
22 |
IUSE="examples"
|
17 |
23 |
|
18 |
24 |
DEPEND="
|
19 |
25 |
>=dev-python/numpy-1.17[${PYTHON_USEDEP}]
|
20 |
|
>=dev-python/scipy-1.3[${PYTHON_USEDEP}]"
|
|
26 |
>=dev-python/scipy-1.3[${PYTHON_USEDEP}]
|
|
27 |
"
|
21 |
28 |
RDEPEND="
|
22 |
29 |
${DEPEND}
|
23 |
30 |
>=dev-python/numpy-1.17[${PYTHON_USEDEP}]
|
... | ... | |
50 |
57 |
export MPLCONFIGDIR="${T}"
|
51 |
58 |
printf -- 'backend : Agg\n' > "${MPLCONFIGDIR}"/matplotlibrc || die
|
52 |
59 |
|
53 |
|
sed -e 's:test_combine:_&:' \
|
54 |
|
-i statsmodels/imputation/tests/test_mice.py || die
|
55 |
|
sed -e 's:test_mixedlm:_&:' \
|
56 |
|
-i statsmodels/stats/tests/test_mediation.py || die
|
57 |
|
|
58 |
60 |
distutils-r1_python_prepare_all
|
59 |
61 |
}
|
60 |
62 |
|
61 |
63 |
python_test() {
|
62 |
64 |
local -x MKL_NUM_THREADS=1
|
63 |
65 |
local -x OMP_NUM_THREADS=1
|
64 |
|
local jobs=$(makeopts_jobs "${MAKEOPTS}" "$(get_nproc)")
|
|
66 |
local EPYTEST_DESELECT=(
|
|
67 |
# note that test path should be without "statsmodels/" prefix
|
|
68 |
imputation/tests/test_mice.py::TestMICE::test_combine
|
|
69 |
stats/tests/test_mediation.py::test_mixedlm
|
|
70 |
"stats/tests/test_corrpsd.py::test_corrpsd_threshold[0]"
|
|
71 |
)
|
65 |
72 |
|
66 |
|
pushd "${BUILD_DIR}" >/dev/null || die
|
67 |
|
"${EPYTHON}" -c "
|
68 |
|
import statsmodels
|
69 |
|
statsmodels.test(extra_args=['-vv', '-n', '${jobs}'], exit=True)" \
|
70 |
|
|| die "tests fail with ${EPYTHON}"
|
71 |
|
rm -rf statsmodels/.pytest_cache || die
|
72 |
|
popd >/dev/null || die
|
|
73 |
cd "${BUILD_DIR}/install$(python_get_sitedir)" || die
|
|
74 |
epytest ${PN} -n "$(makeopts_jobs)"
|
|
75 |
rm -r ${PN}/.pytest_cache || die
|
73 |
76 |
}
|
74 |
77 |
|
75 |
78 |
python_install_all() {
|