其他分享
首页 > 其他分享> > SSD测试训练数据出现的问题

SSD测试训练数据出现的问题

作者:互联网

1. TypeError: '>' not supported between instances of 'builtin_function_or_method' and 'int'

 

 

解决方法

~/caffe/python/caffe$ vim model_libs.py

   将assert len > 0注释掉变成下面,16行

#assert int(len) > 0

2. TypeError: 1.0 has type float, but expected one of: int, long

 

 

 解决方法

vim model_libs.py

156行(vim中输入,156gg可以快速到达156行)

pad = int((3 + (dilation - 1) * 2) - 1) / 2
改为
pad = int((3 + (dilation - 1) * 2) - 1) // 2

375行

pad = int((kernel_size + (dilation - 1) * (kernel_size - 1)) - 1) / 2
改为
pad = int((kernel_size + (dilation - 1) * (kernel_size - 1)) - 1) // 2

417行

pad = int((kernel_size + (dilation - 1) * (kernel_size - 1)) - 1) / 2
改为
pad = int((kernel_size + (dilation - 1) * (kernel_size - 1)) - 1) // 2

 



 

标签:kernel,训练,int,vim,pad,测试,SSD,dilation,size
来源: https://www.cnblogs.com/yangyuqing/p/13064377.html