pymoose.squeeze
pymoose.squeeze#
- pymoose.squeeze(x, axis=None, placement=None)[source]#
Reduce out any singleton dimensions of
x.- Parameters
x – The tensor from which to drop singleton dimensions.
axis – Optional index into the shape of
xdenoting which singleton dimension to drop. If None, drops all singleton dimensions inx.placement – An optional
Placementto pin this operation to.
- Returns
The squeezed tensor with fewer singleton dimensions.