class_docstr: Define basic tools for triangular mesh analysis and improvement.
  
  A TriAnalyzer encapsulates a `.Triangulation` object and provides basic
  tools for mesh analysis and mesh improvement.
  
  Attributes
  ----------
  scale_factors
  
  Parameters
  ----------
  triangulation : `~matplotlib.tri.Triangulation`
      The encapsulated triangulation to analyze.
docstr: Factors to rescale the triangulation into a unit square.
  
  Returns
  -------
  (float, float)
      Scaling factors (kx, ky) so that the triangulation
      ``[triangulation.x * kx, triangulation.y * ky]``
      fits exactly inside a unit square.
code: def scale_factors(self):
      """
      Factors to rescale the triangulation into a unit square.
  
      Returns
      -------
      (float, float)
          Scaling factors (kx, ky) so that the triangulation
          ``[triangulation.x * kx, triangulation.y * ky]``
          fits exactly inside a unit square.
      """
      compressed_triangles = self._triangulation.get_masked_triangles()
      node_used = (
          np.bincount(
              np.ravel(compressed_triangles),
              minlength=self._triangulation.x.size,
          )
          != 0
      )
      return (
          1 / np.ptp(self._triangulation.x[node_used]),
          1 / np.ptp(self._triangulation.y[node_used]),
      )
  
file_path: catboost/contrib/python/matplotlib/py3/matplotlib/tri/_tritools.py
imports: import numpy
  from matplotlib import _api
  from matplotlib.tri import Triangulation
label_desc: Use image node_id 2 for calling the TriAnalyzer obj's underlying member method code with example usage: obj.scale_factors() and returns: unknown,  unknown