From 716bf1f77b886608d5ec2c3ab570a154122d6052 Mon Sep 17 00:00:00 2001 From: ydshieh Date: Tue, 6 Feb 2024 11:53:02 +0100 Subject: [PATCH 1/4] unpin torch --- setup.py | 6 +++--- src/transformers/dependency_versions_table.py | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/setup.py b/setup.py index c4a38eccea2f3c..224f36c4a98f00 100644 --- a/setup.py +++ b/setup.py @@ -175,9 +175,9 @@ "timeout-decorator", "timm", "tokenizers>=0.14,<0.19", - "torch<2.2.0", - "torchaudio<2.2.0", - "torchvision<0.17.0", + "torch", + "torchaudio", + "torchvision", "pyctcdecode>=0.4.0", "tqdm>=4.27", "unidic>=1.0.2", diff --git a/src/transformers/dependency_versions_table.py b/src/transformers/dependency_versions_table.py index 4df2ff8c72957b..d70b717f0d6946 100644 --- a/src/transformers/dependency_versions_table.py +++ b/src/transformers/dependency_versions_table.py @@ -80,9 +80,9 @@ "timeout-decorator": "timeout-decorator", "timm": "timm", "tokenizers": "tokenizers>=0.14,<0.19", - "torch": "torch<2.2.0", - "torchaudio": "torchaudio<2.2.0", - "torchvision": "torchvision<0.17.0", + "torch": "torch", + "torchaudio": "torchaudio", + "torchvision": "torchvision", "pyctcdecode": "pyctcdecode>=0.4.0", "tqdm": "tqdm>=4.27", "unidic": "unidic>=1.0.2", From ffe3a1581a8b9664571c5effe2a6ee7e3ca68ffe Mon Sep 17 00:00:00 2001 From: ydshieh Date: Tue, 6 Feb 2024 15:15:03 +0100 Subject: [PATCH 2/4] check --- .circleci/create_circleci_config.py | 42 ++++++++++++++--------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/.circleci/create_circleci_config.py b/.circleci/create_circleci_config.py index b44a5fde153b12..0f39126e93a308 100644 --- a/.circleci/create_circleci_config.py +++ b/.circleci/create_circleci_config.py @@ -103,27 +103,27 @@ def to_dict(self): steps = [ "checkout", {"attach_workspace": {"at": "~/transformers/test_preparation"}}, - { - "restore_cache": { - "keys": [ - # check the fully-matched cache first - f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-pip-" + '{{ checksum "setup.py" }}', - # try the partially-matched cache from `main` - f"v{self.cache_version}-{self.cache_name}-main-pip-", - # try the general partially-matched cache - f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-pip-", - ] - } - }, - { - "restore_cache": { - "keys": [ - f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-site-packages-" + '{{ checksum "setup.py" }}', - f"v{self.cache_version}-{self.cache_name}-main-site-packages-", - f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-site-packages-", - ] - } - }, + # { + # "restore_cache": { + # "keys": [ + # # check the fully-matched cache first + # f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-pip-" + '{{ checksum "setup.py" }}', + # # try the partially-matched cache from `main` + # f"v{self.cache_version}-{self.cache_name}-main-pip-", + # # try the general partially-matched cache + # f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-pip-", + # ] + # } + # }, + # { + # "restore_cache": { + # "keys": [ + # f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-site-packages-" + '{{ checksum "setup.py" }}', + # f"v{self.cache_version}-{self.cache_name}-main-site-packages-", + # f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-site-packages-", + # ] + # } + # }, ] steps.extend([{"run": l} for l in self.install_steps]) steps.extend([{"run": 'pip install "fsspec>=2023.5.0,<2023.10.0"'}]) From 603b36c9c5d96bd38f444edbe1bb87e12c774304 Mon Sep 17 00:00:00 2001 From: ydshieh Date: Tue, 6 Feb 2024 15:43:04 +0100 Subject: [PATCH 3/4] check --- .circleci/create_circleci_config.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.circleci/create_circleci_config.py b/.circleci/create_circleci_config.py index 0f39126e93a308..165ec7c6bab793 100644 --- a/.circleci/create_circleci_config.py +++ b/.circleci/create_circleci_config.py @@ -283,6 +283,8 @@ def job_name(self): "pip install -U --upgrade-strategy eager .[sklearn,tf-cpu,torch,testing,sentencepiece,torch-speech,vision]", "pip install -U --upgrade-strategy eager tensorflow_probability", "pip install -U --upgrade-strategy eager -e git+https://github.com/huggingface/accelerate@main#egg=accelerate", + # TODO: remove this one after fixing the dependency issue(s) above + "pip install -U --upgrade-strategy eager torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu" ], marker="is_pt_tf_cross_test", pytest_options={"rA": None, "durations": 0}, From 76b1381817828f0fa3626b34c21bf4b3966988e0 Mon Sep 17 00:00:00 2001 From: ydshieh Date: Tue, 6 Feb 2024 16:14:31 +0100 Subject: [PATCH 4/4] check --- .circleci/create_circleci_config.py | 42 ++++++++++++++--------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/.circleci/create_circleci_config.py b/.circleci/create_circleci_config.py index 165ec7c6bab793..0107d95ebad99e 100644 --- a/.circleci/create_circleci_config.py +++ b/.circleci/create_circleci_config.py @@ -103,27 +103,27 @@ def to_dict(self): steps = [ "checkout", {"attach_workspace": {"at": "~/transformers/test_preparation"}}, - # { - # "restore_cache": { - # "keys": [ - # # check the fully-matched cache first - # f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-pip-" + '{{ checksum "setup.py" }}', - # # try the partially-matched cache from `main` - # f"v{self.cache_version}-{self.cache_name}-main-pip-", - # # try the general partially-matched cache - # f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-pip-", - # ] - # } - # }, - # { - # "restore_cache": { - # "keys": [ - # f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-site-packages-" + '{{ checksum "setup.py" }}', - # f"v{self.cache_version}-{self.cache_name}-main-site-packages-", - # f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-site-packages-", - # ] - # } - # }, + { + "restore_cache": { + "keys": [ + # check the fully-matched cache first + f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-pip-" + '{{ checksum "setup.py" }}', + # try the partially-matched cache from `main` + f"v{self.cache_version}-{self.cache_name}-main-pip-", + # try the general partially-matched cache + f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-pip-", + ] + } + }, + { + "restore_cache": { + "keys": [ + f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-site-packages-" + '{{ checksum "setup.py" }}', + f"v{self.cache_version}-{self.cache_name}-main-site-packages-", + f"v{self.cache_version}-{self.cache_name}-{cache_branch_prefix}-site-packages-", + ] + } + }, ] steps.extend([{"run": l} for l in self.install_steps]) steps.extend([{"run": 'pip install "fsspec>=2023.5.0,<2023.10.0"'}])