ImageNet_Utils
ImageNet_Utils copied to clipboard
ImportError: No module named imagedownloader
include
python _init_paths.py as part of the instructions in the README file or recommended fix the imports
This can be fixed by changing _init_paths.py
in a way that allows downloadutils.py
to be run from anywhere, rather than just within ImageNet_Utils
.
Here is a fixed version of _init_paths.py
:
import os.path as osp
import sys
def add_path(path):
if path not in sys.path:
sys.path.insert(0, path)
this_dir = osp.dirname(__file__)
add_path(osp.join(this_dir,'libs'))