Skip to content

< Back


TensorSplitsCollection

Namespace: LLama.Abstractions

A fixed size array to set the tensor splits across multiple GPUs

1
public sealed class TensorSplitsCollection : System.Collections.Generic.IEnumerable`1[[System.Single, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]], System.Collections.IEnumerable

Inheritance ObjectTensorSplitsCollection
Implements IEnumerable<Single>, IEnumerable
Attributes NullableContextAttribute, NullableAttribute, DefaultMemberAttribute, JsonConverterAttribute

Properties

Length

The size of this array

1
public int Length { get; }

Property Value

Int32

Item

1
public float Item { get; set; }

Property Value

Single

Constructors

TensorSplitsCollection(Single[])

Create a new tensor splits collection, copying the given values

1
public TensorSplitsCollection(Single[] splits)

Parameters

splits Single[]

Exceptions

ArgumentException

TensorSplitsCollection()

Create a new tensor splits collection with all values initialised to the default

1
public TensorSplitsCollection()

Methods

Clear()

Set all values to zero

1
public void Clear()

GetEnumerator()

1
public IEnumerator<float> GetEnumerator()

Returns

IEnumerator<Single>


< Back