class_docstr: Compute the log-likelihood of the input assuming a conditional random field
  model.
  
  Args:
      num_tags: The number of tags
class_docstr_tok: ["Compute","the","log-likelihood","of","the","input","assuming","a","conditional","random","field","model",".","Args",":","num_tags",":","The","number","of","tags"]
docstr: Compute log-likelihood of input.
  
  Args:
      emissions: Emission values for different tags for each input. The
          expected shape is batch_size * seq_len * num_labels. Padding is
          should be on the right side of the input.
      tags: Actual tags for each token in the input. Expected shape is
          batch_size * seq_len
docstr_tok: ["Compute","log-likelihood","of","input",".","Args",":","emissions",":","Emission","values","for","different","tags","for","each","input",".","The","expected","shape","is","batch_size","*","seq_len","*","num_labels",".","Padding","is","should","be","on","the","right","side","of","the","input",".","tags",":","Actual","tags","for","each","token","in","the","input",".","Expected","shape","is","batch_size","*","seq_len"]
code: def forward(
      self,
      emissions: torch.Tensor,
      tags: torch.Tensor,
      reduce: bool = True,
  ) -> torch.Tensor:
      """
      Compute log-likelihood of input.
  
      Args:
          emissions: Emission values for different tags for each input. The
              expected shape is batch_size * seq_len * num_labels. Padding is
              should be on the right side of the input.
          tags: Actual tags for each token in the input. Expected shape is
              batch_size * seq_len
      """
      mask = self._make_mask_from_targets(tags)
  
      numerator = self._compute_joint_llh(emissions, tags, mask)
      denominator = self._compute_log_partition_function(
          emissions, mask
      )
  
      llh = numerator - denominator
      return llh if not reduce else torch.mean(llh)
  
imports: from typing import List
  import torch
  import torch.jit
  import torch.nn
  from caffe2.python.crf_predict import apply_crf
  from pytext.utils.usage import log_class_usage
label_desc: Use image node_id 5 for calling the CRF obj's underlying member method code with example usage: obj.forward(emissions, tags, reduce) and returns: unknown