You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there any guidelines to follow for handling the dynamic shape (e.g. reshaping a dynamic tensor)?
In addition to using the shapeOp + sliceOp, is there any other way to get a specific dim size?
Is there a good way to construct 1-D tensor for the ShuffleLayer's dynamic shape input? Currently, I'm using shapeOp + sliceOp + concatOp to construct 1D tensor for mixing dynamic batch with static dims, but it's quite complicated. It would be great if there is an easier way to construct 1D tensor, and a direct way get the size of a particular dim from a tensor.
The text was updated successfully, but these errors were encountered:
You should be able to do dynamic reshaping by manipulating the tensor.shape as though it were a list.
For example, you can flatten a tensor by taking the product of its shape:
Dynamic shapes are really only relevant in compiled mode since eager mode always uses dynamic shapes.
You can compile the above function for a range of input shapes and it should still work as expected:
Is there any guidelines to follow for handling the dynamic shape (e.g. reshaping a dynamic tensor)?
In addition to using the shapeOp + sliceOp, is there any other way to get a specific dim size?
Is there a good way to construct 1-D tensor for the ShuffleLayer's dynamic shape input? Currently, I'm using shapeOp + sliceOp + concatOp to construct 1D tensor for mixing dynamic batch with static dims, but it's quite complicated. It would be great if there is an easier way to construct 1D tensor, and a direct way get the size of a particular dim from a tensor.
The text was updated successfully, but these errors were encountered: