Closed Sine7812 closed 2 months ago
Hi! Please check whether the dataloader is well prepared. The iterable
may be null
.
Thank you for your reply. I have solved this problem. Since I just wanted to test whether the code could run, but the K400 dataset is too large, I only prepared a few video files and created a small dataset according to the author's format. However, when I tried distributed training, due to the relatively small size of the dataset and the possible inappropriate configuration of the batch size, the DataLoader may not have generated any batches during actual operation. After adjusting these settings, I successfully solved the problem.
Traceback (most recent call last): File "/mnt/e/code/VideoMamba-main/videomamba/video_sm/run_class_finetuning.py", line 715, in
main(opts, ds_init)
File "/mnt/e/code/VideoMamba-main/videomamba/video_sm/run_class_finetuning.py", line 632, in main
train_stats = train_one_epoch(
File "/mnt/e/code/VideoMamba-main/videomamba/video_sm/engines/engine_for_finetuning.py", line 48, in train_one_epoch
for data_iterstep, (samples, targets, , _) in enumerate(metric_logger.log_every(data_loader, print_freq, header)):
File "/mnt/e/code/VideoMamba-main/videomamba/video_sm/utils.py", line 164, in log_every
header, total_time_str, total_time / len(iterable)))
ZeroDivisionError: float division by zero
Has anyone encountered this problem before? How can I solve it? Thank you very much.