bubbliiiing / yolact-pytorch

这是一个yolact-pytorch的库,可用于训练自己的数据集
MIT License
70 stars 12 forks source link

File "mtrand.pyx", line 920, in numpy.random.mtrand.RandomState.choice ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (6,) + inhomogeneous part. #24

Open dyhisbig opened 4 months ago

dyhisbig commented 4 months ago

训练自己的数据集,出现这个问题 File "mtrand.pyx", line 920, in numpy.random.mtrand.RandomState.choice ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (6,) + inhomogeneous part.

dyhisbig commented 4 months ago

图片

dyhisbig commented 4 months ago

左边是博主的json文件,右边是我的json文件,整体内容还是一样的,不知道是不是labelme版本不一样导致的

dyhisbig commented 4 months ago

应该不是数据集的问题,我下载了shapes数据集博主网盘的数据集,还是会出现上述错误

dyhisbig commented 4 months ago

![Uploading 图片.png…]()

dyhisbig commented 4 months ago

mode = random.choice(self.sample_options) File "mtrand.pyx", line 920, in numpy.random.mtrand.RandomState.choice ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (6,) + inhomogeneous part. 我在kaggle上,找了个数据集,划分好的,还是这个问题,不捣鼓了,没意思

XYz-dev-max commented 4 months ago

博主后来有再了解吗,遇到了相同的问题,没看懂啥意思

ge548 commented 1 month ago

mode = random.choice(self.sample_options) File "mtrand.pyx", line 920, in numpy.random.mtrand.RandomState.choice ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (6,) + inhomogeneous part. 我在kaggle上,找了个数据集,划分好的,还是这个问题,不捣鼓了,没意思

augmentations.py中RandomSampleCrop()函数问题,我是注释了这个函数可以运行了,不进行随机裁剪。