def get_class(class_name, module_paths=None):
    'Returns the class based on class name.\n\n    Args:\n        class_name (str): Name or full path to the class.\n        module_paths (list): Paths to candidate modules to search for the\n            class. This is used if the class cannot be located solely based on\n            `class_name`. The first module in the list that contains the class\n            is used.\n\n    Returns:\n        The target class.\n\n    Raises:\n        ValueError: If class is not found based on :attr:`class_name` and\n            :attr:`module_paths`.\n    '
    class_ = locate(class_name)
    if ((class_ is None) and (module_paths is not None)):
        for module_path in module_paths:
            class_ = locate('.'.join([module_path, class_name]))
            if (class_ is not None):
                break
    if (class_ is None):
        raise ValueError('Class not found in {}: {}'.format(module_paths, class_name))
    return class_
Returns the class based on class name.

Args:
    class_name (str): Name or full path to the class.
    module_paths (list): Paths to candidate modules to search for the
        class. This is used if the class cannot be located solely based on
        `class_name`. The first module in the list that contains the class
        is used.

Returns:
    The target class.

Raises:
    ValueError: If class is not found based on :attr:`class_name` and
        :attr:`module_paths`.
def get_class(class_name, module_paths=None):
    'Returns the class based on class name.\n\n    Args:\n        class_name (str): Name or full path to the class.\n        module_paths (list): Paths to candidate modules to search for the\n            class. This is used if the class cannot be located solely based on\n            `class_name`. The first module in the list that contains the class\n            is used.\n\n    Returns:\n        The target class.\n\n    Raises:\n        ValueError: If class is not found based on :attr:`class_name` and\n            :attr:`module_paths`.\n    '
    class_ = locate(class_name)
    if ((class_ is None) and (module_paths is not None)):
        for module_path in module_paths:
            class_ = locate('.'.join([module_path, class_name]))
            if (class_ is not None):
                break
    if (class_ is None):
        raise ValueError('Class not found in {}: {}'.format(module_paths, class_name))
    return class_