latest (dev)
Copy
Latest development documentation · Updated 2026-10-15
tensorplay.functional.ravel
- tensorplay.functional.ravel(input) Tensor[source]
Return a contiguous flattened tensor. A copy is made only if needed.
- Parameters:
input (Tensor) – the input tensor.
Example:
>>> t = tensorplay.tensor([[[1, 2], ... [3, 4]], ... [[5, 6], ... [7, 8]]]) >>> tensorplay.ravel(t) tensor([1, 2, 3, 4, 5, 6, 7, 8])
Help improve this page
Found an error, an unclear step, or a missing example?
Was this page helpful?

