报错:Cannot find declaration to go to
if type(resFile) == str or type(resFile) == unicode: NameError: name ‘unicode’ is not defined
解决一:pip install scikit-image
但我按照这个方法没有解决:
解决二:pip install -U 'git+https://github.com/cocodataset/cocoapi.git#subdirectory=PythonAPI'
这个方法也没有解决
解决三:
把这一行代码
if type(resFile) == str or type(resFile) == unicode:
改为:
if type(resFile) == str or (PYTHON_VERSION == 2 and type(resFile) == unicode):
这个方法还是未能解决
解决四:
把这一行代码
if type(resFile) == str or type(resFile) == unicode:
改为:
if type(resFile) == str or type(resFile) == bytes:
这个方法解决了