From 8272a3239ec06da47d9e54ddb69112383ceb6d3a Mon Sep 17 00:00:00 2001 From: Oleksandr Chychkan Date: Wed, 23 Feb 2022 05:59:57 -0800 Subject: [PATCH] Pre-install numpy for Python 3.10 --- scripts/0_setup.sh | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/scripts/0_setup.sh b/scripts/0_setup.sh index c3ede23..dea6d70 100755 --- a/scripts/0_setup.sh +++ b/scripts/0_setup.sh @@ -32,10 +32,6 @@ python -m pip install --upgrade pip version=$(python -V | cut -f 2 -d ' ' | cut -f 1,2 -d .) reqs_file='requirements.txt' -if [ "$version" == "3.10" ]; then - (cd .dfl/DeepFaceLab; git checkout support-opencv45) -fi - version_suffix='' if [[ ! -z "$version" && -f "requirements_$version.txt" ]]; then version_suffix="_$version" @@ -66,6 +62,11 @@ if is_arm64; then h5py_pkg="$(cat $reqs_file | grep -E 'h5py==.+')" HDF5_DIR="$(brew --prefix hdf5)" pip --no-cache-dir install --no-build-isolation "$h5py_pkg" +elif [ "$version" == "3.10" ]; then + (cd .dfl/DeepFaceLab; git checkout support-opencv45) + + numpy_pkg="$(cat $reqs_file | grep -E 'numpy==.+')" + pip install "$numpy_pkg" fi pip --no-cache-dir install -r $reqs_file