Package-level declarations

Sequence labeling algorithms.

Sequence labeling is a type of pattern recognition task that involves the algorithmic assignment of a categorical label to each member of a sequence of observed values. Common examples include part-of-speech tagging, named-entity recognition, and gene prediction.

Functions

Link copied to clipboard
fun crf(sequences: Array<Array<Tuple>>, labels: Array<IntArray>, options: CRF.Options): CRF

Fits a first-order linear conditional random field with given hyperparameters.

fun <T> crf(sequences: Array<Array<T>>, labels: Array<IntArray>, options: CRF.Options, features: (T) -> Tuple): CRFLabeler<T>

Fits a first-order linear conditional random field labeler for generic observation objects with given hyperparameters.

fun crf(sequences: Array<Array<Tuple>>, labels: Array<IntArray>, ntrees: Int = 100, maxDepth: Int = 20, maxNodes: Int = 100, nodeSize: Int = 5, shrinkage: Double = 1.0): CRF

Fits a first-order linear conditional random field.

fun <T> crf(sequences: Array<Array<T>>, labels: Array<IntArray>, ntrees: Int = 100, maxDepth: Int = 20, maxNodes: Int = 100, nodeSize: Int = 5, shrinkage: Double = 1.0, features: (T) -> Tuple): CRFLabeler<T>

Fits a first-order linear conditional random field labeler for generic observation objects.

Link copied to clipboard
fun <T> gcrf(sequences: Array<Array<T>>, labels: Array<IntArray>, options: CRF.Options, features: (T) -> Tuple): CRFLabeler<T>

Fits a first-order linear conditional random field labeler for generic observation objects with given hyperparameters. This is an alias for crf matching the Scala API convention.

fun <T> gcrf(sequences: Array<Array<T>>, labels: Array<IntArray>, ntrees: Int = 100, maxDepth: Int = 20, maxNodes: Int = 100, nodeSize: Int = 5, shrinkage: Double = 1.0, features: (T) -> Tuple): CRFLabeler<T>

Fits a first-order linear conditional random field labeler for generic observation objects. This is an alias for crf matching the Scala API convention.

Link copied to clipboard
fun hmm(observations: Array<IntArray>, labels: Array<IntArray>): HMM

Fits a first-order Hidden Markov Model by maximum likelihood estimation.

fun <T> hmm(observations: Array<Array<T>>, labels: Array<IntArray>, ordinal: (T) -> Int): HMMLabeler<T>

Fits a first-order Hidden Markov Model sequence labeler for generic observation objects.

Creates a first-order Hidden Markov Model from initial, transition, and emission probability arrays.

fun hmm(pi: DoubleArray, a: DenseMatrix, b: DenseMatrix): HMM

Creates a first-order Hidden Markov Model from initial, transition, and emission probabilities.