MCPcopy Create free account
hub / github.com/NVIDIA/TensorRT / setup

Function setup

samples/python/detectron2/eval_coco.py:48–56  ·  view source on GitHub ↗

Create config and perform basic setup.

(config_file, weights)

Source from the content-addressed store, hash-verified

46 raise NotImplementedError("Evaluator type is not supported")
47
48def setup(config_file, weights):
49 """
50 Create config and perform basic setup.
51 """
52 cfg = get_cfg()
53 cfg.merge_from_file(config_file)
54 cfg.merge_from_list(["MODEL.WEIGHTS", weights])
55 cfg.freeze()
56 return cfg
57
58def main(args):
59 # Set up Detectron 2 config and build evaluator.

Callers 1

mainFunction · 0.70

Calls 1

freezeMethod · 0.80

Tested by

no test coverage detected