class_docstr: Create and store a set of contour lines or filled regions.
  
  This class is typically not instantiated directly by the user but by
  `~.Axes.contour` and `~.Axes.contourf`.
  
  %(contour_set_attributes)s
class_docstr_tok: ["Create","and","store","a","set","of","contour","lines","or","filled","regions",".","This","class","is","typically","not","instantiated","directly","by","the","user","but","by","`","~.Axes.contour","`","and","`","~.Axes.contourf","`",".","%","(","contour_set_attributes",")","s"]
code: def _contour_args(self, args, kwargs):
      if self.filled:
          fn = "contourf"
      else:
          fn = "contour"
      nargs = len(args)
  
      if 0 < nargs <= 2:
          z, *args = args
          z = ma.asarray(z)
          x, y = self._initialize_x_y(z)
      elif 2 < nargs <= 4:
          x, y, z_orig, *args = args
          x, y, z = self._check_xyz(x, y, z_orig, kwargs)
  
      else:
          raise _api.nargs_error(fn, takes="from 1 to 4", given=nargs)
      z = ma.masked_invalid(z, copy=False)
      self.zmax = z.max().astype(float)
      self.zmin = z.min().astype(float)
      if self.logscale and self.zmin <= 0:
          z = ma.masked_where(z <= 0, z)
          _api.warn_external(
              "Log scale: values of z <= 0 have been masked"
          )
          self.zmin = z.min().astype(float)
      self._process_contour_level_args(args, z.dtype)
      return (x, y, z)
  
imports: from contextlib import ExitStack
  import functools
  import math
  from numbers import Integral
  import numpy
  from numpy import ma
  import matplotlib
  from matplotlib import _api, _docstring
  from matplotlib.backend_bases import MouseButton
  from matplotlib.lines import Line2D
  from matplotlib.path import Path
  from matplotlib.text import Text
  import matplotlib.ticker
  import matplotlib.cm
  import matplotlib.colors
  import matplotlib.collections
  import matplotlib.font_manager
  import matplotlib.cbook
  import matplotlib.patches
  import matplotlib.transforms
label_desc: Use image node_id 2 for calling the QuadContourSet obj's underlying member method code with example usage: obj._contour_args(args, kwargs) and returns: x,  y,  z