taokz / BiomedGPT

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

train.py: error: unrecognized arguments: --warmup-ratio=0.04 #24

Closed wangpengyu-debug closed 2 months ago

wangpengyu-debug commented 3 months ago

When I run bash train_vqa_rad_beam_scale.sh, an error message of train.py: error: unrecognized arguments: --warmup-ratio=0.04 is generated in the log file. What should I do?

image
taokz commented 3 months ago

@wangpengyu-debug Did you use the fairseq library from this repo? The argument warmup-ratio is in fairseq/fairseq/optim/lr_scheduler/polynomial_decay_schedule.py. Using fairseq from other sources may not work.

You can activate a new environment, install all dependencies including this fairseq version via pip install requirements.txt.

wangpengyu-debug commented 3 months ago

Another question Would you like to know if the medmnist.py file is the latest version? (For preprocessing the MedMNIST dataset, the following steps are employed: First, the .npy files are converted to .png images using the command python medmnist.py --mode 0. Subsequently, these .png images are converted into a .tsv file using the command --mode 1) There is no ability to output {dataset}_class2label.pkl in Medmnist.py, which would make it impossible to train and evaluate on the medmnist dataset。

image image
taokz commented 3 months ago

There is the class2labl information in scripts/preprocess/finetuning/medmnist.py, you can use the INFO_DICT['bloodmnist']['label'], and save it to be pkl.