MoRe复现过程
环境安装
在校园服务器上运行,不需要考虑服务器费用,故直接使用conda安装,耗费一天自动安装完成。
下载resnet50权重
wget https://storage.googleapis.com/tensorflow/keras-applications/resnet/resnet50_weights_tf_dim_ordering_tf_kernels.h5 -O RESNET50_ORIGINAL_WEIGHTS.h5
从谷歌服务器下载文件并重命名
警告
出现了一些兼容性警告,暂时略过
报错
IndexError: arrays used as indices must be of integer (or boolean) type
错误发生在general_generator_center函数中
具体是pidB = np.array(idB)[posB]这行出现索引类型错误
需要检查idB和posB的数据类型
可能是idB或posB包含非整数类型
通过Cline解决了报错
IndexError: index 4708 is out of bounds for axis 0 with size 3607
错误发生在三元组训练阶段,索引4708超出data_camA数组大小3607
需要检查generator.py中general_generator_center函数的索引生成逻辑
可能是posA数组生成时计算错误
需要添加边界检查确保索引不越界
同样通过Cline解决
浙公网安备 33010602011771号