mednli
mednli copied to clipboard
Load our pre-trained model
Thank you for providing medmli! I was wondering if you could assist me by telling me how could I run your code like InferSent demo.pynb?
https://github.com/DAVEZJ/Simple_Sentence_Simliarity/blob/0f564adedad62f1bbe13265ca3848d98e8b363f6/Simple_Sentence_Similarity.ipynb
Hi,
What is the problem exactly? The InferSent model is available in this repository: https://github.com/jgc128/mednli_baseline
I am trying to figure out how I can run your scripts with code line below.
if FULL:
import torch
from models import InferSent
V = 1
MODEL_PATH = 'encoder/infersent1.pkl'
params_model = {'bsize': 64, 'word_emb_dim': 300, 'enc_lstm_dim': 2048,
'pool_type': 'max', 'dpout_model': 0.0, 'version': V}
infersent = InferSent(params_model)
infersent.load_state_dict(torch.load(MODEL_PATH))
infersent.set_w2v_path(PATH_TO_GLOVE)
Here is the notebook that I plan to use: