File tree Expand file tree Collapse file tree 1 file changed +16
-3
lines changed
Expand file tree Collapse file tree 1 file changed +16
-3
lines changed Original file line number Diff line number Diff line change @@ -398,19 +398,32 @@ def load_layer(self):
398398
399399 # print(volume.shape)
400400 # print(volume.dtype)
401-
402- load_transforms = Compose (
401+ if self . use_window :
402+ load_transforms = Compose (
403403 [
404404 ToTensor (),
405405 # anisotropic_transform,
406406 AddChannel (),
407- SpatialPad (spatial_size = pad ),
407+ # SpatialPad(spatial_size=pad),
408408 AddChannel (),
409409 EnsureType (),
410410 ],
411411 map_items = False ,
412412 log_stats = True ,
413413 )
414+ else :
415+ load_transforms = Compose (
416+ [
417+ ToTensor (),
418+ # anisotropic_transform,
419+ AddChannel (),
420+ SpatialPad (spatial_size = pad ),
421+ AddChannel (),
422+ EnsureType (),
423+ ],
424+ map_items = False ,
425+ log_stats = True ,
426+ )
414427
415428 self .log ("\n Loading dataset..." )
416429 input_image = load_transforms (volume )
You can’t perform that action at this time.
0 commit comments