Skip to content

Commit

Permalink
remove unused infiniteloop
Browse files Browse the repository at this point in the history
  • Loading branch information
Xiaoming-Zhao committed Nov 16, 2024
1 parent 2781067 commit db65caa
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions examples/images/cifar10/train_cifar10_ddp.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
from torch.utils.data import DistributedSampler
from torchdyn.core import NeuralODE
from torchvision import datasets, transforms
from utils_cifar import ema, generate_samples, infiniteloop, setup
from utils_cifar import ema, generate_samples, setup

from torchcfm.conditional_flow_matching import (
ConditionalFlowMatcher,
Expand Down Expand Up @@ -102,8 +102,6 @@ def train(rank, total_num_gpus, argv):
drop_last=True,
)

datalooper = infiniteloop(dataloader)

# Calculate number of epochs
steps_per_epoch = math.ceil(len(dataset) / FLAGS.batch_size)
num_epochs = math.ceil(FLAGS.total_steps / steps_per_epoch)
Expand Down

0 comments on commit db65caa

Please sign in to comment.