crf_decode_forward: CRF decode forward

Description Usage Arguments Value

View source: R/text_ops.R

Description

Computes forward decoding in a linear-chain CRF.

Usage

1
crf_decode_forward(inputs, state, transition_params, sequence_lengths)

Arguments

inputs

A [batch_size, num_tags] matrix of unary potentials.

state

A [batch_size, num_tags] matrix containing the previous step's score values.

transition_params

A [num_tags, num_tags] matrix of binary potentials.

sequence_lengths

A [batch_size] vector of true sequence lengths.

Value

backpointers: A [batch_size, num_tags] matrix of backpointers. new_state: A [batch_size, num_tags] matrix of new score values.


tfaddons documentation built on July 2, 2020, 2:12 a.m.