Skip to content

Commit

Permalink
修正: 対応デバイスモックの属性不足を修正 (#1224)
Browse files Browse the repository at this point in the history
fix: コアバージョンモックの属性不足を修正
  • Loading branch information
tarepan authored May 14, 2024
1 parent 67dbf5f commit 418a9d3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion test/tts_pipeline/test_tts_engine.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import json
from test.utility import pydantic_to_native_type, round_floats
from unittest import TestCase
from unittest.mock import Mock
Expand Down Expand Up @@ -97,7 +98,7 @@ def metas(self) -> str:
return ""

def supported_devices(self) -> str:
return ""
return json.dumps({"cpu": True, "cuda": False, "dml": False})

def is_model_loaded(self, style_id: str) -> bool:
return True
Expand Down
7 changes: 1 addition & 6 deletions voicevox_engine/dev/core/mock.py
Original file line number Diff line number Diff line change
Expand Up @@ -229,12 +229,7 @@ def sf_decode_forward(
return np.array(result, dtype=np.float32)

def supported_devices(self) -> str:
return json.dumps(
{
"cpu": True,
"cuda": False,
}
)
return json.dumps({"cpu": True, "cuda": False, "dml": False})

def finalize(self) -> None:
pass
Expand Down

0 comments on commit 418a9d3

Please sign in to comment.