def _load_module(modulepath):
 mod = __import__(modulepath)
 path = []
 for token in modulepath.split('.')[1:]:
  path.append(token)
  mod = getattr(mod, token)
 return mod

def _load_module ( modulepath ) : mod = __import__ ( modulepath ) path = [ ] for token in modulepath . split ( '.' ) [ 1 : ] : path . append ( token ) mod = getattr ( mod , token ) return mod
load module modulepath and return the last module object in the module path .