Skip to content

Instantly share code, notes, and snippets.

@joeyism
Created October 7, 2019 15:45
Show Gist options
  • Save joeyism/3c8f6ee975b02873943877d88966d644 to your computer and use it in GitHub Desktop.
Save joeyism/3c8f6ee975b02873943877d88966d644 to your computer and use it in GitHub Desktop.
from allennlp.models.archival import load_archive
from allennlp.predictors.predictor import Predictor
SERIALIZATION_DIR = './model'
archive = load_archive(SERIALIZATION_DIR)
predictor = Predictor.from_archive(archive, 'model')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment