Skip to content

[Fix] delete data_root in CocoOccludedSeparatedMetric to fix bug #9969

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 17, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 0 additions & 7 deletions mmdet/evaluation/metrics/coco_occluded_metric.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
# Copyright (c) OpenMMLab. All rights reserved.

import os.path as osp
from typing import Dict, List, Optional, Union

import mmengine
Expand Down Expand Up @@ -68,11 +66,6 @@ def __init__(
metric: Union[str, List[str]] = ['bbox', 'segm'],
**kwargs) -> None:
super().__init__(*args, metric=metric, **kwargs)
# load from local file
if osp.isfile(occluded_ann) and not osp.isabs(occluded_ann):
occluded_ann = osp.join(self.data_root, occluded_ann)
if osp.isfile(separated_ann) and not osp.isabs(separated_ann):
separated_ann = osp.join(self.data_root, separated_ann)
self.occluded_ann = load(occluded_ann)
self.separated_ann = load(separated_ann)
self.score_thr = score_thr
Expand Down