class_docstr: base class for a 4-panel imshow (RGB, R, G, B)
  
  Layout:
  +---------------+-----+
  |               |  R  |
  +               +-----+
  |      RGB      |  G  |
  +               +-----+
  |               |  B  |
  +---------------+-----+
  
  Attributes
  ----------
  _defaultAxesClass : matplotlib.axes.Axes
      defaults to 'Axes' in RGBAxes child class.
      No default in abstract base class
  RGB : _defaultAxesClass
      The axes object for the three-channel imshow
  R : _defaultAxesClass
      The axes object for the red channel imshow
  G : _defaultAxesClass
      The axes object for the green channel imshow
  B : _defaultAxesClass
      The axes object for the blue channel imshow
class_docstr_tok: ["base","class","for","a","4-panel","imshow","(","RGB",",","R",",","G",",","B",")","Layout",":","+","--","--","--","--","--","--","--","-+","--","--","-+","|","|","R","|","+","+","--","--","-+","|","RGB","|","G","|","+","+","--","--","-+","|","|","B","|","+","--","--","--","--","--","--","--","-+","--","--","-+","Attributes","--","--","--","--","--","_defaultAxesClass",":","matplotlib.axes.Axes","defaults","to","'Axes","'","in","RGBAxes","child","class",".","No","default","in","abstract","base","class","RGB",":","_defaultAxesClass","The","axes","object","for","the","three-channel","imshow","R",":","_defaultAxesClass","The","axes","object","for","the","red","channel","imshow","G",":","_defaultAxesClass","The","axes","object","for","the","green","channel","imshow","B",":","_defaultAxesClass","The","axes","object","for","the","blue","channel","imshow"]
docstr: Parameters
  ----------
  pad : float
      fraction of the axes height to put as padding.
      defaults to 0.0
  add_all : bool
      True: Add the {rgb, r, g, b} axes to the figure
      defaults to True.
  axes_class : matplotlib.axes.Axes
  
  kl :
      Unpacked into axes_class() init for RGB
  kwargs :
      Unpacked into axes_class() init for RGB, R, G, B axes
docstr_tok: ["Parameters","--","--","--","--","--","pad",":","float","fraction","of","the","axes","height","to","put","as","padding",".","defaults","to","0.0","add_all",":","bool","True",":","Add","the","{","rgb",",","r",",","g",",","b","}","axes","to","the","figure","defaults","to","True",".","axes_class",":","matplotlib.axes.Axes","kl",":","Unpacked","into","axes_class","(",")","init","for","RGB","kwargs",":","Unpacked","into","axes_class","(",")","init","for","RGB",",","R",",","G",",","B","axes"]
code: def __init__(self, *kl, **kwargs):
      """
      Parameters
      ----------
      pad : float
          fraction of the axes height to put as padding.
          defaults to 0.0
      add_all : bool
          True: Add the {rgb, r, g, b} axes to the figure
          defaults to True.
      axes_class : matplotlib.axes.Axes
  
      kl :
          Unpacked into axes_class() init for RGB
      kwargs :
          Unpacked into axes_class() init for RGB, R, G, B axes
      """
      pad = kwargs.pop("pad", 0.0)
      add_all = kwargs.pop("add_all", True)
      try:
          axes_class = kwargs.pop("axes_class", self._defaultAxesClass)
      except AttributeError:
          new_msg = (
              "A subclass of RGBAxesBase must have a "
              "_defaultAxesClass attribute. If you are not sure which "
              "axes class to use, consider using "
              "mpl_toolkits.axes_grid1.mpl_axes.Axes."
          )
          six.reraise(
              AttributeError, AttributeError(new_msg), sys.exc_info()[2]
          )
  
      ax = axes_class(*kl, **kwargs)
  
      divider = make_axes_locatable(ax)
  
      pad_size = Size.Fraction(pad, Size.AxesY(ax))
  
      xsize = Size.Fraction((1.0 - 2.0 * pad) / 3.0, Size.AxesX(ax))
      ysize = Size.Fraction((1.0 - 2.0 * pad) / 3.0, Size.AxesY(ax))
  
      divider.set_horizontal([Size.AxesX(ax), pad_size, xsize])
      divider.set_vertical([ysize, pad_size, ysize, pad_size, ysize])
  
      ax.set_axes_locator(divider.new_locator(0, 0, ny1=-1))
  
      ax_rgb = []
      for ny in [4, 2, 0]:
          ax1 = axes_class(
              ax.get_figure(),
              ax.get_position(original=True),
              sharex=ax,
              sharey=ax,
              **kwargs,
          )
          locator = divider.new_locator(nx=2, ny=ny)
          ax1.set_axes_locator(locator)
          ax1.axis[:].toggle(ticklabels=False)
          ax_rgb.append(ax1)
  
      self.RGB = ax
      self.R, self.G, self.B = ax_rgb
  
      if add_all:
          fig = ax.get_figure()
          fig.add_axes(ax)
          self.add_RGB_to_figure()
  
      self._config_axes()
  
file_path: catboost/contrib/python/matplotlib/py2/mpl_toolkits/axes_grid1/axes_rgb.py
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  import six
  import numpy
  from .axes_divider import make_axes_locatable, Size, locatable_axes_factory
  import sys
  from .mpl_axes import Axes
label_desc: Use image node_id 1 to create a new RGBAxesBase object from inherited base classes: object with example: obj = RGBAxesBase()