class_docstr: This is a mixin class to support scalar -> RGBA mapping.  Handles
  normalization and colormapping
docstr: *norm* is an instance of :class:`colors.Normalize` or one of
  its subclasses, used to map luminance to 0-1. *cmap* is a
  :mod:`cm` colormap instance, for example :data:`cm.jet`
docstr_tok: ["*","norm","*","is","an","instance","of",":","class",":","`","colors.Normalize","`","or","one","of","its","subclasses",",","used","to","map","luminance","to","0-1",".","*","cmap","*","is","a",":","mod",":","`","cm","`","colormap","instance",",","for","example",":","data",":","`","cm.jet","`"]
code: def __init__(self, norm=None, cmap=None):
      """
      *norm* is an instance of :class:`colors.Normalize` or one of
      its subclasses, used to map luminance to 0-1. *cmap* is a
      :mod:`cm` colormap instance, for example :data:`cm.jet`
      """
  
      self.callbacksSM = cbook.CallbackRegistry(("changed",))
  
      if cmap is None:
          cmap = get_cmap()
      if norm is None:
          norm = colors.Normalize()
  
      self._A = None
      self.norm = norm
      self.cmap = cmap
      self.colorbar = None
      self.update_dict = {"array": False}
  
imports: import numpy
  from numpy import ma
  import matplotlib
  import matplotlib.colors
  import matplotlib.cbook
  from matplotlib._cm import *
label_desc: Use image node_id 1 to create a new ScalarMappable object  with example: obj = ScalarMappable(norm, cmap)