MCPcopy Index your code
hub / github.com/DeepLabCut/DeepLabCut / select_device

Function select_device

deeplabcut/pose_estimation_pytorch/modelzoo/utils.py:168–172  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

166
167
168def select_device():
169 if torch.cuda.is_available():
170 return torch.device("cuda:0")
171 else:
172 return torch.device("cpu")
173
174
175def raise_warning_if_called_directly():

Callers 1

keypoint_matchingFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected