jupyter-notebookcondaallennlp

Location of downloaded model when using Predictor.from_path in AllenNLP?


I'm following AllenNLP's example code for correference resolution, which has a method Predictor.from_path:

from allennlp.predictors.predictor import Predictor
import allennlp_models.tagging

predictor = Predictor.from_path("https://storage.googleapis.com/allennlp-public-models/coref-spanbert-large-2021.03.10.tar.gz")

I'm running this in a Jupyter notebook, in a conda environment. When I execute the example snippet, the model file is downloaded, which is ~1.5gb in size.

I'm wondering where this file was downloaded to, so I can potentially clean it up if necessary? It's not in ~/conda/env/<my env>, ~/.jupyter, ~/.local/share/jupyter/, /tmp, or the working directory where the notebook is.


Solution

  • It goes into ~/.allennlp/cache/.