Skip to content

Interface: AttentionMapOptions ​

Defined in: ml/charts.ts:344

Properties ​

annotate? ​

ts
optional annotate?: boolean;

Defined in: ml/charts.ts:352

Draw each weight in its cell (small maps only). Default false.


colormap? ​

ts
optional colormap?: ColormapSpec;

Defined in: ml/charts.ts:350


keys? ​

ts
optional keys?: number;

Defined in: ml/charts.ts:349


queries? ​

ts
optional queries?: number;

Defined in: ml/charts.ts:348

Required with a flat weights.


weights ​

ts
weights: ArrayLike<number> | number[][];

Defined in: ml/charts.ts:346

Attention weights, query×key: a flat row-major array or a 2-D array.

MIT licensed. WebGL2 required.