broadcast_arrays

broadcast_arrays(*args)

Broadcast any number of arrays against each other.

Parameters:
`*args` : a list of ndarrays

The arrays to broadcast.

Returns:
broadcasted : list of arrays

These arrays are copies of the original arrays unless that all the input arrays have the same shape, the input list of arrays are returned instead of a list of copies.

Examples

>>> x = np.array([[1,2,3]])
>>> y = np.array([[4],[5]])
>>> np.broadcast_arrays(x, y)
[array([[1., 2., 3.],
       [1., 2., 3.]]), array([[4., 4., 4.],
       [5., 5., 5.]])]