(model_dir, root_path)
| 281 | videoWriter.release() |
| 282 | |
| 283 | def run_from_train(model_dir, root_path): |
| 284 | if not os.path.exists(os.path.join(model_dir, 'results')): |
| 285 | os.makedirs(os.path.join(model_dir, 'results')) |
| 286 | retinanet = torch.load(os.path.join(model_dir, 'model_final.pt')) |
| 287 | |
| 288 | use_gpu = True |
| 289 | |
| 290 | if use_gpu: retinanet = retinanet.cuda() |
| 291 | |
| 292 | retinanet.eval() |
| 293 | |
| 294 | for seq_num in [2, 4, 5, 9, 10, 11, 13]: |
| 295 | run_each_dataset(model_dir, retinanet, root_path, 'train', 'MOT17-{:02d}'.format(seq_num)) |
| 296 | for seq_num in [1, 3, 6, 7, 8, 12, 14]: |
| 297 | run_each_dataset(model_dir, retinanet, root_path, 'test', 'MOT17-{:02d}'.format(seq_num)) |
| 298 | |
| 299 | def main(args=None): |
| 300 | parser = argparse.ArgumentParser(description='Simple script for testing a CTracker network.') |
nothing calls this directly
no test coverage detected