@frozen
public struct StringTensor
extension StringTensor: TensorGroup
StringTensor
is a multi-dimensional array whose elements are String
s.
-
The underlying
TensorHandle
.Note
handle
is public to allow user defined ops, but should not normally be used otherwise.Declaration
public let handle: TensorHandle<String>
-
Declaration
public init(handle: TensorHandle<String>)
-
Declaration
public init(shape: TensorShape, scalars: [String])
-
Creates a 0-D
StringTensor
from a scalar value.Declaration
public init(_ value: String)
-
Creates a 1-D
StringTensor
in from contiguous scalars.Declaration
public init(_ scalars: [String])
-
Declaration
public var array: ShapedArray<String> { get }
-
Declaration
public var scalars: [String] { get }
-
Computes
self == other
element-wise.Note
elementsEqual
supports broadcasting.Declaration
public func elementsEqual(_ other: StringTensor) -> Tensor<Bool>
-
Declaration
public init(_owning tensorHandles: UnsafePointer<CTensorHandle>?)
-
Declaration
public init<C: RandomAccessCollection>( _handles: C ) where C.Element: _AnyTensorHandle