LabelCellsResults

LabelCellsResults

Wrapper around the cell labelling results on the Wasm heap, typically produced by labelCells.

Methods

fineTuningDelta(optionsopt) → {Float64Array|Float64WasmArray}

Source:
Parameters:
Name Type Attributes Default Description
options object <optional>
{}

Optional parameters.

Properties
Name Type Attributes Default Description
copy boolean | string <optional>
true

Copying mode, see possibleCopy for details.

Returns:

Array of length equal to the number of cells, containing the difference in scores between the best and second-best label during fine-tuning.

Type
Float64Array | Float64WasmArray

free()

Source:
Returns:

Frees the memory allocated on the Wasm heap for this object. This invalidates this object and all references to it.

numberOfCells() → {number}

Source:
Returns:

Number of cells that were labelled.

Type
number

numberOfLabels() → {number}

Source:
Returns:

Number of labels used in labelCells.

Type
number

predictedLabels(optionsopt) → {Int32Array|Int32WasmArray}

Source:
Parameters:
Name Type Attributes Default Description
options object <optional>
{}

Optional parameters.

Properties
Name Type Attributes Default Description
copy boolean | string <optional>
true

Copying mode, see possibleCopy for details.

Returns:

Array of length equal to the number of cells, containing the index of the best label for each cell.

Type
Int32Array | Int32WasmArray

scoresForCell(i, optionsopt) → {Float64Array|Float64WasmArray}

Source:
Parameters:
Name Type Attributes Default Description
i number

Index of the cell of interest.

options object <optional>
{}

Optional parameters.

Properties
Name Type Attributes Default Description
copy boolean | string <optional>
true

Copying mode, see possibleCopy for details. Only used if buffer is not supplied.

buffer Float64WasmArray <optional>
<nullable>
null

Buffer in which to store the output. This should have the same length as the numberOfLabels.

Returns:

Array containing the scores for this cell across all labels. If buffer is supplied, it is used as the return value.

Type
Float64Array | Float64WasmArray

scoresForLabel(i, optionsopt) → {Float64Array|Float64WasmArray}

Source:
Parameters:
Name Type Attributes Default Description
i number

Index of the label of interest.

options object <optional>
{}

Optional parameters.

Properties
Name Type Attributes Default Description
copy boolean | string <optional>
true

Copying mode, see possibleCopy for details. Only used if buffer is not supplied.

buffer Float64WasmArray <optional>
<nullable>
null

Buffer in which to store the output. This should have the same length as the numberOfCells.

Returns:

Array containing the scores across all cells for this label. If buffer is supplied, it is used as the return value.

Type
Float64Array | Float64WasmArray