MCPcopy
hub / github.com/facebookresearch/detectron2 / func

Method func

tests/structures/test_boxes.py:199–202  ·  view source on GitHub ↗
(x)

Source from the content-addressed store, hash-verified

197
198 def test_scriptability(self):
199 def func(x):
200 boxes = Boxes(x)
201 test = boxes.to(torch.device("cpu")).tensor
202 return boxes.area(), test
203
204 f = torch.jit.script(func)
205 f = reload_script_model(f)

Callers

nothing calls this directly

Calls 4

toMethod · 0.95
areaMethod · 0.95
BoxesClass · 0.90
deviceMethod · 0.45

Tested by

no test coverage detected