File size: 859 Bytes
128757a
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved.
# from .rpn import build_rpn
from .rpn import RPNModule
from .retina import RetinaNetModule
from .fcos import FCOSModule
from .atss import ATSSModule
from .dyhead import DyHeadModule
from .vldyhead import VLDyHeadModule

_RPN_META_ARCHITECTURES = {"RPN": RPNModule,
                           "RETINA": RetinaNetModule,
                           "FCOS": FCOSModule,
                           "ATSS": ATSSModule,
                           "DYHEAD": DyHeadModule,
                           "VLDYHEAD": VLDyHeadModule
                           }


def build_rpn(cfg):
    """

    This gives the gist of it. Not super important because it doesn't change as much

    """
    rpn_arch = _RPN_META_ARCHITECTURES[cfg.MODEL.RPN_ARCHITECTURE]
    return rpn_arch(cfg)