Allows one to cast an operation to a different shape with the same volume.
The operation to be reshaped.
The new shape.
The new Operation.
import dopt.core : evaluate; auto r1 = float32([2, 2], [1.0f, 2.0f, 3.0f, 4.0f]).reshape([1, 4]); assert(r1.shape == [1, 4]); assert(r1.evaluate().get!float == [1.0f, 2.0f, 3.0f, 4.0f]);
See Implementation
Allows one to cast an operation to a different shape with the same volume.