Open cvsekhar opened 4 years ago
I see. Will fix the bug of infinite loops. The hyper-parameters are not ideal for this dataset either (I will change the README with an updated set). Meanwhile, you can try this one
CUDA_VISIBLE_DEVICES=0 python train_ditto.py \
--task Structured/Beer \
--batch_size 32 \
--max_len 128 \
--lr 3e-5 \
--n_epochs 40 \
--finetuning \
--lm roberta \
--fp16 \
--da drop_col
which should work better.
I have this same error before as well, forgot to capture this
/data/home/vijaya.chennupati/.conda/envs/txtclass/lib/python3.8/site-packages/sklearn/metrics/_classification.py:1221: UndefinedMetricWarning: Precision is ill-defined and being set to 0.0 due to no predicted samples. Use zero_division
parameter to control this behavior.
_warn_prf(average, modifier, msg_start, len(result))
accuracy=0.846
precision=0.000
recall=0.000
f1=0.000
I am using CPU ... so removed the parameter --fp16 , no luck runs into infinite loop
I see. I tried the CPU version and got the same error. It seems to be related to data augmentation but I am not sure. I tried the baseline version (no DA) and it works fine on CPU:
CUDA_VISIBLE_DEVICES= python train_ditto.py --task Structured/Beer --batch_size 32 --max_len 128 --lr 3e-5 --n_epochs 40 --finetuning --lm distilbert
You might also use this colab notebook to run it on GPUs.
Will give it a try.
Hello, does the latest version fixed this bug? I also have this problem when I use CPU to train my program...
I was trying to execute the training code on a cpu. With the following hyperparemeters. python train_ditto.py \ --task Structured/Beer \ --batch_size 64 \ --max_len 64 \ --lr 3e-5 \ --n_epochs 5 \ --finetuning \ --lm distilbert \ --da del \ --dk product \ --save_model \ --summarize
I think some how the dev_f1 score is zero and the accuracy stuck at 0.84 and the epoch is not increased and its going in loops since due to the while loop in mixda is epoch <= hp.n_epochs.
is there something I am missing or is it going in an infinite loop