From 90dc16b81a36dd74861d8fb790b89b18202c9be2 Mon Sep 17 00:00:00 2001 From: Oleksandr Chychkan Date: Wed, 23 Feb 2022 07:13:56 -0800 Subject: [PATCH] Add requirements file for Python 3.10 (#49) * Add requirements file for Python 10 * Add Python 3.10 to GitHub Actions * Upgrade opencv-contrib-python-headless to 4.5.4.58 for Python 10 * Upgrade scipy to 1.7.2 for Python 3.10 * Upgrade multiple deps * Use custom DFL branch for python 3.10 * Pre-install numpy for Python 3.10 * Switch to opencv-python --- .github/workflows/verify-setup-catalina.yml | 2 +- requirements_3.10.txt | 12 ++++++++++++ scripts/0_setup.sh | 5 +++++ 3 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 requirements_3.10.txt diff --git a/.github/workflows/verify-setup-catalina.yml b/.github/workflows/verify-setup-catalina.yml index e7502b1..6a454f8 100644 --- a/.github/workflows/verify-setup-catalina.yml +++ b/.github/workflows/verify-setup-catalina.yml @@ -16,7 +16,7 @@ jobs: strategy: fail-fast: true matrix: - python-version: [3.6, 3.7, 3.8, 3.9] + python-version: ["3.6", "3.7", "3.8", "3.9", "3.10"] steps: - uses: actions/checkout@v2 diff --git a/requirements_3.10.txt b/requirements_3.10.txt new file mode 100644 index 0000000..bea7808 --- /dev/null +++ b/requirements_3.10.txt @@ -0,0 +1,12 @@ +numpy==1.22.2 +numexpr==2.8.1 +opencv-python==4.5.5.62 +scipy==1.8.0 +tensorflow==2.8.0 +colorama==0.4.4 +tqdm==4.62.3 +ffmpeg-python==0.2.0 +Pillow==8.4.0 +scikit-image==0.19.2 +h5py==3.6.0 +PyQt5==5.15.4 diff --git a/scripts/0_setup.sh b/scripts/0_setup.sh index 54b5d31..dea6d70 100755 --- a/scripts/0_setup.sh +++ b/scripts/0_setup.sh @@ -62,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