KyGao / ABGNN

PyTorch code for KDD 2023 paper "Pre-training Antibody Language Models for Antigen-Specific Computational Antibody Design"
MIT License
49 stars 5 forks source link

inference crash #3

Open sahamitul opened 7 months ago

sahamitul commented 7 months ago

Hi there,

When I run finetune-exp2.sh, I get crash at the inference part:-

python3 inference.py --cktpath checkpoints/exp2/pflen5_iter5_loss1_1_2_lr0.0001_bsz2_seed128/checkpoint_best.pt

Traceback (most recent call last): File "/home/mitul/projs/bime.2023/antibody_design/ABGNN/inference.py", line 111, in main(args) File "/home/mitul/projs/bime.2023/antibody_design/ABGNN/inference.py", line 20, in main modelhub = AntibodyRobertaModel.from_pretrained( File "/home/mitul/projs/bime.2023/antibody_design/ABGNN/fairseq_models/models/ab_roberta_base.py", line 377, in from_pretrained model = cls.build_model(args, task, inference) File "/home/mitul/projs/bime.2023/antibody_design/ABGNN/fairseq_models/models/ab_roberta_base.py", line 250, in build_model base_architecture(args) File "/home/mitul/projs/bime.2023/antibody_design/ABGNN/fairseq_models/models/ab_roberta_base.py", line 569, in base_architecture args.encoder_layers = getattr(args, "encoder_layers", 12) AttributeError: 'NoneType' object has no attribute 'encoder_layers'

Any ideas? Thanks!

sahamitul commented 7 months ago

Someone posted a similar issue: https://stackoverflow.com/questions/76617741/empty-value-for-stateargs-when-i-load-model-with-bartmodel-from-pretained

but no reply yet.