It actually returns a nested empty list. For example, try
x = np.array([np.array([]),np.array([]),np.array([])]) >>> array([], shape=(3, 0), dtype=float64)
or
>>> print x.shape (3, 0)
Don't let print x pins fool you. These types of outputs simply reflect the (aesthetic) choice of __str__ and __repr__ . To see the exact measurement, you need to use things like .shape .
source share