-
Notifications
You must be signed in to change notification settings - Fork 25
Description
Abstract(μμ½) π₯
run-all.sh multi gpu μ€ν μ μΌλΆ task(dependency parsing)κ° μ μμ μΌλ‘ μλνμ§ μμ΅λλ€.
error-message:
RuntimeError: The size of tensor a (23) must match the size of tensor b (25) at non-singleton dimension 2
How to Reproduce(μ¬ν λ°©λ²) π€
[python==3.7.11]
git clone --recursive https://github.com/KLUE-benchmark/KLUE-Baseline.git
pip install -r requirements.txt
pip install torch==1.7.0+cu110 -f https://download.pytorch.org/whl/torch_stable.html (cuda version matching with torch)
run-all.sh μμ :
KLUE-DP
task="klue-dp"
python run_klue.py train --task ${task} --output_dir ${OUTPUT_DIR} --data_dir ${DATA_DIR}/${task}-${VERSION} --model_name_or_path klue/roberta-large --learning_rate 5e-5 --num_train_epochs 15 --gradient_accumulation_steps 1 --warmup_ratio 0.2 --train_batch_size 32 --patience 10000 --max_seq_length 256 --metric_key uas_macro_f1 --gpus 0 --num_workers 4
->
python run_klue.py train --task ${task} --output_dir ${OUTPUT_DIR} --data_dir ${DATA_DIR}/${task}-${VERSION} --model_name_or_path klue/roberta-large --learning_rate 3e-5 --num_train_epochs 10 --train_batch_size 16 --eval_batch_size 16 --max_seq_length 510 --gradient_accumulation_steps 2 --warmup_ratio 0.2 --weight_decay 0.01 --max_grad_norm 1.0 --patience 100000 --metric_key slot_micro_f1 --gpus 1 2 3 --num_workers 8
bash run-all.sh
RuntimeError: The size of tensor a (23) must match the size of tensor b (25) at non-singleton dimension 2
How to solve (μ΄λ»κ² ν΄κ²°ν μ μμκΉμ) πββ
single GPUμμ λ©λͺ¨λ¦¬ λΆμ‘±μΌλ‘ roBERTa-Large λͺ¨λΈλ‘ νμ΅μ΄ λΆκ°νμ¬
νΉμ λμ λ°μ μ μμκΉ μΆμ΄ λ¬Έμλ립λλ€!
κ°μ¬ν©λλ€.