From 96b6c13ebe0ccf60cfd4b39bad89150704a12437 Mon Sep 17 00:00:00 2001 From: Daniel Tang Date: Thu, 14 Aug 2025 06:18:59 -0400 Subject: [PATCH 1/3] fix(orpheus): Windows constexpr compile error --- src/orpheus_model.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/orpheus_model.cpp b/src/orpheus_model.cpp index 8e2bb5f..4866af2 100644 --- a/src/orpheus_model.cpp +++ b/src/orpheus_model.cpp @@ -1,8 +1,10 @@ #include "orpheus_model.h" +#include + // These tokens and variables aren't defined in the Orpheus' model configuration but instead are defined inline in various python functions. // As such, they are not discoverable so defining them as unconfigurable constants should be fine. -static constexpr std::array orpheus_voices = {"zoe", "zac","jess", "leo", "mia", "julia", "leah"}; +static constexpr std::array orpheus_voices{"zoe", "zac","jess", "leo", "mia", "julia", "leah"}; static constexpr std::array orpheus_prepended_tokens = { 128259, 128000 }; static constexpr std::array orpheus_appended_tokens = { 128009, 128260, 128261, 128257 }; From 578c414ecbffba241fc89f348aae1d59fb287f09 Mon Sep 17 00:00:00 2001 From: Daniel Tang Date: Thu, 14 Aug 2025 06:24:02 -0400 Subject: [PATCH 2/3] fix(kokoro): Iterator debug assertion on Windows Fixes: #109 --- src/phonemizer.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/phonemizer.cpp b/src/phonemizer.cpp index a9ef2fb..16271b8 100644 --- a/src/phonemizer.cpp +++ b/src/phonemizer.cpp @@ -409,7 +409,7 @@ void word_phonemizer::add_rule(std::vector keys, std::string phonem phonemizer_rule * current_rule = nullptr; for (int i = 0; i < keys.size(); i++) { if (current_rule) { - if (current_rule->rules.find(keys[i]) == rules.end()) { + if (!current_rule->rules.contains(keys[i])) { phonemizer_rule * nrule = new phonemizer_rule; current_rule->rules[keys[i]] = nrule; current_rule = nrule; @@ -1178,4 +1178,3 @@ struct phonemizer * phonemizer_from_file(const std::string fname, const std::str } return phonemizer_from_gguf(meta_ctx, espeak_voice_code); } - From 581c8df56d223b1acb15162d3c0b7b728e59e1a1 Mon Sep 17 00:00:00 2001 From: Daniel Tang Date: Thu, 14 Aug 2025 06:28:48 -0400 Subject: [PATCH 3/3] fix(util): Ensure M_PI is imported on Windows Co-authored-by: Concedo <39025047+LostRuins@users.noreply.github.com> --- src/util.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/util.h b/src/util.h index 681111e..42b2164 100644 --- a/src/util.h +++ b/src/util.h @@ -1,8 +1,9 @@ #ifndef util_h #define util_h +#define _USE_MATH_DEFINES +#include #include -#include #include #include #include