Open AADeLucia opened 2 years ago
Nevermind, seems to be working when I pass in max_tokens=max_source_positions
in scripts/inference.py
bart = BARTModel.from_pretrained(
model_dir,
checkpoint_file=model_file,
data_name_or_path=bin_folder,
gpt2_encoder_json=encoder_file,
gpt2_vocab_bpe=vocab_file,
max_source_positions=max_source_positions,
max_tokens=max_source_positions
)
I am trying to use
scripts/prep.sh
andscripts/inference.py
to load/reddit_vanilla_actual/checkpoint_best.pt
BART for inference. I have been having many issues, mostly related to package versions and the extended2048
source positions.Environment:
And I tried installing
fairseq
from source to access theexamples
module, but then I saw you had your own copy of fairseq in this repo so I installed your version according to the instructions hereI binarized
val.source
andval.target
from and am running inference as such:And I get the following error:
Am I using the wrong version of a package? Is there something extra needed for this to work?