|
1 | 1 | from datetime import datetime |
2 | 2 | from functools import cached_property |
3 | | -from typing import Dict, NamedTuple, Sequence |
| 3 | +from typing import NamedTuple, Sequence |
4 | 4 |
|
5 | 5 | import numpy as np |
6 | 6 | import pandas as pd |
@@ -42,14 +42,14 @@ class LUNA25(Dataset): |
42 | 42 | Parameters |
43 | 43 | ---------- |
44 | 44 | root : str, Path, optional |
45 | | - path to the folder containing `luna25_images` and `luna25_nodule_blocks` folders and |
| 45 | + path to the folder containing `luna25_images` and `luna25_nodule_blocks` folders and |
46 | 46 | `LUNA25_Public_Training_Development_Data.csv` file obtained by the instruction at |
47 | 47 | https://luna25.grand-challenge.org/datasets/. |
48 | 48 | If not provided, the cache is assumed to be already populated. |
49 | 49 |
|
50 | 50 | Notes |
51 | 51 | ----- |
52 | | - Join the challenge at https://luna25.grand-challenge.org/. |
| 52 | + Join the challenge at https://luna25.grand-challenge.org/. |
53 | 53 | Then follow the download and extraction instructions at https://luna25.grand-challenge.org/datasets/. |
54 | 54 | """ |
55 | 55 |
|
@@ -109,8 +109,8 @@ def nodules(self, i): |
109 | 109 | coords = (row.CoordX, row.CoordY, row.CoordZ) |
110 | 110 | center_voxel = sitk_image.TransformPhysicalPointToIndex(map(int, coords))[::-1] |
111 | 111 |
|
112 | | - nodule_block_metadata = self.nodule_block_metadata(row.AnnotationID) |
113 | | - bbox_start_point = sitk_image.TransformPhysicalPointToIndex(map(int, nodule_block_metadata['origin'][::-1]))[::-1] |
| 112 | + nodule_block_origin = self.nodule_block_metadata(row.AnnotationID)['origin'][::-1] |
| 113 | + bbox_start_point = sitk_image.TransformPhysicalPointToIndex(map(int, nodule_block_origin))[::-1] |
114 | 114 | bbox = np.array([bbox_start_point, np.minimum(bbox_start_point + bbox_size, shape)]) |
115 | 115 | nodules.append( |
116 | 116 | LUNA25Nodule( |
|
0 commit comments