def _as_dict(module):
    """
    Returns publicly names values in module's __dict__.
    """
    try:
        return {k: v for k, v in module.__dict__.iteritems() if not k[0:1] == '_'}
    except AttributeError:
        return {}