From 1be57bb8ec8beaa71641f347cc66621c84bfd52e Mon Sep 17 00:00:00 2001 From: Mikhail Ryzhov Date: Tue, 6 Feb 2024 13:54:27 +0100 Subject: [PATCH] tests reqs --- .github/workflows/linux.yml | 2 +- pyproject.toml | 12 +++++++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 92a245964..49ab2bc70 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -281,7 +281,7 @@ jobs: # Find and install wheel pushd ${INSTALL_DIR}/ov_tokenizers wheel_name=$(find . -name 'openvino_tokenizers*.whl') - python3 -m pip install $wheel_name[all] + python3 -m pip install $wheel_name[test] popd - name: Tokenizers Bandit tests diff --git a/pyproject.toml b/pyproject.toml index 9c2b412fd..f66d16618 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -28,11 +28,21 @@ transformers = [ ] dev = [ "ruff", + "bandit", "pytest", "pytest_harvest", - "bandit", "openvino_tokenizers[transformers]" ] +torch = [ + 'torch @ https://download.pytorch.org/whl/cpu-cxx11-abi/torch-2.0.1%2Bcpu.cxx11.abi-cp38-cp38-linux_x86_64.whl ; sys_platform=="linux" and python_version == "3.8"', + 'torch @ https://download.pytorch.org/whl/cpu-cxx11-abi/torch-2.0.1%2Bcpu.cxx11.abi-cp39-cp39-linux_x86_64.whl ; sys_platform=="linux" and python_version == "3.9"', + 'torch @ https://download.pytorch.org/whl/cpu-cxx11-abi/torch-2.0.1%2Bcpu.cxx11.abi-cp310-cp310-linux_x86_64.whl ; sys_platform=="linux" and python_version == "3.10"', + 'torch @ https://download.pytorch.org/whl/cpu-cxx11-abi/torch-2.0.1%2Bcpu.cxx11.abi-cp311-cp311-linux_x86_64.whl ; sys_platform=="linux" and python_version == "3.11"', + 'torch ; sys_platform != "linux"' +] +test = [ + "openvino_tokenizers[dev, torch]" +] fuzzing = [ "atheris", "openvino_tokenizers[transformers]"