Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add condlane #20

Merged
merged 15 commits into from
Sep 11, 2021
Prev Previous commit
Next Next commit
update datasets/registry
  • Loading branch information
Turoad committed Jul 8, 2021
commit 99f09eb2db9f87fd57cc57817451cd4136ddcb2b
5 changes: 2 additions & 3 deletions lanedet/datasets/registry.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,16 +32,15 @@ def build_dataloader(split_cfg, cfg, is_train=True):
shuffle = True
else:
shuffle = False
batch_size=cfg.batch_size

dataset = build_dataset(split_cfg, cfg)

init_fn = partial(
worker_init_fn, seed=cfg.seed)

samples_per_gpu = batch_size#cfg.batch_size // cfg.gpus
samples_per_gpu = cfg.batch_size // cfg.gpus
data_loader = torch.utils.data.DataLoader(
dataset, batch_size = batch_size, shuffle = shuffle,
dataset, batch_size = cfg.batch_size, shuffle = shuffle,
num_workers = cfg.workers, pin_memory = False, drop_last = False,
collate_fn=partial(collate, samples_per_gpu=samples_per_gpu),
worker_init_fn=init_fn)
Expand Down