classification-pytorch icon indicating copy to clipboard operation
classification-pytorch copied to clipboard

大佬,我在Ubuntu上跑训练的时候报这个错误一直找不到解决方法能帮我看看吗

Open txg-GANGGANG opened this issue 2 years ago • 2 comments

Traceback (most recent call last): File "train.py", line 452, in fit_one_epoch(model_train, model, loss_history, optimizer, epoch, epoch_step, epoch_step_val, gen, gen_val, UnFreeze_Epoch, Cuda, fp16, save_period, save_dir, local_rank) File "/mnt/class_master/utils/utils_fit.py", line 116, in fit_one_epoch if (math.floor(epoch) + 1) % save_period == 0 or math.floor(epoch)+1 == Epoch: TypeError: unsupported operand type(s) for %: 'int' and 'str'

txg-GANGGANG avatar Mar 09 '23 03:03 txg-GANGGANG

你的Epoch为啥是一个str呀

bubbliiiing avatar Mar 10 '23 15:03 bubbliiiing

0 0

bubbliiiing avatar Mar 10 '23 15:03 bubbliiiing