From f9607ad89119ddac8765b548a89057ad6ce17cf3 Mon Sep 17 00:00:00 2001 From: tsukumi Date: Mon, 23 Sep 2024 11:10:41 +0900 Subject: [PATCH] Fix: Omitted consideration of macOS support --- pyproject.toml | 14 ++++++++++++-- requirements-infer.txt | 3 ++- requirements.txt | 3 ++- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index e1a771f..2d5ad38 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,11 @@ packages = ["style_bert_vits2"] # for PyTorch inference [tool.hatch.envs.test] -dependencies = ["coverage[toml]>=6.5", "pytest", "scipy"] +dependencies = [ + "coverage[toml]>=6.5", + "pytest", + "scipy", +] features = ["torch"] [tool.hatch.envs.test.scripts] # Usage: `hatch run test:test` @@ -91,7 +95,13 @@ python = ["3.9", "3.10", "3.11"] # for ONNX inference (without PyTorch dependency) [tool.hatch.envs.test-onnx] -dependencies = ["coverage[toml]>=6.5", "pytest", "scipy", "onnxruntime-gpu", "onnxruntime-directml; sys_platform == 'win32'"] +dependencies = [ + "coverage[toml]>=6.5", + "pytest", + "scipy", + "onnxruntime-directml; sys_platform == 'win32'", + "onnxruntime-gpu; sys_platform != 'darwin'", +] [tool.hatch.envs.test-onnx.scripts] # Usage: `hatch run test-onnx:test` test = "pytest tests/test_main.py::test_synthesize_onnx_cpu" diff --git a/requirements-infer.txt b/requirements-infer.txt index 0fd1a63..c198986 100644 --- a/requirements-infer.txt +++ b/requirements-infer.txt @@ -12,7 +12,8 @@ nltk<=3.8.1 num2words numpy<2 onnxruntime -onnxruntime-gpu +onnxruntime-directml; sys_platform == 'win32' +onnxruntime-gpu; sys_platform != 'darwin' # onnxsim # protobuf==4.25 psutil diff --git a/requirements.txt b/requirements.txt index 475ca5c..dd2d327 100644 --- a/requirements.txt +++ b/requirements.txt @@ -12,7 +12,8 @@ nltk<=3.8.1 num2words numpy<2 onnxruntime -onnxruntime-gpu +onnxruntime-directml; sys_platform == 'win32' +onnxruntime-gpu; sys_platform != 'darwin' onnxsim protobuf==4.25 psutil