(self, index)
| 56 | label_transform=label_transform) |
| 57 | |
| 58 | def __getitem__(self, index): |
| 59 | # return img, mask, img_name, scale_float |
| 60 | crop_size = cfg.DATASET.CROP_SIZE |
| 61 | if ',' in crop_size: |
| 62 | crop_size = [int(x) for x in crop_size.split(',')] |
| 63 | else: |
| 64 | crop_size = int(crop_size) |
| 65 | crop_size = [crop_size, crop_size] |
| 66 | |
| 67 | img = torch.FloatTensor(np.zeros([3] + crop_size)) |
| 68 | mask = torch.LongTensor(np.zeros(crop_size)) |
| 69 | img_name = f'img{index}' |
| 70 | scale_float = 0.0 |
| 71 | return img, mask, img_name, scale_float |
| 72 | |
| 73 | def __len__(self): |
| 74 | return 3000 |
nothing calls this directly
no outgoing calls
no test coverage detected