diff --git a/README.rst b/README.rst index 30396dff99c16..b41bb9c98daba 100644 --- a/README.rst +++ b/README.rst @@ -35,7 +35,7 @@ .. |SciPyMinVersion| replace:: 1.1.0 .. |JoblibMinVersion| replace:: 0.11 .. |ThreadpoolctlMinVersion| replace:: 2.0.0 -.. |MatplotlibMinVersion| replace:: 2.2.2 +.. |MatplotlibMinVersion| replace:: 2.2.3 .. |Scikit-ImageMinVersion| replace:: 0.14.5 .. |PandasMinVersion| replace:: 0.25.0 .. |SeabornMinVersion| replace:: 0.9.0 diff --git a/azure-pipelines.yml b/azure-pipelines.yml index def0a8f98ae9b..19bc8b4efe4df 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -97,8 +97,9 @@ jobs: ) ) matrix: - pylatest_conda_mkl: + pylatest_conda_forge_mkl: DISTRIB: 'conda' + CONDA_CHANNEL: 'conda-forge' PYTHON_VERSION: '*' BLAS: 'mkl' COVERAGE: 'false' @@ -116,8 +117,9 @@ jobs: not(contains(dependencies['git_commit']['outputs']['commit.message'], '[ci skip]')) ) matrix: - pylatest_conda_mkl: + pylatest_conda_forge_mkl: DISTRIB: 'conda' + CONDA_CHANNEL: 'conda-forge' PYTHON_VERSION: '*' BLAS: 'mkl' COVERAGE: 'true' @@ -135,8 +137,9 @@ jobs: ne(variables['Build.Reason'], 'Schedule') ) matrix: - py37_conda: + py37_conda_forge_openblas_ubuntu_1804: DISTRIB: 'conda' + CONDA_CHANNEL: 'conda-forge' PYTHON_VERSION: '3.7' BLAS: 'openblas' COVERAGE: 'false' @@ -164,14 +167,15 @@ jobs: THREADPOOLCTL_VERSION: 'min' COVERAGE: 'false' # Linux + Python 3.7 build with OpenBLAS and without SITE_JOBLIB - py37_conda_openblas: + py37_conda_defaults_openblas: DISTRIB: 'conda' + CONDA_CHANNEL: 'defaults' # Anaconda main channel PYTHON_VERSION: '3.7' BLAS: 'openblas' NUMPY_VERSION: 'min' SCIPY_VERSION: 'min' MATPLOTLIB_VERSION: 'min' - THREADPOOLCTL_VERSION: '2.0.0' + THREADPOOLCTL_VERSION: '2.2.0' # Linux environment to test the latest available dependencies and MKL. # It runs tests requiring lightgbm, pandas and PyAMG. pylatest_pip_openblas_pandas: @@ -206,7 +210,7 @@ jobs: # disable pytest xdist due to unknown bug with 32-bit container PYTEST_XDIST_VERSION: 'none' PYTEST_VERSION: 'min' - THREADPOOLCTL_VERSION: 'min' + THREADPOOLCTL_VERSION: '2.2.0' - template: build_tools/azure/posix.yml parameters: @@ -242,13 +246,14 @@ jobs: ne(variables['Build.Reason'], 'Schedule') ) matrix: - py37_conda_mkl: + py37_conda_forge_mkl: + DISTRIB: 'conda' + CONDA_CHANNEL: 'conda-forge' PYTHON_VERSION: '3.7' CHECK_WARNINGS: 'true' PYTHON_ARCH: '64' PYTEST_VERSION: '*' COVERAGE: 'true' - DISTRIB: 'conda' py37_pip_openblas_32bit: PYTHON_VERSION: '3.7' PYTHON_ARCH: '32' diff --git a/build_tools/azure/install.sh b/build_tools/azure/install.sh index c8bd98ee36b7c..5bd845147b0f3 100755 --- a/build_tools/azure/install.sh +++ b/build_tools/azure/install.sh @@ -16,6 +16,7 @@ make_conda() { if [[ "$DISTRIB" == *"mamba"* ]]; then mamba create -n $VIRTUALENV --yes $TO_INSTALL else + conda config --show conda create -n $VIRTUALENV --yes $TO_INSTALL fi source activate $VIRTUALENV @@ -38,7 +39,7 @@ source build_tools/shared.sh if [[ "$DISTRIB" == "conda" || "$DISTRIB" == *"mamba"* ]]; then if [[ "$CONDA_CHANNEL" != "" ]]; then - TO_INSTALL="-c $CONDA_CHANNEL" + TO_INSTALL="--override-channels -c $CONDA_CHANNEL" else TO_INSTALL="" fi diff --git a/build_tools/azure/test_script.sh b/build_tools/azure/test_script.sh index 6e05d7d858e52..8e8110bcaef04 100755 --- a/build_tools/azure/test_script.sh +++ b/build_tools/azure/test_script.sh @@ -12,18 +12,20 @@ if [[ "$BUILD_WITH_ICC" == "true" ]]; then source /opt/intel/oneapi/setvars.sh fi -python --version -python -c "import numpy; print('numpy %s' % numpy.__version__)" -python -c "import scipy; print('scipy %s' % scipy.__version__)" -python -c "\ -try: - import pandas - print('pandas %s' % pandas.__version__) -except ImportError: - print('pandas not installed') -" -python -c "import multiprocessing as mp; print('%d CPUs' % mp.cpu_count())" -pip list +mkdir -p $TEST_DIR +cp setup.cfg $TEST_DIR +cd $TEST_DIR + +python -c "import sklearn; sklearn.show_versions()" +python -m threadpoolctl -i sklearn + +if ! command -v conda &> /dev/null +then + pip list +else + # conda list provides more info than pip list (when available) + conda list +fi TEST_CMD="python -m pytest --showlocals --durations=20 --junitxml=$JUNITXML" @@ -46,10 +48,6 @@ if [[ "$PYTEST_XDIST_VERSION" != "none" ]]; then TEST_CMD="$TEST_CMD -n2" fi -mkdir -p $TEST_DIR -cp setup.cfg $TEST_DIR -cd $TEST_DIR - set -x $TEST_CMD --pyargs sklearn set +x diff --git a/doc/whats_new/v1.1.rst b/doc/whats_new/v1.1.rst index d75ef4f388110..c4f16f4404963 100644 --- a/doc/whats_new/v1.1.rst +++ b/doc/whats_new/v1.1.rst @@ -16,7 +16,7 @@ Minimal dependencies -------------------- Version 1.1.0 of scikit-learn requires python 3.7+, numpy 1.14.6+ and -scipy 1.1.0+. Optional minimal dependency is matplotlib 2.2.2+. +scipy 1.1.0+. Optional minimal dependency is matplotlib 2.2.3+. Put the changes in their relevant module. diff --git a/sklearn/_min_dependencies.py b/sklearn/_min_dependencies.py index 85a5d8555ae1e..bee904fffa558 100644 --- a/sklearn/_min_dependencies.py +++ b/sklearn/_min_dependencies.py @@ -25,7 +25,7 @@ "joblib": (JOBLIB_MIN_VERSION, "install"), "threadpoolctl": (THREADPOOLCTL_MIN_VERSION, "install"), "cython": (CYTHON_MIN_VERSION, "build"), - "matplotlib": ("2.2.2", "benchmark, docs, examples, tests"), + "matplotlib": ("2.2.3", "benchmark, docs, examples, tests"), "scikit-image": ("0.14.5", "docs, examples, tests"), "pandas": ("0.25.0", "benchmark, docs, examples, tests"), "seaborn": ("0.9.0", "docs, examples"),