Table of Contents

Class NTMWriteHead<T>

Namespace
AiDotNet.MetaLearning.Algorithms
Assembly
AiDotNet.dll

NTM write head for content-based addressing.

public class NTMWriteHead<T>

Type Parameters

T

The numeric type.

Inheritance
NTMWriteHead<T>
Inherited Members

Constructors

NTMWriteHead(int, int)

Initializes a new instance of NTMWriteHead.

public NTMWriteHead(int memoryWidth, int memorySize)

Parameters

memoryWidth int

The width of each memory slot.

memorySize int

The number of memory slots.

Methods

Clone()

Clones the write head.

public NTMWriteHead<T> Clone()

Returns

NTMWriteHead<T>

A new write head with the same configuration.

ComputeWriteWeights(Tensor<T>, NTMMemory<T>)

Computes write weights using cosine similarity.

public Vector<T> ComputeWriteWeights(Tensor<T> key, NTMMemory<T> memory)

Parameters

key Tensor<T>

The key tensor.

memory NTMMemory<T>

The memory matrix.

Returns

Vector<T>

The write weights vector.