Skip to main content
Associate
September 7, 2024
Solved

A problem during optimization:Unsupported layer types: ScatterND

  • September 7, 2024
  • 1 reply
  • 1388 views

We reported the following error during the "optimize" step of generating an ONNX model: (ST Edge AI Core v1.0.0-19894  NOT IMPLEMENTED: Unsupported layer types: ScatterND).

How to solve this issue? Is there any function or tool that can replace ScatterND?

 

Best answer by

The error you're encountering during the optimization step of generating an ONNX model suggests that the ScatterND layer is not supported in the version of ST Edge AI Core you're using. To address this issue, you can consider the following strategies:

1. Replace ScatterND with Supported Operations
One way to handle this issue is by rewriting the logic that uses ScatterNd with other ONNX operations that are supported by the target environment. This would involve manual refactoring of your model to eliminate ScatterND operations. Some potential alternatives include:

GatherND: If you are only selecting certain indices rather than scattering values, GatherND could replace ScatterND depending on your use case.
Slice and Concat: You can mimic the scattering behavior using combinations of Slice, Concat, and other tensor manipulation functions to implement the functionality of ScatterND.

1 reply

Best answer
September 19, 2024

The error you're encountering during the optimization step of generating an ONNX model suggests that the ScatterND layer is not supported in the version of ST Edge AI Core you're using. To address this issue, you can consider the following strategies:

1. Replace ScatterND with Supported Operations
One way to handle this issue is by rewriting the logic that uses ScatterNd with other ONNX operations that are supported by the target environment. This would involve manual refactoring of your model to eliminate ScatterND operations. Some potential alternatives include:

GatherND: If you are only selecting certain indices rather than scattering values, GatherND could replace ScatterND depending on your use case.
Slice and Concat: You can mimic the scattering behavior using combinations of Slice, Concat, and other tensor manipulation functions to implement the functionality of ScatterND.

KaifAuthor
Associate
September 19, 2024

Thanks for your reply, we will try your solution.