Download the ontology and stores it in CLASSIFIER_WORKDIR.

def _download_ontology(url, local_file):
    """Download the ontology and stores it in CLASSIFIER_WORKDIR."""
    current_app.logger.debug(
        "Copying remote ontology '%s' to file '%s'." % (url, local_file)
    )
    try:
        request = requests.get(url, stream=True)
        if request.status_code == 200:
            with open(local_file, 'wb') as f:
                for chunk in request.iter_content(chunk_size):
                    f.write(chunk)
    except IOError as e:
        current_app.logger.exception(e)
        return False
    else:
        current_app.logger.debug("Done copying.")
        return True