Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade the required python version to python>=3.11 #337

Merged
merged 10 commits into from
Sep 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/docs-latest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Set up Python and uv
uses: drivendataorg/setup-python-uv-action@v1
with:
python-version: 3.8
python-version: 3.11

- name: Install dependencies
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/docs-preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- name: Set up Python and uv
uses: drivendataorg/setup-python-uv-action@v1
with:
python-version: 3.8
python-version: 3.11

- name: Install dependencies
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
- name: Set up Python and uv
uses: drivendataorg/setup-python-uv-action@v1
with:
python-version: 3.8
python-version: 3.11

- name: Install dependencies
run: |
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
- name: Set up Python and uv
uses: drivendataorg/setup-python-uv-action@v1
with:
python-version: 3.8
python-version: 3.11

- name: Install dependencies
run: |
Expand All @@ -41,7 +41,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
python-version: [3.8, 3.9]
python-version: [3.11, 3.12]

steps:
- if: matrix.os == 'ubuntu-latest'
Expand Down Expand Up @@ -101,12 +101,12 @@ jobs:
ZAMBA_RUN_DENSEPOSE_TESTS: 1
run: |
uv pip install flit-core
# torch is alread installed, so just add the densepose extra
# torch is already installed, so just add the densepose extra
uv pip install -e .[densepose] --no-build-isolation
make densepose-tests

- name: Upload coverage to codecov
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml
Expand All @@ -119,7 +119,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
python-version: [3.8]
python-version: [3.11, 3.12]

steps:
- name: Remove unused software
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

PROJECT_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
PROJECT_NAME = zamba
PYTHON_VERSION = 3.8
PYTHON_VERSION = 3.11
PYTHON_INTERPRETER = python

ifeq (, $(shell which nvidia-smi))
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Visit https://zamba.drivendata.org/docs/ for full documentation and tutorials.

First, make sure you have the prerequisites installed:

* Python 3.8 or 3.9
* Python 3.11 or 3.12
* FFmpeg > 4.3

Then run:
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ We encourage people to share their custom models trained with Zamba. If you trai

First, make sure you have the prerequisites installed:

* Python 3.8 or 3.9
* Python 3.11 or 3.12
* FFmpeg > 4.3

Then run:
Expand Down
4 changes: 2 additions & 2 deletions docs/docs/install.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ GPU configurations.

Prerequisites:

- Python 3.8 or 3.9
- Python 3.11 or 3.12
- FFmpeg

#### [Python](https://www.python.org/) 3.8 or 3.9
#### [Python](https://www.python.org/) 3.11 or 3.12

We recommend [Python installation using Anaconda](https://www.anaconda.com/download/) for all platforms. For more information about how to install Anaconda, here are some useful YouTube videos of installation:

Expand Down
6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ classifiers = [
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
]
requires-python = ">=3.8"
requires-python = ">=3.11"
dependencies = [
"appdirs",
"av",
Expand All @@ -38,7 +38,7 @@ dependencies = [
"pytorchvideo",
"scikit-learn",
"tensorboard",
"thop==0.0.31.post2005241907",
"thop",
"timm",
"torch",
"torchinfo",
Expand All @@ -61,7 +61,7 @@ tests = [
"wheel",
]
densepose = [
"torch<2.1.0", # densepose broken after 2.1.0; https://github.com/facebookresearch/detectron2/issues/5110
"torch",
"detectron2 @ git+https://github.com/facebookresearch/detectron2.git",
"detectron2-densepose @ git+https://github.com/facebookresearch/detectron2@main#subdirectory=projects/DensePose"
]
Expand Down
4 changes: 2 additions & 2 deletions zamba/models/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -428,7 +428,7 @@ class TrainConfig(ZambaBaseModel):
data_dir: DirectoryPath = ""
checkpoint: Optional[FilePath] = None
scheduler_config: Optional[Union[str, SchedulerConfig]] = "default"
model_name: Optional[ModelEnum] = ModelEnum.time_distributed
model_name: Optional[ModelEnum] = ModelEnum.time_distributed.value
dry_run: Union[bool, int] = False
batch_size: int = 2
auto_lr_find: bool = False
Expand Down Expand Up @@ -749,7 +749,7 @@ class PredictConfig(ZambaBaseModel):
data_dir: DirectoryPath = ""
filepaths: Optional[FilePath] = None
checkpoint: Optional[FilePath] = None
model_name: Optional[ModelEnum] = ModelEnum.time_distributed
model_name: Optional[ModelEnum] = ModelEnum.time_distributed.value
gpus: int = GPUS_AVAILABLE
num_workers: int = 3
batch_size: int = 2
Expand Down
Loading