def import_entry_point(fullname):
    (module_name, classname) = partition(fullname)
    try:
        import_module(module_name)
        # This is done to ensure we get the right submodule
        module = __import__(module_name)
        for submodule in module_name.split('.')[1:]:
            module = getattr(module, submodule)
        LOG.debug("Importing class: %s", classname)
        cls = getattr(module, classname)
        # TODO(harlowja) actually verify this is a class??
    except (ImportError, AttributeError, ValueError) as err:
        raise RuntimeError('Could not load entry point %s: %s' %
                           (fullname, err))
    return cls
Given a name import the class and return it.
dataset/ETHPy150Open openstack/anvil/anvil/importer.py/import_entry_point