class_docstr: Configuration for running a :class:`SegmentAnythingModel`.
  
  See :class:`fiftyone.utils.torch.TorchImageModelConfig` for additional
  arguments.
  
  Args:
      auto_kwargs (None): a dictionary of keyword arguments to pass to
          ``segment_anything.SamAutomaticMaskGenerator(model, **auto_kwargs)``
      points_mask_index (None): an optional mask index to use for each
          keypoint output
class_docstr_tok: ["Configuration","for","running","a",":","class",":","`","SegmentAnythingModel","`",".","See",":","class",":","`","fiftyone.utils.torch.TorchImageModelConfig","`","for","additional","arguments",".","Args",":","auto_kwargs","(","None",")",":","a","dictionary","of","keyword","arguments","to","pass","to","``","segment_anything.SamAutomaticMaskGenerator","(","model",",","*","*","auto_kwargs",")","``","points_mask_index","(","None",")",":","an","optional","mask","index","to","use","for","each","keypoint","output"]
code: def __init__(self, d):
      d = self.init(d)
      super().__init__(d)
  
      self.auto_kwargs = self.parse_dict(d, "auto_kwargs", default=None)
      self.points_mask_index = self.parse_int(
          d, "points_mask_index", default=None
      )
      if (
          self.points_mask_index
          and not 0 <= self.points_mask_index <= 2
      ):
          raise ValueError("mask_index must be 0, 1, or 2")
  
imports: import numpy
  import eta.core.utils
  import fiftyone.core.labels
  import fiftyone.core.utils
  import fiftyone.utils.torch
  import fiftyone.zoo.models
  import torch
label_desc: Use image node_id 1 to create a new SegmentAnythingModelConfig object from inherited base classes: fout, fozm with example: obj = SegmentAnythingModelConfig(d)