type(imgs): |
<class 'numpy.ndarray'>
--------
imgs.shape |
(40,)
-------
imgs[0].shape |
(3, 512, 512)
-------
imgs
255, 255, 255, 255, 255, 255, 255, 255]]], dtype=uint8)], |
dtype=object)
-------
imgs[0].dtype |
dtype('uint8')
-------
imgs.dtype |
dtype('O')
-------
imgs[39].dtype |
dtype('uint8')
我想将imgs格式化为dtype('uint8')的4D np.array,而不是dtype('Object')的1D np.array,其中每个元素都是dtype('uint8')的3D np.array )。