// flatten out dimensions beyond the first
first_dim = ary.shape[0]
newshape = np.product(ary.shape[1:]).astype(int)
ary = ary.reshape((first_dim, newshape), order="F")
return ary
def _scale_text(figsize, textsize, scale_ratio=2):
After Change
In case the array is already more than 2 dimensional, will ravel the
dimensions after the first.
dim_0, *_ = np.atleast_1d(ary).shape
return ary.reshape(dim_0, -1, order="F")
def _scale_text(figsize, textsize, scale_ratio=2):