MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / Tensor

Method Tensor

tensorflow/core/framework/tensor.h:191–192  ·  view source on GitHub ↗

A series of specialized constructors for scalar tensors in host memory. NOTE: The `Variant` host-scalar constructor is not defined, because Variant is implicitly constructible from many different types, and this causes ambiguities with some compilers.

Source from the content-addressed store, hash-verified

189 // is implicitly constructible from many different types, and this causes
190 // ambiguities with some compilers.
191 explicit Tensor(float scalar_value)
192 : Tensor(scalar_value, host_scalar_tag{}) {}
193 explicit Tensor(double scalar_value)
194 : Tensor(scalar_value, host_scalar_tag{}) {}
195 explicit Tensor(int32 scalar_value)

Callers

nothing calls this directly

Calls 1

tstringClass · 0.85

Tested by

no test coverage detected