MCPcopy Create free account
hub / github.com/pytorch/pytorch / float

Method float

torch/storage.py:158–160  ·  view source on GitHub ↗

Casts this storage to float type.

(self)

Source from the content-addressed store, hash-verified

156 return self._to(torch.double)
157
158 def float(self):
159 """Casts this storage to float type."""
160 return self._to(torch.float)
161
162 def half(self):
163 """Casts this storage to half type."""

Callers 15

_tensor_strFunction · 0.45
testFunction · 0.45
testFunction · 0.45
testFunction · 0.45
get_a_test_layerMethod · 0.45
decodeMethod · 0.45
test_cuda_halfMethod · 0.45
test_dtypeMethod · 0.45
test_toMethod · 0.45

Calls 1

_toMethod · 0.95

Tested by 15

get_a_test_layerMethod · 0.36
decodeMethod · 0.36
test_cuda_halfMethod · 0.36
test_dtypeMethod · 0.36
test_toMethod · 0.36
mixed_type_producerFunction · 0.36
get_tensor_from_raw_BGRFunction · 0.36
test_load_tensorMethod · 0.36