Add emotion, event of SenseVoice. (#1257)
* Add emotion, event of SenseVoice. * Fix tokens size check and update java api. https://github.com/k2-fsa/sherpa-onnx/pull/1257
This commit is contained in:
@@ -32,6 +32,12 @@ static void PybindOfflineRecognitionResult(py::module *m) { // NOLINT
|
||||
return py::str(PyUnicode_DecodeUTF8(self.text.c_str(),
|
||||
self.text.size(), "ignore"));
|
||||
})
|
||||
.def_property_readonly("lang",
|
||||
[](const PyClass &self) { return self.lang; })
|
||||
.def_property_readonly("emotion",
|
||||
[](const PyClass &self) { return self.emotion; })
|
||||
.def_property_readonly("event",
|
||||
[](const PyClass &self) { return self.event; })
|
||||
.def_property_readonly("tokens",
|
||||
[](const PyClass &self) { return self.tokens; })
|
||||
.def_property_readonly("words",
|
||||
|
||||
Reference in New Issue
Block a user