()
| 16 | |
| 17 | |
| 18 | def test_array_dataset(): |
| 19 | size = (10,) |
| 20 | data_shape = (3, 256, 256) |
| 21 | label_shape = (1,) |
| 22 | data = np.random.randint(0, 255, size + data_shape) |
| 23 | label = np.random.randint(0, 9, size + label_shape) |
| 24 | dataset = ArrayDataset(data, label) |
| 25 | assert dataset[0][0].shape == data_shape |
| 26 | assert dataset[0][1].shape == label_shape |
| 27 | assert len(dataset) == size[0] |
| 28 | |
| 29 | |
| 30 | def test_array_dataset_dim_error(): |
nothing calls this directly
no test coverage detected