Commit 60af60a8 authored by Wei Wang's avatar Wei Wang Committed by Facebook GitHub Bot
Browse files

Drop python 3.7 support (#3020)

Summary:
https://github.com/pytorch/pytorch/pull/93155 Core has dropped python3.7

Pull Request resolved: https://github.com/pytorch/audio/pull/3020

Reviewed By: mthrok

Differential Revision: D42902346

Pulled By: weiwangmeta

fbshipit-source-id: 07ab1aff0e128c5960d87e5fa29e341310dea388
parent 0709cadc
...@@ -108,7 +108,7 @@ jobs: ...@@ -108,7 +108,7 @@ jobs:
lint_python_and_config: lint_python_and_config:
docker: docker:
- image: circleci/python:3.7 - image: circleci/python:3.8
steps: steps:
- checkout - checkout
- run: - run:
...@@ -615,7 +615,7 @@ jobs: ...@@ -615,7 +615,7 @@ jobs:
conda activate python${PYTHON_VERSION} conda activate python${PYTHON_VERSION}
# Hack to load FFmpeg libraries # Hack to load FFmpeg libraries
# Note: Depending on Python version, they search different paths. # Note: Depending on Python version, they search different paths.
# For 3.7 and 3.9, copying them in CWD works. # For 3.9, copying them in CWD works.
cp ~/workspace/ffmpeg/bin/* test/smoke_test/ cp ~/workspace/ffmpeg/bin/* test/smoke_test/
# For 3.8 and 3.10, they must be in the same directory as the entrypoint lib # For 3.8 and 3.10, they must be in the same directory as the entrypoint lib
cp ~/workspace/ffmpeg/bin/* /C/tools/miniconda3/envs/python${PYTHON_VERSION}/lib/site-packages/torchaudio/lib/ cp ~/workspace/ffmpeg/bin/* /C/tools/miniconda3/envs/python${PYTHON_VERSION}/lib/site-packages/torchaudio/lib/
...@@ -931,57 +931,6 @@ workflows: ...@@ -931,57 +931,6 @@ workflows:
python_version: foo python_version: foo
requires: requires:
- download_third_parties - download_third_parties
- binary_windows_wheel:
cuda_version: cpu
name: binary_windows_wheel_py3.7_cpu
python_version: '3.7'
requires:
- build_ffmpeg_windows
- smoke_test_windows_pip:
cuda_version: cpu
name: binary_windows_wheel_py3.7_cpu_smoke_test_pip
python_version: '3.7'
requires:
- binary_windows_wheel_py3.7_cpu
- binary_windows_wheel:
cuda_version: cu116
name: binary_windows_wheel_py3.7_cu116
python_version: '3.7'
requires:
- build_ffmpeg_windows
wheel_docker_image: pytorch/manylinux-cuda116
- smoke_test_windows_pip:
cuda_version: cu116
name: binary_windows_wheel_py3.7_cu116_smoke_test_pip
python_version: '3.7'
requires:
- binary_windows_wheel_py3.7_cu116
- binary_windows_wheel:
cuda_version: cu117
name: binary_windows_wheel_py3.7_cu117
python_version: '3.7'
requires:
- build_ffmpeg_windows
wheel_docker_image: pytorch/manylinux-cuda117
- smoke_test_windows_pip:
cuda_version: cu117
name: binary_windows_wheel_py3.7_cu117_smoke_test_pip
python_version: '3.7'
requires:
- binary_windows_wheel_py3.7_cu117
- binary_windows_wheel:
cuda_version: cu118
name: binary_windows_wheel_py3.7_cu118
python_version: '3.7'
requires:
- build_ffmpeg_windows
wheel_docker_image: pytorch/manylinux-cuda118
- smoke_test_windows_pip:
cuda_version: cu118
name: binary_windows_wheel_py3.7_cu118_smoke_test_pip
python_version: '3.7'
requires:
- binary_windows_wheel_py3.7_cu118
- binary_windows_wheel: - binary_windows_wheel:
cuda_version: cpu cuda_version: cpu
name: binary_windows_wheel_py3.8_cpu name: binary_windows_wheel_py3.8_cpu
...@@ -1148,13 +1097,6 @@ workflows: ...@@ -1148,13 +1097,6 @@ workflows:
python_version: '3.8' python_version: '3.8'
requires: requires:
- binary_linux_conda_py3.8_cu116 - binary_linux_conda_py3.8_cu116
- binary_macos_conda:
conda_docker_image: pytorch/conda-builder:cpu
cuda_version: cpu
name: binary_macos_conda_py3.7_cpu
python_version: '3.7'
requires:
- build_ffmpeg_macos
- binary_macos_conda: - binary_macos_conda:
conda_docker_image: pytorch/conda-builder:cpu conda_docker_image: pytorch/conda-builder:cpu
cuda_version: cpu cuda_version: cpu
...@@ -1176,58 +1118,6 @@ workflows: ...@@ -1176,58 +1118,6 @@ workflows:
python_version: '3.10' python_version: '3.10'
requires: requires:
- build_ffmpeg_macos - build_ffmpeg_macos
- binary_windows_conda:
conda_docker_image: pytorch/conda-builder:cpu
cuda_version: cpu
name: binary_windows_conda_py3.7_cpu
python_version: '3.7'
requires:
- build_ffmpeg_windows
- smoke_test_windows_conda:
cuda_version: cpu
name: binary_windows_conda_py3.7_cpu_smoke_test_conda
python_version: '3.7'
requires:
- binary_windows_conda_py3.7_cpu
- binary_windows_conda:
conda_docker_image: pytorch/conda-builder:cuda116
cuda_version: cu116
name: binary_windows_conda_py3.7_cu116
python_version: '3.7'
requires:
- build_ffmpeg_windows
- smoke_test_windows_conda_gpu:
cuda_version: cu116
name: binary_windows_conda_py3.7_cu116_smoke_test_conda
python_version: '3.7'
requires:
- binary_windows_conda_py3.7_cu116
- binary_windows_conda:
conda_docker_image: pytorch/conda-builder:cuda117
cuda_version: cu117
name: binary_windows_conda_py3.7_cu117
python_version: '3.7'
requires:
- build_ffmpeg_windows
- smoke_test_windows_conda_gpu:
cuda_version: cu117
name: binary_windows_conda_py3.7_cu117_smoke_test_conda
python_version: '3.7'
requires:
- binary_windows_conda_py3.7_cu117
- binary_windows_conda:
conda_docker_image: pytorch/conda-builder:cuda118
cuda_version: cu118
name: binary_windows_conda_py3.7_cu118
python_version: '3.7'
requires:
- build_ffmpeg_windows
- smoke_test_windows_conda_gpu:
cuda_version: cu118
name: binary_windows_conda_py3.7_cu118_smoke_test_conda
python_version: '3.7'
requires:
- binary_windows_conda_py3.7_cu118
- binary_windows_conda: - binary_windows_conda:
conda_docker_image: pytorch/conda-builder:cpu conda_docker_image: pytorch/conda-builder:cpu
cuda_version: cpu cuda_version: cpu
...@@ -1414,20 +1304,14 @@ workflows: ...@@ -1414,20 +1304,14 @@ workflows:
name: download_third_parties name: download_third_parties
- unittest_linux_cpu: - unittest_linux_cpu:
cuda_version: cpu cuda_version: cpu
name: unittest_linux_cpu_py3.7 name: unittest_linux_cpu_py3.8
python_version: '3.7' python_version: '3.8'
requires: requires:
- download_third_parties - download_third_parties
- stylecheck: - stylecheck:
cuda_version: cpu cuda_version: cpu
name: stylecheck_py3.7 name: stylecheck_py3.8
python_version: '3.7'
- unittest_linux_cpu:
cuda_version: cpu
name: unittest_linux_cpu_py3.8
python_version: '3.8' python_version: '3.8'
requires:
- download_third_parties
- unittest_linux_cpu: - unittest_linux_cpu:
cuda_version: cpu cuda_version: cpu
name: unittest_linux_cpu_py3.9 name: unittest_linux_cpu_py3.9
...@@ -1440,12 +1324,6 @@ workflows: ...@@ -1440,12 +1324,6 @@ workflows:
python_version: '3.10' python_version: '3.10'
requires: requires:
- download_third_parties - download_third_parties
- unittest_linux_gpu:
cuda_version: cu116
name: unittest_linux_gpu_py3.7
python_version: '3.7'
requires:
- download_third_parties
- unittest_linux_gpu: - unittest_linux_gpu:
cuda_version: cu116 cuda_version: cu116
name: unittest_linux_gpu_py3.8 name: unittest_linux_gpu_py3.8
...@@ -1466,20 +1344,20 @@ workflows: ...@@ -1466,20 +1344,20 @@ workflows:
- download_third_parties - download_third_parties
- unittest_windows_cpu: - unittest_windows_cpu:
cuda_version: cpu cuda_version: cpu
name: unittest_windows_cpu_py3.7 name: unittest_windows_cpu_py3.8
python_version: '3.7' python_version: '3.8'
requires: requires:
- download_third_parties - download_third_parties
- unittest_windows_gpu: - unittest_windows_gpu:
cuda_version: cu116 cuda_version: cu116
name: unittest_windows_gpu_py3.7 name: unittest_windows_gpu_py3.8
python_version: '3.7' python_version: '3.8'
requires: requires:
- download_third_parties - download_third_parties
- unittest_macos_cpu: - unittest_macos_cpu:
cuda_version: cpu cuda_version: cpu
name: unittest_macos_cpu_py3.7 name: unittest_macos_cpu_py3.8
python_version: '3.7' python_version: '3.8'
requires: requires:
- download_third_parties - download_third_parties
nightly: nightly:
...@@ -1529,153 +1407,6 @@ workflows: ...@@ -1529,153 +1407,6 @@ workflows:
python_version: foo python_version: foo
requires: requires:
- download_third_parties - download_third_parties
- binary_windows_wheel:
cuda_version: cpu
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cpu
python_version: '3.7'
requires:
- build_ffmpeg_windows
- binary_wheel_upload:
context: org-member
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cpu_upload
requires:
- nightly_binary_windows_wheel_py3.7_cpu
subfolder: cpu/
- smoke_test_windows_pip:
cuda_version: cpu
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cpu_smoke_test_pip
python_version: '3.7'
requires:
- nightly_binary_windows_wheel_py3.7_cpu
- binary_windows_wheel:
cuda_version: cu116
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cu116
python_version: '3.7'
requires:
- build_ffmpeg_windows
wheel_docker_image: pytorch/manylinux-cuda116
- binary_wheel_upload:
context: org-member
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cu116_upload
requires:
- nightly_binary_windows_wheel_py3.7_cu116
subfolder: cu116/
- smoke_test_windows_pip:
cuda_version: cu116
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cu116_smoke_test_pip
python_version: '3.7'
requires:
- nightly_binary_windows_wheel_py3.7_cu116
- binary_windows_wheel:
cuda_version: cu117
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cu117
python_version: '3.7'
requires:
- build_ffmpeg_windows
wheel_docker_image: pytorch/manylinux-cuda117
- binary_wheel_upload:
context: org-member
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cu117_upload
requires:
- nightly_binary_windows_wheel_py3.7_cu117
subfolder: cu117/
- smoke_test_windows_pip:
cuda_version: cu117
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cu117_smoke_test_pip
python_version: '3.7'
requires:
- nightly_binary_windows_wheel_py3.7_cu117
- binary_windows_wheel:
cuda_version: cu118
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cu118
python_version: '3.7'
requires:
- build_ffmpeg_windows
wheel_docker_image: pytorch/manylinux-cuda118
- binary_wheel_upload:
context: org-member
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cu118_upload
requires:
- nightly_binary_windows_wheel_py3.7_cu118
subfolder: cu118/
- smoke_test_windows_pip:
cuda_version: cu118
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_wheel_py3.7_cu118_smoke_test_pip
python_version: '3.7'
requires:
- nightly_binary_windows_wheel_py3.7_cu118
- binary_windows_wheel: - binary_windows_wheel:
cuda_version: cpu cuda_version: cpu
filters: filters:
...@@ -2142,30 +1873,6 @@ workflows: ...@@ -2142,30 +1873,6 @@ workflows:
python_version: '3.8' python_version: '3.8'
requires: requires:
- nightly_binary_linux_conda_py3.8_cu116 - nightly_binary_linux_conda_py3.8_cu116
- binary_macos_conda:
conda_docker_image: pytorch/conda-builder:cpu
cuda_version: cpu
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_macos_conda_py3.7_cpu
python_version: '3.7'
requires:
- build_ffmpeg_macos
- binary_conda_upload:
context: org-member
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_macos_conda_py3.7_cpu_upload
requires:
- nightly_binary_macos_conda_py3.7_cpu
- binary_macos_conda: - binary_macos_conda:
conda_docker_image: pytorch/conda-builder:cpu conda_docker_image: pytorch/conda-builder:cpu
cuda_version: cpu cuda_version: cpu
...@@ -2238,150 +1945,6 @@ workflows: ...@@ -2238,150 +1945,6 @@ workflows:
name: nightly_binary_macos_conda_py3.10_cpu_upload name: nightly_binary_macos_conda_py3.10_cpu_upload
requires: requires:
- nightly_binary_macos_conda_py3.10_cpu - nightly_binary_macos_conda_py3.10_cpu
- binary_windows_conda:
conda_docker_image: pytorch/conda-builder:cpu
cuda_version: cpu
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cpu
python_version: '3.7'
requires:
- build_ffmpeg_windows
- binary_conda_upload:
context: org-member
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cpu_upload
requires:
- nightly_binary_windows_conda_py3.7_cpu
- smoke_test_windows_conda:
cuda_version: cpu
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cpu_smoke_test_conda
python_version: '3.7'
requires:
- nightly_binary_windows_conda_py3.7_cpu
- binary_windows_conda:
conda_docker_image: pytorch/conda-builder:cuda116
cuda_version: cu116
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cu116
python_version: '3.7'
requires:
- build_ffmpeg_windows
- binary_conda_upload:
context: org-member
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cu116_upload
requires:
- nightly_binary_windows_conda_py3.7_cu116
- smoke_test_windows_conda_gpu:
cuda_version: cu116
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cu116_smoke_test_conda
python_version: '3.7'
requires:
- nightly_binary_windows_conda_py3.7_cu116
- binary_windows_conda:
conda_docker_image: pytorch/conda-builder:cuda117
cuda_version: cu117
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cu117
python_version: '3.7'
requires:
- build_ffmpeg_windows
- binary_conda_upload:
context: org-member
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cu117_upload
requires:
- nightly_binary_windows_conda_py3.7_cu117
- smoke_test_windows_conda_gpu:
cuda_version: cu117
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cu117_smoke_test_conda
python_version: '3.7'
requires:
- nightly_binary_windows_conda_py3.7_cu117
- binary_windows_conda:
conda_docker_image: pytorch/conda-builder:cuda118
cuda_version: cu118
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cu118
python_version: '3.7'
requires:
- build_ffmpeg_windows
- binary_conda_upload:
context: org-member
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cu118_upload
requires:
- nightly_binary_windows_conda_py3.7_cu118
- smoke_test_windows_conda_gpu:
cuda_version: cu118
filters:
branches:
only:
- nightly
tags:
only: /v[0-9]+(\.[0-9]+)*-rc[0-9]+/
name: nightly_binary_windows_conda_py3.7_cu118_smoke_test_conda
python_version: '3.7'
requires:
- nightly_binary_windows_conda_py3.7_cu118
- binary_windows_conda: - binary_windows_conda:
conda_docker_image: pytorch/conda-builder:cpu conda_docker_image: pytorch/conda-builder:cpu
cuda_version: cpu cuda_version: cpu
......
...@@ -108,7 +108,7 @@ jobs: ...@@ -108,7 +108,7 @@ jobs:
lint_python_and_config: lint_python_and_config:
docker: docker:
- image: circleci/python:3.7 - image: circleci/python:3.8
steps: steps:
- checkout - checkout
- run: - run:
...@@ -615,7 +615,7 @@ jobs: ...@@ -615,7 +615,7 @@ jobs:
conda activate python${PYTHON_VERSION} conda activate python${PYTHON_VERSION}
# Hack to load FFmpeg libraries # Hack to load FFmpeg libraries
# Note: Depending on Python version, they search different paths. # Note: Depending on Python version, they search different paths.
# For 3.7 and 3.9, copying them in CWD works. # For 3.9, copying them in CWD works.
cp ~/workspace/ffmpeg/bin/* test/smoke_test/ cp ~/workspace/ffmpeg/bin/* test/smoke_test/
# For 3.8 and 3.10, they must be in the same directory as the entrypoint lib # For 3.8 and 3.10, they must be in the same directory as the entrypoint lib
cp ~/workspace/ffmpeg/bin/* /C/tools/miniconda3/envs/python${PYTHON_VERSION}/lib/site-packages/torchaudio/lib/ cp ~/workspace/ffmpeg/bin/* /C/tools/miniconda3/envs/python${PYTHON_VERSION}/lib/site-packages/torchaudio/lib/
......
...@@ -21,7 +21,7 @@ import yaml ...@@ -21,7 +21,7 @@ import yaml
from jinja2 import select_autoescape from jinja2 import select_autoescape
PYTHON_VERSIONS = ["3.7", "3.8", "3.9", "3.10"] PYTHON_VERSIONS = ["3.8", "3.9", "3.10"]
CU_VERSIONS_DICT = { CU_VERSIONS_DICT = {
"linux": ["cpu", "cu116", "cu117", "cu118", "rocm5.2", "rocm5.3"], "linux": ["cpu", "cu116", "cu117", "cu118", "rocm5.2", "rocm5.3"],
"windows": ["cpu", "cu116", "cu117", "cu118"], "windows": ["cpu", "cu116", "cu117", "cu118"],
......
...@@ -22,14 +22,12 @@ RUN apt-get -qq update && apt-get -qq -y install curl bzip2 sox libsox-dev libso ...@@ -22,14 +22,12 @@ RUN apt-get -qq update && apt-get -qq -y install curl bzip2 sox libsox-dev libso
ENV PATH /opt/conda/bin:$PATH ENV PATH /opt/conda/bin:$PATH
RUN conda create -y --name python3.7 python=3.7
RUN conda create -y --name python3.8 python=3.8 RUN conda create -y --name python3.8 python=3.8
RUN conda create -y --name python3.9 python=3.9 RUN conda create -y --name python3.9 python=3.9
RUN conda create -y --name python3.10 python=3.10 RUN conda create -y --name python3.10 python=3.10
SHELL [ "/bin/bash", "-c" ] SHELL [ "/bin/bash", "-c" ]
RUN echo "source /usr/local/etc/profile.d/conda.sh" >> ~/.bashrc RUN echo "source /usr/local/etc/profile.d/conda.sh" >> ~/.bashrc
RUN source /usr/local/etc/profile.d/conda.sh && conda activate python3.7 && conda install -y -c conda-forge sox && conda install -y numpy
RUN source /usr/local/etc/profile.d/conda.sh && conda activate python3.8 && conda install -y -c conda-forge sox && conda install -y numpy RUN source /usr/local/etc/profile.d/conda.sh && conda activate python3.8 && conda install -y -c conda-forge sox && conda install -y numpy
RUN source /usr/local/etc/profile.d/conda.sh && conda activate python3.9 && conda install -y -c conda-forge sox && conda install -y numpy RUN source /usr/local/etc/profile.d/conda.sh && conda activate python3.9 && conda install -y -c conda-forge sox && conda install -y numpy
RUN source /usr/local/etc/profile.d/conda.sh && conda activate python3.10 && conda install -y -c conda-forge sox && conda install -y numpy RUN source /usr/local/etc/profile.d/conda.sh && conda activate python3.10 && conda install -y -c conda-forge sox && conda install -y numpy
......
...@@ -35,7 +35,7 @@ The following are the corresponding ``torchaudio`` versions and supported Python ...@@ -35,7 +35,7 @@ The following are the corresponding ``torchaudio`` versions and supported Python
| | ``torch`` | ``torchaudio`` | ``python`` | | | ``torch`` | ``torchaudio`` | ``python`` |
| ----------- | ------------------------ | ------------------------ | ------------------------------- | | ----------- | ------------------------ | ------------------------ | ------------------------------- |
| Development | ``master`` / ``nightly`` | ``main`` / ``nightly`` | ``>=3.7``, ``<=3.10`` | | Development | ``master`` / ``nightly`` | ``main`` / ``nightly`` | ``>=3.8``, ``<=3.10`` |
| Latest versioned release | ``1.13.1`` | ``0.13.1`` | ``>=3.7``, ``<=3.10`` | | Latest versioned release | ``1.13.1`` | ``0.13.1`` | ``>=3.7``, ``<=3.10`` |
<details><summary>Previous versions</summary> <details><summary>Previous versions</summary>
......
...@@ -157,7 +157,7 @@ retry () { ...@@ -157,7 +157,7 @@ retry () {
} }
# Inputs: # Inputs:
# PYTHON_VERSION (2.7, 3.5, 3.6, 3.7) # PYTHON_VERSION (3.8, 3.9, 3.10)
# UNICODE_ABI (bool) # UNICODE_ABI (bool)
# #
# Outputs: # Outputs:
...@@ -173,7 +173,6 @@ setup_wheel_python() { ...@@ -173,7 +173,6 @@ setup_wheel_python() {
conda install --quiet -y pkg-config conda install --quiet -y pkg-config
else else
case "$PYTHON_VERSION" in case "$PYTHON_VERSION" in
3.7) python_abi=cp37-cp37m ;;
3.8) python_abi=cp38-cp38 ;; 3.8) python_abi=cp38-cp38 ;;
3.9) python_abi=cp39-cp39 ;; 3.9) python_abi=cp39-cp39 ;;
3.10) python_abi=cp310-cp310 ;; 3.10) python_abi=cp310-cp310 ;;
......
...@@ -5,7 +5,7 @@ c_compiler: ...@@ -5,7 +5,7 @@ c_compiler:
cxx_compiler: cxx_compiler:
- vs2019 # [win] - vs2019 # [win]
python: python:
- 3.7 - 3.8
# This differs from target_platform in that it determines what subdir the compiler # This differs from target_platform in that it determines what subdir the compiler
# will target, not what subdir the compiler package will be itself. # will target, not what subdir the compiler package will be itself.
# For example, we need a win-64 vs2008_win-32 package, so that we compile win-32 # For example, we need a win-64 vs2008_win-32 package, so that we compile win-32
......
...@@ -5,6 +5,6 @@ first_party_detection = false ...@@ -5,6 +5,6 @@ first_party_detection = false
[tool.black] [tool.black]
line-length = 120 line-length = 120
target-version = ["py37"] target-version = ["py38"]
[tool.ufmt] [tool.ufmt]
...@@ -162,9 +162,9 @@ def _main(): ...@@ -162,9 +162,9 @@ def _main():
"Operating System :: Microsoft :: Windows", "Operating System :: Microsoft :: Windows",
"Operating System :: POSIX", "Operating System :: POSIX",
"Programming Language :: C++", "Programming Language :: C++",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: CPython",
"Topic :: Multimedia :: Sound/Audio", "Topic :: Multimedia :: Sound/Audio",
"Topic :: Scientific/Engineering :: Artificial Intelligence", "Topic :: Scientific/Engineering :: Artificial Intelligence",
......
import math
import torch import torch
import torchaudio.prototype.functional as F import torchaudio.prototype.functional as F
from parameterized import parameterized from parameterized import parameterized
...@@ -13,14 +15,7 @@ class AutogradTestImpl(TestBaseMixin): ...@@ -13,14 +15,7 @@ class AutogradTestImpl(TestBaseMixin):
] ]
) )
def test_oscillator_bank(self, sample_rate, shape): def test_oscillator_bank(self, sample_rate, shape):
# can be replaced with math.prod when we drop 3.7 support numel = math.prod(shape)
def prod(iterable):
ret = 1
for item in iterable:
ret *= item
return ret
numel = prod(shape)
# use 1.9 instead of 2 so as to include values above nyquist frequency # use 1.9 instead of 2 so as to include values above nyquist frequency
fmax = sample_rate / 1.9 fmax = sample_rate / 1.9
......
import math
import torch import torch
from parameterized import parameterized from parameterized import parameterized
from torchaudio.prototype.models import hifigan_vocoder, hifigan_vocoder_v1, hifigan_vocoder_v2, hifigan_vocoder_v3 from torchaudio.prototype.models import hifigan_vocoder, hifigan_vocoder_v1, hifigan_vocoder_v2, hifigan_vocoder_v3
...@@ -76,9 +78,7 @@ class HiFiGANTestImpl(TestBaseMixin): ...@@ -76,9 +78,7 @@ class HiFiGANTestImpl(TestBaseMixin):
inputs = self._get_inputs() inputs = self._get_inputs()
model = self._get_model() model = self._get_model()
total_upsample_rate = 1 # Use loop instead of math.prod for compatibility with Python 3.7 total_upsample_rate = math.prod(model_config["upsample_rates"])
for upsample_rate in model_config["upsample_rates"]:
total_upsample_rate *= upsample_rate
for _ in range(2): for _ in range(2):
out = model(inputs) out = model(inputs)
......
...@@ -3,7 +3,7 @@ from typing import List ...@@ -3,7 +3,7 @@ from typing import List
import torch import torch
import torchaudio.prototype.transforms as T import torchaudio.prototype.transforms as T
from torch.autograd import gradcheck, gradgradcheck from torch.autograd import gradcheck, gradgradcheck
from torchaudio_unittest.common_utils import get_spectrogram, get_whitenoise, nested_params, TestBaseMixin from torchaudio_unittest.common_utils import get_spectrogram, get_whitenoise, TestBaseMixin
class Autograd(TestBaseMixin): class Autograd(TestBaseMixin):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment