lib.utils.enforce_shape¶
- lib.utils.enforce_shape(x, y, grid=True)¶
Broadcast
xandyarrays.- Parameters
x (array_like) – Input x-array, scalar, 1D or 2D if not
grid.y (array_like) – Input y-array, scalar, 1D or 2D if not
grid.grid (bool, default=True) – If
grid, andx,ynot scalars, add dimension toxsuch thatxandycan be broadcast (e.g.x*y, is shape(len(x),) + y.shape). Else, simply return x,y.
- Returns
x (array) – x-array.
y (array) – y-array.