From 97af7f0f1493383b47a77b75a932523f20b4cf75 Mon Sep 17 00:00:00 2001 From: Wuyang LI Date: Thu, 29 Feb 2024 22:08:40 +0800 Subject: [PATCH] Correct target domain evluation data splits C2F: use all training data since val (500) is not enough for evaluation; P2C: use all training data since val (500) is not enough for evaluation; C2B: use val data since it is sufficient --- datasets/DAOD.py | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/datasets/DAOD.py b/datasets/DAOD.py index cae27ec..f9fdb08 100644 --- a/datasets/DAOD.py +++ b/datasets/DAOD.py @@ -41,8 +41,8 @@ def get_paths(root): 'train_data_list': root / 'Cityscapes/AOOD_Main/train_target.txt', 'val_xml': root / 'Cityscapes/AOOD_Annotations', - 'val_data_list': root / 'Cityscapes/AOOD_Main/val_target.txt', - + # 'val_data_list': root / 'Cityscapes/AOOD_Main/val_target.txt', + 'val_data_list': root / 'Cityscapes/AOOD_Main/train_target.txt', }, 'sim10k': { 'train_img': root / 'sim10k/VOC2012/JPEGImages', @@ -152,14 +152,9 @@ def build(image_set, cfg, multi_task_eval_id=4): if image_set == 'val': if cfg.DATASET.DA_MODE == 'aood': return AOODDetection( - # For C2F and P2C - img_folder=paths[target_domain]['train_img'], - ann_folder=paths[target_domain]['train_xml'], - data_list=paths[target_domain]['train_data_list'], - # For C2B - # img_folder=paths[target_domain]['val_img'], - # ann_folder=paths[target_domain]['val_xml'], - # data_list=paths[target_domain]['val_data_list'], + img_folder=paths[target_domain]['val_img'], + ann_folder=paths[target_domain]['val_xml'], + data_list=paths[target_domain]['val_data_list'], transforms=make_coco_transforms(image_set), remove_unk=False, setting= cfg.DATASET.AOOD_SETTING,