占坑
由两分支组成:检测分支和分割分支组成;
1) roi_heads.append(("keypoint", build_roi_keypoint_head(cfg, in_channels)))
2) roi_heads = CombinedROIHeads(cfg, roi_heads)
1)build_roi_keypoint_head可查看modeling\roi_heads\keypoint_head\keypoint_head.py
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved.
import torch
from .box_head.box_head import build_roi_box_head
from .mask_head.mask_head import build_roi_mask_head
from .keypoint_head.keypoint_head import build_roi_keypoint_head
class CombinedROIHeads(torch.nn.ModuleDict):
"""
Combines a set of individual heads (for box prediction or masks) into a single
head.
"""
def __init__(self, cfg, heads):
super(CombinedROIHeads, self).__init__(heads)
self.cfg = cfg.clone()
if cfg.MO

本文档详细记录了maskrcnn_benchmark中modeling/roi_heads/roi_heads.py模块的理解,该模块包含检测和分割两个关键分支。通过对build_roi_keypoint_head的分析,深入探讨关键点检测头的实现细节。
最低0.47元/天 解锁文章
2486

被折叠的 条评论
为什么被折叠?



