wildedge-python
wildedge-python copied to clipboard
ONNX extractor: Piper TTS models report name "main_graph" and version 9223372036854775807
What happens
Loading a Piper TTS voice (onnxruntime.InferenceSession on e.g. pl_PL-*.onnx) with the onnx integration registers:
model_name = "main_graph"model_version = "9223372036854775807"
In OnnxExtractor.extract_info (wildedge/integrations/onnx.py:144):
main_graph(the default name fromtorch.onnx.exportin newer PyTorch) isn't in_GENERIC_GRAPH_NAMES, so it's used as the model name.meta.versionisINT64_MAX, an "unset" sentinel, and only"0"is treated as missing.
Every Piper voice therefore shows up as the same model, with a nonsense version.
Expected
- Add
main_graphto_GENERIC_GRAPH_NAMES. - Treat
INT64_MAX(and probably any negative value) as no version. - When the graph name is generic, fall back to the model file name stem (
session._model_pathwhen available, or the path passed toInferenceSession) before"onnx-model".
SDK 0.2.2, onnxruntime on macOS.
🤖 Generated with Claude Code