From f956d012ce54ad0907e6c15443ff99058157305e Mon Sep 17 00:00:00 2001 From: Nicolas Hug Date: Tue, 11 Jul 2023 13:29:24 +0000 Subject: [PATCH] remove comment --- references/detection/coco_utils.py | 1 - references/detection/utils.py | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/references/detection/coco_utils.py b/references/detection/coco_utils.py index 7b42faad1e8..06b21021b84 100644 --- a/references/detection/coco_utils.py +++ b/references/detection/coco_utils.py @@ -231,7 +231,6 @@ def get_coco(root, image_set, transforms, mode="instances", use_v2=False): img_folder = os.path.join(root, img_folder) ann_file = os.path.join(root, ann_file) - # TODO: cleanup if use_v2: dataset = torchvision.datasets.CocoDetection(img_folder, ann_file, transforms=transforms) # TODO: need to update target_keys to handle masks for segmentation! diff --git a/references/detection/utils.py b/references/detection/utils.py index f73915580f7..f67226ffedb 100644 --- a/references/detection/utils.py +++ b/references/detection/utils.py @@ -262,9 +262,9 @@ def init_distributed_mode(args): args.rank = int(os.environ["RANK"]) args.world_size = int(os.environ["WORLD_SIZE"]) args.gpu = int(os.environ["LOCAL_RANK"]) - elif "SLURM_PROCID" in os.environ: - args.rank = int(os.environ["SLURM_PROCID"]) - args.gpu = args.rank % torch.cuda.device_count() + # elif "SLURM_PROCID" in os.environ: + # args.rank = int(os.environ["SLURM_PROCID"]) + # args.gpu = args.rank % torch.cuda.device_count() else: print("Not using distributed mode") args.distributed = False