MCPcopy Create free account
hub / github.com/OpenNMT/CTranslate2 / dtype

Method dtype

python/ctranslate2/specs/model_spec.py:737–738  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

735
736 @property
737 def dtype(self) -> str:
738 return str(self.tensor.dtype).replace("torch.", "")
739
740 def numpy(self) -> np.ndarray:
741 return self.tensor.detach().numpy()

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected