mirror of
https://github.com/tinygrad/tinygrad.git
synced 2026-04-29 03:00:14 -04:00
docs: update wording for unflatten (#4974)
it was using `Expands`, the same in torch doc, but we also have expand so it's confusing
This commit is contained in:
@@ -1228,7 +1228,7 @@ class Tensor:
|
||||
|
||||
def unflatten(self, dim:int, sizes:Tuple[int,...]):
|
||||
"""
|
||||
Expands dimension `dim` of the tensor over multiple dimensions specified by `sizes`.
|
||||
Unflattens dimension `dim` of the tensor into multiple dimensions specified by `sizes`. `Tensor.flatten()` is the inverse of this function.
|
||||
|
||||
```python exec="true" source="above" session="tensor" result="python"
|
||||
print(Tensor.ones(3, 4, 1).unflatten(1, (2, 2)).shape)
|
||||
|
||||
Reference in New Issue
Block a user