def url_to_fn(url):
    """
    Convert `url` to filename used to download the datasets.

    ``http://kitakitsune.org/xe`` -> ``kitakitsune.org_xe``.

    Args:
        url (str): URL of the resource.

    Returns:
        str: Normalized URL.
    """
    url = url.replace("http://", "").replace("https://", "")
    url = url.split("?")[0]

    return url.replace("%", "_").replace("/", "_")