TF 2.0 is out! Get hands-on practice at TF World, Oct 28-31. Use code TF20 for 20% off select passes. Register now

tfa.text.crf_decode_backward

View source on GitHub

Computes backward decoding in a linear-chain CRF.

Aliases:

tfa.text.crf_decode_backward(
    inputs,
    state
)

Args:

  • inputs: A [batch_size, num_tags] matrix of backpointer of next step (in time order).
  • state: A [batch_size, 1] matrix of tag index of next step.

Returns:

  • new_tags: A [batch_size, num_tags] tensor containing the new tag indices.