surveilling-surveillance/detection/models/__init__.py
2021-05-20 13:22:04 -07:00

14 lines
317 B
Python

import argparse
from util import Args
from .classification import *
from .detection import *
def get_model(model_args):
model_args_ = model_args
if isinstance(model_args, argparse.Namespace):
model_args_ = Args(vars(model_args))
return globals().copy()[model_args_.get("model")](model_args_)