MCPcopy Create free account
hub / github.com/WasmEdge/WasmEdge / updatePiperOptions

Function updatePiperOptions

plugins/wasi_nn/wasinn_piper.cpp:220–234  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

218}
219
220void updatePiperOptions(const SynthesisConfig &SynthesisConfig,
221 piper_synthesize_options &Options) {
222 if (SynthesisConfig.SpeakerId) {
223 Options.speaker_id = SynthesisConfig.SpeakerId.value();
224 }
225 if (SynthesisConfig.NoiseScale) {
226 Options.noise_scale = SynthesisConfig.NoiseScale.value();
227 }
228 if (SynthesisConfig.LengthScale) {
229 Options.length_scale = SynthesisConfig.LengthScale.value();
230 }
231 if (SynthesisConfig.NoiseW) {
232 Options.noise_w_scale = SynthesisConfig.NoiseW.value();
233 }
234}
235
236Expect<WASINN::ErrNo> load(WASINN::WasiNNEnvironment &Env,
237 Span<const Span<uint8_t>> Builders, WASINN::Device,

Callers 1

computeFunction · 0.85

Calls 1

valueMethod · 0.45

Tested by

no test coverage detected