MCPcopy Create free account
hub / github.com/PythonOT/POT / _change_device

Method _change_device

ot/backend.py:1531–1532  ·  view source on GitHub ↗
(self, a, type_as)

Source from the content-addressed store, hash-verified

1529 return a.device_buffer.device()
1530
1531 def _change_device(self, a, type_as):
1532 return jax.device_put(a, self._get_device(type_as))
1533
1534 def _from_numpy(self, a, type_as=None):
1535 if isinstance(a, float):

Callers 6

_from_numpyMethod · 0.95
zerosMethod · 0.95
onesMethod · 0.95
fullMethod · 0.95
eyeMethod · 0.95
linspaceMethod · 0.95

Calls 1

_get_deviceMethod · 0.95

Tested by

no test coverage detected