In train.py, you use next(iter(train_loader)) to fetch the patches every iteration.
However , in such way you build an iterator of train_loader every iteration,and next() would return the first element of the iterator every time, which means during the whole iteration there is only one subject is used to training.
I'm just confused about this.Could anyone give me some explanation or discussion?
In
train.py
, you usenext(iter(train_loader))
to fetch the patches every iteration.However , in such way you build an iterator of train_loader every iteration,and
next()
would return the first element of the iterator every time, which means during the whole iteration there is only one subject is used to training.I'm just confused about this.Could anyone give me some explanation or discussion?