OpenUtau icon indicating copy to clipboard operation
OpenUtau copied to clipboard

Diffsinger Onnx Error

Open usasho opened this issue 1 year ago • 1 comments

Acknowledgement

  • [X] I have read Getting-Started and FAQ

🐛 Describe the bug

An error occurred when using Diffsinger's ONNX Variance function No error occurred when converting Torch version 1.13 to Onnx. This time I used Torch 2.2 and got an Onnx error. Have the model parameters themselves changed?

The version of Torch currently used for both SOME and SOFA is 2.2. Thank you for your improvement.

Explains how to reproduce the bug

Errors Onnx Pitch、Duration、linguistic  Variance

OS & Version

Windows10-11

Logs

Failed to run editing macro [ErrorCode:RuntimeException] Non-zero status code returned while running Reshape node. Name:'/encoder/layers.0/op/self_attn/Reshape_4' Status Message:

Microsoft.ML.OnnxRuntime.OnnxRuntimeException: [ErrorCode:RuntimeException] Non-zero status code returned while running Reshape node. Name:'/encoder/layers.0/op/self_attn/Reshape_4' Status Message: at Microsoft.ML.OnnxRuntime.NativeApiStatus.VerifySuccess(IntPtr nativeStatus) at Microsoft.ML.OnnxRuntime.InferenceSession.RunImpl(RunOptions options, IntPtr[] inputNames, IntPtr[] inputValues, IntPtr[] outputNames, DisposableList1 cleanupList) at Microsoft.ML.OnnxRuntime.InferenceSession.Run(IReadOnlyCollection1 inputs, IReadOnlyCollection1 outputNames, RunOptions options) at Microsoft.ML.OnnxRuntime.InferenceSession.Run(IReadOnlyCollection1 inputs, IReadOnlyCollection1 outputNames) at Microsoft.ML.OnnxRuntime.InferenceSession.Run(IReadOnlyCollection1 inputs) at OpenUtau.Core.DiffSinger.DsPitch.Process(RenderPhrase phrase) in C:\projects\openutau\OpenUtau.Core\DiffSinger\DiffSingerPitch.cs:line 126 at OpenUtau.Core.DiffSinger.DiffSingerRenderer.LoadRenderedPitch(RenderPhrase phrase) in C:\projects\openutau\OpenUtau.Core\DiffSinger\DiffSingerRenderer.cs:line 304 at OpenUtau.Core.Editing.LoadRenderedPitch.Run(UProject project, UVoicePart part, List`1 selectedNotes, DocManager docManager) in C:\projects\openutau\OpenUtau.Core\Editing\NoteBatchEdits.cs:line 464 at OpenUtau.App.ViewModels.PianoRollViewModel.<.ctor>b__94_10(BatchEdit edit) in C:\projects\openutau\OpenUtau\ViewModels\PianoRollViewModel.cs:line 167

usasho avatar Feb 07 '24 17:02 usasho

CPU Ver

Failed to run editing macro [ErrorCode:RuntimeException] Non-zero status code returned while running Reshape node. Name:'/encoder/layers.0/op/self_attn/Reshape_4' Status Message: D:\a_work\1\s\onnxruntime\core\providers\cpu\tensor\reshape_helper.h:41 onnxruntime::ReshapeHelper::ReshapeHelper gsl::narrow_cast<int64_t>(input_shape.Size()) == size was false. The input tensor cannot be reshaped to the requested shape. Input shape:{3,1,128}, requested shape:{5,2,64}

Microsoft.ML.OnnxRuntime.OnnxRuntimeException: [ErrorCode:RuntimeException] Non-zero status code returned while running Reshape node. Name:'/encoder/layers.0/op/self_attn/Reshape_4' Status Message: D:\a_work\1\s\onnxruntime\core\providers\cpu\tensor\reshape_helper.h:41 onnxruntime::ReshapeHelper::ReshapeHelper gsl::narrow_cast<int64_t>(input_shape.Size()) == size was false. The input tensor cannot be reshaped to the requested shape. Input shape:{3,1,128}, requested shape:{5,2,64}

at Microsoft.ML.OnnxRuntime.NativeApiStatus.VerifySuccess(IntPtr nativeStatus) at Microsoft.ML.OnnxRuntime.InferenceSession.RunImpl(RunOptions options, IntPtr[] inputNames, IntPtr[] inputValues, IntPtr[] outputNames, DisposableList1 cleanupList) at Microsoft.ML.OnnxRuntime.InferenceSession.Run(IReadOnlyCollection1 inputs, IReadOnlyCollection1 outputNames, RunOptions options) at Microsoft.ML.OnnxRuntime.InferenceSession.Run(IReadOnlyCollection1 inputs, IReadOnlyCollection1 outputNames) at Microsoft.ML.OnnxRuntime.InferenceSession.Run(IReadOnlyCollection1 inputs) at OpenUtau.Core.DiffSinger.DsPitch.Process(RenderPhrase phrase) in C:\projects\openutau\OpenUtau.Core\DiffSinger\DiffSingerPitch.cs:line 126 at OpenUtau.Core.DiffSinger.DiffSingerRenderer.LoadRenderedPitch(RenderPhrase phrase) in C:\projects\openutau\OpenUtau.Core\DiffSinger\DiffSingerRenderer.cs:line 304 at OpenUtau.Core.Editing.LoadRenderedPitch.Run(UProject project, UVoicePart part, List`1 selectedNotes, DocManager docManager) in C:\projects\openutau\OpenUtau.Core\Editing\NoteBatchEdits.cs:line 464 at OpenUtau.App.ViewModels.PianoRollViewModel.<.ctor>b__94_10(BatchEdit edit) in C:\projects\openutau\OpenUtau\ViewModels\PianoRollViewModel.cs:line 167

0.1.384.0

usasho avatar Feb 07 '24 17:02 usasho

This issue is stale because it has been open for 60 days with no activity. It will be closed if no further activity occurs. Thank you.

github-actions[bot] avatar Apr 08 '24 02:04 github-actions[bot]