MCPcopy Create free account
hub / github.com/deepdrive/deepdrive / get_available_gpus

Function get_available_gpus

install.py:109–112  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

107
108
109def get_available_gpus():
110 from tensorflow.python.client import device_lib
111 local_device_protos = device_lib.list_local_devices()
112 return [x.name for x in local_device_protos if x.device_type == 'GPU']
113
114
115if __name__ == '__main__':

Callers 1

get_tf_validFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected