From ad8a4cb468b418c82d4b34dfce6ba6f1de323b18 Mon Sep 17 00:00:00 2001 From: Ilyas Moutawwakil <57442720+IlyasMoutawwakil@users.noreply.github.com> Date: Fri, 29 Nov 2024 14:05:31 +0100 Subject: [PATCH] Pin ipex for release (#1041) * pin ipex for release * fix --- .github/workflows/test_inc.yml | 2 +- .github/workflows/test_ipex.yml | 4 ++-- optimum/intel/neural_compressor/utils.py | 3 +-- setup.py | 2 +- 4 files changed, 5 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test_inc.yml b/.github/workflows/test_inc.yml index b31f2055f3..2e51cdfbb3 100644 --- a/.github/workflows/test_inc.yml +++ b/.github/workflows/test_inc.yml @@ -35,7 +35,7 @@ jobs: run: | pip install --upgrade pip pip install torch==${{ matrix.torch-version }} torchaudio torchvision --index-url https://download.pytorch.org/whl/cpu - pip install .[neural-compressor,ipex,diffusers,peft,tests] transformers[testing] intel-extension-for-pytorch==${{ matrix.torch-version }} + pip install .[neural-compressor,diffusers,peft,tests] transformers[testing] intel-extension-for-pytorch==${{ matrix.torch-version }} - name: Assert versions run: | diff --git a/.github/workflows/test_ipex.yml b/.github/workflows/test_ipex.yml index 59a3161528..41330ed42b 100644 --- a/.github/workflows/test_ipex.yml +++ b/.github/workflows/test_ipex.yml @@ -18,7 +18,7 @@ jobs: strategy: fail-fast: false matrix: - torch-version: ["2.2.0", "2.3.*", "2.4.*"] + torch-version: ["2.2.0", "2.3.*"] transformers-version: ["4.39.0", "4.44.*"] runs-on: ubuntu-22.04 @@ -50,4 +50,4 @@ jobs: - name: Test with Pytest run: | - pytest tests/ipex \ No newline at end of file + pytest tests/ipex diff --git a/optimum/intel/neural_compressor/utils.py b/optimum/intel/neural_compressor/utils.py index c7a7ceda72..80c5f78528 100644 --- a/optimum/intel/neural_compressor/utils.py +++ b/optimum/intel/neural_compressor/utils.py @@ -30,10 +30,9 @@ CONFIG_NAME = "best_configure.yaml" QUANTIZATION_CONFIG_NAME = "quantize_config.json" +IPEX_MINIMUM_VERSION = "2.4.0" NEURAL_COMPRESSOR_MINIMUM_VERSION = "2.1.0" NEURAL_COMPRESSOR_WEIGHT_ONLY_MINIMUM_VERSION = "2.3.0" -IPEX_MINIMUM_VERSION = "2.3.1" - _HEAD_TO_AUTOMODELS = { "fill-mask": "INCModelForMaskedLM", diff --git a/setup.py b/setup.py index fde9150143..cd49ea041a 100644 --- a/setup.py +++ b/setup.py @@ -64,7 +64,7 @@ "nncf": ["nncf>=2.14.0"], "openvino": ["nncf>=2.14.0", "openvino>=2024.5.0", "openvino-tokenizers>=2024.5.0"], "neural-compressor": ["neural-compressor[pt]>3.0", "accelerate", "transformers<4.46"], - "ipex": ["intel-extension-for-pytorch", "transformers>=4.39,<4.45"], + "ipex": ["intel-extension-for-pytorch>=2.2,<2.4", "transformers>=4.39,<4.45"], "diffusers": ["diffusers"], "quality": QUALITY_REQUIRE, "tests": TESTS_REQUIRE,