taokz / BiomedGPT

BiomedGPT: A Unified and Generalist Biomedical Generative Pre-trained Transformer for Vision, Language, and Multimodal Tasks
Apache License 2.0
363 stars 34 forks source link

omegaconf.errors.ConfigAttributeError: Key 'use_ema_weights_to_init_param' is not in struct #15

Closed nghiemkythu closed 6 months ago

nghiemkythu commented 6 months ago

Hello, When I use the weight in checkpoints folder after pre-training to finetune on VQA-RAD, I have the error: omegaconf.errors.ConfigAttributeError: Key 'use_ema_weights_to_init_param' is not in struct When I use your checkpoint named "biomedgpt_tiny.pt", I still have this error. How can I solve this problem ?

nghiemkythu commented 6 months ago

I have fixed this error by changing self.cfg.checkpoint.use_ema_weights_to_init_param to self.cfg.checkpoint.get("use_ema_weights_to_init_param", False) and it works.