class_docstr: A class the mimicks the output of a classifier or regressor to
  allow testing of functionality that depends on it without
  inference overhead.
class_docstr_tok: ["A","class","the","mimicks","the","output","of","a","classifier","or","regressor","to","allow","testing","of","functionality","that","depends","on","it","without","inference","overhead","."]
docstr: Parameters
  ----------
      out_dim
          The number of output classes.
      out_type
          Indicates if probabilities, class predictions or continuous outputs
          are generated.
docstr_tok: ["Parameters","--","--","--","--","--","out_dim","The","number","of","output","classes",".","out_type","Indicates","if","probabilities",",","class","predictions","or","continuous","outputs","are","generated","."]
code: def __init__(
      self,
      out_dim: int,
      out_type: str = "proba",
      model_type: Optional[str] = None,
      seed: Optional[int] = None,
  ) -> None:
      """
      Parameters
      ----------
          out_dim
              The number of output classes.
          out_type
              Indicates if probabilities, class predictions or continuous outputs
              are generated.
  
      """
  
      np.random.seed(seed)
  
      self.out_dim = out_dim
      self.num_outputs = out_dim
      self.out_type = out_type
      self.model_type = model_type  # Required to emulate `shap` model wrapper arguments, see test_shap_wrappers.py
      if out_type not in OUT_TYPES:
          raise ValueError(
              "Unknown output type. Accepted values are {}".format(
                  OUT_TYPES
              )
          )
  
file_path: alibi/alibi/tests/utils.py
imports: from contextlib import contextmanager
  from typing import Optional
  import numpy
label_desc: Use image node_id 1 to create a new MockPredictor object  with example: obj = MockPredictor(out_dim, out_type, model_type, seed)