Skip to content

Commit 94a6245

Browse files
authoredOct 15, 2024··
Fix bug when enable --quad training option (#13355)
* fix: quad training * fix: quad training in segmentation
1 parent abdfbd6 commit 94a6245

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed
 

‎utils/dataloaders.py

+1
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,7 @@ def create_dataloader(
210210
shuffle=shuffle and sampler is None,
211211
num_workers=nw,
212212
sampler=sampler,
213+
drop_last=quad,
213214
pin_memory=PIN_MEMORY,
214215
collate_fn=LoadImagesAndLabels.collate_fn4 if quad else LoadImagesAndLabels.collate_fn,
215216
worker_init_fn=seed_worker,

‎utils/segment/dataloaders.py

+1
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ def create_dataloader(
7575
shuffle=shuffle and sampler is None,
7676
num_workers=nw,
7777
sampler=sampler,
78+
drop_last=quad,
7879
pin_memory=True,
7980
collate_fn=LoadImagesAndLabelsAndMasks.collate_fn4 if quad else LoadImagesAndLabelsAndMasks.collate_fn,
8081
worker_init_fn=seed_worker,

0 commit comments

Comments
 (0)
Please sign in to comment.