class_docstr: Output layer for joint intent classification and slot-filling models.
  Intent classification is a document classification problem and slot filling
  is a word tagging problem. Thus terms these can be used interchangeably in the
  documentation.
  
  Args:
      doc_output (ClassificationOutputLayer): Output layer for intent
          classification task. See
          :class:`~pytext.models.output_layers.ClassificationOutputLayer` for
          details.
      word_output (WordTaggingOutputLayer): Output layer for slot filling task.
          See :class:`~pytext.models.output_layers.WordTaggingOutputLayer` for
          details.
  
  Attributes:
      doc_output (type): Output layer for intent classification task.
      word_output (type): Output layer for slot filling task.
docstr: Compute and return prediction and scores from the model.
  
  Args:
      logit (Tuple[torch.Tensor, torch.Tensor]): Logits returned by
          :class:`~pytext.models.joint_model.JointModel`. It's tuple
          containing logits for intent classification and slot filling.
      targets (Optional[torch.Tensor]): Not applicable. Defaults to None.
      context (Optional[Dict[str, Any]]): Context is a dictionary of items
          that's passed as additional metadata. Defaults to None.
  
  Returns:
      Tuple[torch.Tensor, torch.Tensor]: Model prediction and scores.
docstr_tok: ["Compute","and","return","prediction","and","scores","from","the","model",".","Args",":","logit","(","Tuple","[","torch.Tensor",",","torch.Tensor","]",")",":","Logits","returned","by",":","class",":","`","~pytext.models.joint_model.JointModel","`",".","It","'s","tuple","containing","logits","for","intent","classification","and","slot","filling",".","targets","(","Optional","[","torch.Tensor","]",")",":","Not","applicable",".","Defaults","to","None",".","context","(","Optional","[","Dict","[","str",",","Any","]","]",")",":","Context","is","a","dictionary","of","items","that","'s","passed","as","additional","metadata",".","Defaults","to","None",".","Returns",":","Tuple","[","torch.Tensor",",","torch.Tensor","]",":","Model","prediction","and","scores","."]
code: def get_pred(
      self,
      logits: Tuple[torch.Tensor, torch.Tensor],
      targets: Optional[torch.Tensor] = None,
      context: Optional[Dict[str, Any]] = None,
  ) -> Tuple[torch.Tensor, torch.Tensor]:
      """Compute and return prediction and scores from the model.
  
      Args:
          logit (Tuple[torch.Tensor, torch.Tensor]): Logits returned by
              :class:`~pytext.models.joint_model.JointModel`. It's tuple
              containing logits for intent classification and slot filling.
          targets (Optional[torch.Tensor]): Not applicable. Defaults to None.
          context (Optional[Dict[str, Any]]): Context is a dictionary of items
              that's passed as additional metadata. Defaults to None.
  
      Returns:
          Tuple[torch.Tensor, torch.Tensor]: Model prediction and scores.
  
      """
      d_logit, w_logit = logits
      if DatasetFieldName.TOKEN_INDICES in context:
          w_logit = query_word_reprs(
              w_logit, context[DatasetFieldName.TOKEN_INDICES]
          )
      d_pred, d_score = self.doc_output.get_pred(d_logit, None, context)
      w_pred, w_score = self.word_output.get_pred(
          w_logit, None, context
      )
      return (d_pred, w_pred), (d_score, w_score)
  
imports: from typing import Any, Dict, List, Optional, Tuple, Union
  import torch
  import torch.nn
  from caffe2.python import core
  from pytext.common.constants import DatasetFieldName
  from pytext.data.utils import Vocabulary
  from pytext.models.module import create_module
  from pytext.utils.usage import log_class_usage
  from torch import jit
  from .doc_classification_output_layer import ClassificationOutputLayer
  from .output_layer_base import OutputLayerBase
  from .utils import query_word_reprs
  from .word_tagging_output_layer import CRFOutputLayer, WordTaggingOutputLayer
label_desc: Use image node_id 4 for calling the IntentSlotOutputLayer obj's underlying member method code with example usage: obj.get_pred(logits, targets, context) and returns: d_pred,  w_pred,  d_score,  w_score