From c5cd41c8384ea0b81116a88ea4c817bc1a22984e Mon Sep 17 00:00:00 2001 From: danemadsen Date: Tue, 30 Jul 2024 16:43:50 +1000 Subject: [PATCH] add casts --- CMakeLists.txt | 12 +----------- src/phonemizer.cpp | 2 +- src/voice.cpp | 2 +- 3 files changed, 3 insertions(+), 13 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 51fafde..dabceea 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -150,17 +150,7 @@ else() ) endif() -target_link_directories( - babylon PUBLIC - ${BABYLON_LIB_INSTALL_DIR} -) - -if(WIN32) - target_link_libraries( - babylon - onnxruntime - ) -elseif(APPLE) +if(APPLE) target_link_libraries( babylon onnxruntime diff --git a/src/phonemizer.cpp b/src/phonemizer.cpp index ac7587b..24fadc7 100644 --- a/src/phonemizer.cpp +++ b/src/phonemizer.cpp @@ -133,7 +133,7 @@ namespace DeepPhonemizer { session_options.SetIntraOpNumThreads(1); session_options.SetGraphOptimizationLevel(GraphOptimizationLevel::ORT_ENABLE_ALL); - session = new Ort::Session(env, model_path.c_str(), session_options); + session = new Ort::Session(env, (const ORTCHAR_T *) model_path.c_str(), session_options); // Load metadata from the model Ort::ModelMetadata model_metadata = session->GetModelMetadata(); diff --git a/src/voice.cpp b/src/voice.cpp index a29d354..19a343d 100644 --- a/src/voice.cpp +++ b/src/voice.cpp @@ -77,7 +77,7 @@ namespace Vits { session_options.DisableMemPattern(); session_options.DisableProfiling(); - session = new Ort::Session(env, model_path.c_str(), session_options); + session = new Ort::Session(env, (const ORTCHAR_T *) model_path.c_str(), session_options); // Load metadata from the model Ort::ModelMetadata model_metadata = session->GetModelMetadata();