|
16 | 16 | from utils import AverageMeter, colorEncode, accuracy, intersectionAndUnion, parse_devices, setup_logger |
17 | 17 | from lib.nn import user_scattered_collate, async_copy_to |
18 | 18 | from lib.utils import as_numpy |
19 | | -import lib.utils.data as torchdata |
20 | 19 | import cv2 |
21 | 20 | from tqdm import tqdm |
22 | 21 |
|
@@ -94,7 +93,7 @@ def worker(cfg, gpu_id, start_idx, end_idx, result_queue): |
94 | 93 | cfg.DATASET.list_val, |
95 | 94 | cfg.DATASET, |
96 | 95 | start_idx=start_idx, end_idx=end_idx) |
97 | | - loader_val = torchdata.DataLoader( |
| 96 | + loader_val = torch.utils.data.DataLoader( |
98 | 97 | dataset_val, |
99 | 98 | batch_size=cfg.VAL.batch_size, |
100 | 99 | shuffle=False, |
@@ -211,10 +210,9 @@ def main(cfg, gpus): |
211 | 210 |
|
212 | 211 | # absolute paths of model weights |
213 | 212 | cfg.MODEL.weights_encoder = os.path.join( |
214 | | - cfg.DIR, 'encoder' + cfg.VAL.suffix) |
| 213 | + cfg.DIR, 'encoder_' + cfg.VAL.checkpoint) |
215 | 214 | cfg.MODEL.weights_decoder = os.path.join( |
216 | | - cfg.DIR, 'decoder' + cfg.VAL.suffix) |
217 | | - |
| 215 | + cfg.DIR, 'decoder_' + cfg.VAL.checkpoint) |
218 | 216 | assert os.path.exists(cfg.MODEL.weights_encoder) and \ |
219 | 217 | os.path.exists(cfg.MODEL.weights_decoder), "checkpoint does not exitst!" |
220 | 218 |
|
|
0 commit comments