Skip to content

Genie TTS bundled server fails to load converted ONNX model due to missing vits_fp32.bin #6

@Dmt3tianOVO

Description

@Dmt3tianOVO

Environment

  • Shinsekai version: 1.6.4-dev / bundled release package
  • OS: Windows
  • TTS backend: Genie TTS
  • Bundled package: data/tts_bundles/installed/genie_tts_server
  • genie-tts version: 2.0.2

Problem

After converting a GPT-SoVITS model with the bundled Genie TTS server, conversion succeeds, but loading the character fails.

The converted ONNX model directory contains:

  • t2s_encoder_fp32.bin
  • t2s_encoder_fp32.onnx
  • t2s_first_stage_decoder_fp32.onnx
  • t2s_shared_fp16.bin
  • t2s_stage_decoder_fp32.onnx
  • vits_fp16.bin
  • vits_fp32.onnx

But it does not contain:

  • vits_fp32.bin

However, vits_fp32.onnx references vits_fp32.bin as external data.

Error

When starting Genie TTS Server and loading the model, ONNXRuntime reports:

CopyLittleEndian source and destination buffer size mismatch

Full error:

Failed to load in-memory model vits_fp32.onnx:
[ONNXRuntimeError] : 6 : RUNTIME_EXCEPTION :
Exception during initialization:
endian_utils.cc:57
onnxruntime::utils::detail::CopyLittleEndian source and destination buffer size mismatch

Then TTS fails with:

Missing model or reference audio.

Root cause

The bundled genie-tts package is version 2.0.2.

Package metadata shows:

Project-URL: https://github.com/High-Logic/Genie

The converter generates vits_fp32.onnx, but only emits vits_fp16.bin.
Since the ONNX file references vits_fp32.bin, ONNXRuntime cannot load the model.

Additionally, after generating a matching vits_fp32.bin, 7 external_data.length fields in vits_fp32.onnx were still incorrect and had to be fixed.

Workaround verified

I generated vits_fp32.bin by expanding vits_fp16.bin from float16 to float32, then fixed external_data.length fields according to tensor dtype and shape.

After that, ONNXRuntime successfully loaded the model:

ORT load OK 3 1

Suggested fix

Please either:

  1. update the bundled Genie TTS server after upstream fixes it, or
  2. add a post-conversion repair step to the bundled converter:
  • generate vits_fp32.bin from vits_fp16.bin if missing
  • fix vits_fp32.onnx external_data.length fields

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions