Closed hhxdestiny closed 2 weeks ago
请教一个奇葩的问题,我写了一个ort推理paraformer的过程(根据自己的需求简化了一下funasr/runtime/onnxruntime,但是forword这里几乎是一致的),然后从Ort::Session::Run的output Tensor中获取logits时(output[0].GetTensorMutableData())是正常的,但是获取token_num时(output[1].GetTensorMutableData()),有时候正常,有时候会是一个非常大的不固定的数据(比如7306086966494233117),这个过程在同一个音频文件上也不一定必现,在token_num不正常时output[0].GetTensorTypeAndShapeInfo().GetShape()[1]是正常的,我使用output[0].GetTensorTypeAndShapeInfo().GetShape()[1]作为输出的长度也是能够工作的,但是不明白output[1].GetTensorMutableData()和output[0].GetTensorTypeAndShapeInfo().GetShape()[1]不一致的缘由。。。
Let's close this issue for now. If needed, reopen it.
请教一个奇葩的问题,我写了一个ort推理paraformer的过程(根据自己的需求简化了一下funasr/runtime/onnxruntime,但是forword这里几乎是一致的),然后从Ort::Session::Run的output Tensor中获取logits时(output[0].GetTensorMutableData())是正常的,但是获取token_num时(output[1].GetTensorMutableData()),有时候正常,有时候会是一个非常大的不固定的数据(比如7306086966494233117),这个过程在同一个音频文件上也不一定必现,在token_num不正常时output[0].GetTensorTypeAndShapeInfo().GetShape()[1]是正常的,我使用output[0].GetTensorTypeAndShapeInfo().GetShape()[1]作为输出的长度也是能够工作的,但是不明白output[1].GetTensorMutableData()和output[0].GetTensorTypeAndShapeInfo().GetShape()[1]不一致的缘由。。。