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

Method zeros

ot/backend.py:1559–1563  ·  view source on GitHub ↗
(self, shape, type_as=None)

Source from the content-addressed store, hash-verified

1557 return jax.lax.stop_gradient(a)
1558
1559 def zeros(self, shape, type_as=None):
1560 if type_as is None:
1561 return jnp.zeros(shape)
1562 else:
1563 return self._change_device(jnp.zeros(shape, dtype=type_as.dtype), type_as)
1564
1565 def ones(self, shape, type_as=None):
1566 if type_as is None:

Callers 1

eliminate_zerosMethod · 0.95

Calls 2

_change_deviceMethod · 0.95
zerosMethod · 0.45

Tested by

no test coverage detected