import pkg_resources


def pkg_resource_filename(path):
    """Return absolute filepath for the given input path.

    Args:
        path: str, filepath name.

    Returns
        str, absolute filepath name.
    """
    path_vals = path.split('/')
    abs_filename = pkg_resources.resource_filename('.'.join(path_vals[:-1]),
                                                   path_vals[-1])
    return abs_filename