Commit 86bd6c79 authored by Michael Carilli's avatar Michael Carilli
Browse files

resolving delete conflicts

parents d2ac4872 ca2baffb
...@@ -82,7 +82,6 @@ def fast_collate(batch): ...@@ -82,7 +82,6 @@ def fast_collate(batch):
tensor = torch.zeros( (len(imgs), 3, h, w), dtype=torch.uint8 ) tensor = torch.zeros( (len(imgs), 3, h, w), dtype=torch.uint8 )
for i, img in enumerate(imgs): for i, img in enumerate(imgs):
nump_array = np.asarray(img, dtype=np.uint8) nump_array = np.asarray(img, dtype=np.uint8)
tens = torch.from_numpy(nump_array)
if(nump_array.ndim < 3): if(nump_array.ndim < 3):
nump_array = np.expand_dims(nump_array, axis=-1) nump_array = np.expand_dims(nump_array, axis=-1)
nump_array = np.rollaxis(nump_array, 2) nump_array = np.rollaxis(nump_array, 2)
......
...@@ -86,7 +86,6 @@ def fast_collate(batch): ...@@ -86,7 +86,6 @@ def fast_collate(batch):
tensor = torch.zeros( (len(imgs), 3, h, w), dtype=torch.uint8 ) tensor = torch.zeros( (len(imgs), 3, h, w), dtype=torch.uint8 )
for i, img in enumerate(imgs): for i, img in enumerate(imgs):
nump_array = np.asarray(img, dtype=np.uint8) nump_array = np.asarray(img, dtype=np.uint8)
tens = torch.from_numpy(nump_array)
if(nump_array.ndim < 3): if(nump_array.ndim < 3):
nump_array = np.expand_dims(nump_array, axis=-1) nump_array = np.expand_dims(nump_array, axis=-1)
nump_array = np.rollaxis(nump_array, 2) nump_array = np.rollaxis(nump_array, 2)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment