Skip to content
Discussion options

You must be logged in to vote

Emotion2Vec ONNX export is available now. Support was added in #2359. I re-tested the current main (1d8080af) with the public iic/emotion2vec_plus_large checkpoint and ONNX Runtime CPU.

One current filename issue is easy to miss: the exporter writes a valid graph named emotion2vec without the .onnx suffix. Rename that file after export; no conversion is needed.

from pathlib import Path

import numpy as np
import onnx
import onnxruntime as ort
from funasr import AutoModel

output_dir = Path("./emotion2vec_onnx")
model = AutoModel(
    model="iic/emotion2vec_plus_large",
    hub="ms",
    device="cpu",
    disable_update=True,
)

export_dir = Path(
    model.export(
        type="onnx",
  …

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by LauraGPT
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants