class_docstr: An internal class to manage filters/algorithms for polydata datasets.
class_docstr_tok: ["An","internal","class","to","manage","filters\/algorithms","for","polydata","datasets","."]
docstr: Adjust point coordinates using Laplacian smoothing.
  
  The effect is to "relax" the mesh, making the cells better shaped and
  the vertices more evenly distributed.
  
  Parameters
  ----------
  n_iter : int, default: 20
      Number of iterations for Laplacian smoothing.
  
  relaxation_factor : float, default: 0.01
      Relaxation factor controls the amount of displacement in a single
      iteration. Generally a lower relaxation factor and higher number of
      iterations is numerically more stable.
  
  convergence : float, default: 0.0
      Convergence criterion for the iteration process. Smaller numbers
      result in more smoothing iterations. Range from (0 to 1).
  
  edge_angle : float, default: 15
      Edge angle to control smoothing along edges (either interior or boundary).
  
  feature_angle : float, default: 45
      Feature angle for sharp edge identification.
  
  boundary_smoothing : bool, default: True
      Flag to control smoothing of boundary edges. When ``True``,
      boundary edges remain fixed.
  
  feature_smoothing : bool, default: False
      Flag to control smoothing of feature edges.  When ``True``,
      boundary edges remain fixed as defined by ``feature_angle`` and
      ``edge_angle``.
  
  inplace : bool, default: False
      Updates mesh in-place.
  
  progress_bar : bool, default: False
      Display a progress bar to indicate progress.
  
  Returns
  -------
  pyvista.PolyData
      Smoothed mesh.
  
  Examples
  --------
  Smooth the edges of an all triangular cube
  
  >>> import pyvista as pv
  >>> cube = pv.Cube().triangulate().subdivide(5)
  >>> smooth_cube = cube.smooth(1000, feature_smoothing=False)
  >>> n_edge_cells = cube.extract_feature_edges().n_cells
  >>> n_smooth_cells = smooth_cube.extract_feature_edges().n_cells
  >>> f'Sharp Edges on Cube:        {n_edge_cells}'
  'Sharp Edges on Cube:        384'
  >>> f'Sharp Edges on Smooth Cube: {n_smooth_cells}'
  'Sharp Edges on Smooth Cube: 12'
  >>> smooth_cube.plot()
  
  See :ref:`surface_smoothing_example` for more examples using this filter.
docstr_tok: ["Adjust","point","coordinates","using","Laplacian","smoothing",".","The","effect","is","to","``","relax","''","the","mesh",",","making","the","cells","better","shaped","and","the","vertices","more","evenly","distributed",".","Parameters","--","--","--","--","--","n_iter",":","int",",","default",":","20","Number","of","iterations","for","Laplacian","smoothing",".","relaxation_factor",":","float",",","default",":","0.01","Relaxation","factor","controls","the","amount","of","displacement","in","a","single","iteration",".","Generally","a","lower","relaxation","factor","and","higher","number","of","iterations","is","numerically","more","stable",".","convergence",":","float",",","default",":","0.0","Convergence","criterion","for","the","iteration","process",".","Smaller","numbers","result","in","more","smoothing","iterations",".","Range","from","(","0","to","1",")",".","edge_angle",":","float",",","default",":","15","Edge","angle","to","control","smoothing","along","edges","(","either","interior","or","boundary",")",".","feature_angle",":","float",",","default",":","45","Feature","angle","for","sharp","edge","identification",".","boundary_smoothing",":","bool",",","default",":","True","Flag","to","control","smoothing","of","boundary","edges",".","When","``","True","``",",","boundary","edges","remain","fixed",".","feature_smoothing",":","bool",",","default",":","False","Flag","to","control","smoothing","of","feature","edges",".","When","``","True","``",",","boundary","edges","remain","fixed","as","defined","by","``","feature_angle","``","and","``","edge_angle","``",".","inplace",":","bool",",","default",":","False","Updates","mesh","in-place",".","progress_bar",":","bool",",","default",":","False","Display","a","progress","bar","to","indicate","progress",".","Returns","--","--","--","-","pyvista.PolyData","Smoothed","mesh",".","Examples","--","--","--","--","Smooth","the","edges","of","an","all","triangular","cube",">",">",">","import","pyvista","as","pv",">",">",">","cube","=","pv.Cube","(",")",".triangulate","(",")",".subdivide","(","5",")",">",">",">","smooth_cube","=","cube.smooth","(","1000",",","feature_smoothing=False",")",">",">",">","n_edge_cells","=","cube.extract_feature_edges","(",")",".n_cells",">",">",">","n_smooth_cells","=","smooth_cube.extract_feature_edges","(",")",".n_cells",">",">",">","f'Sharp","Edges","on","Cube",":","{","n_edge_cells","}","'","'Sharp","Edges","on","Cube",":","384'",">",">",">","f'Sharp","Edges","on","Smooth","Cube",":","{","n_smooth_cells","}","'","'Sharp","Edges","on","Smooth","Cube",":","12'",">",">",">","smooth_cube.plot","(",")","See",":","ref",":","`","surface_smoothing_example","`","for","more","examples","using","this","filter","."]
code: def smooth(
      self,
      n_iter=20,
      relaxation_factor=0.01,
      convergence=0.0,
      edge_angle=15,
      feature_angle=45,
      boundary_smoothing=True,
      feature_smoothing=False,
      inplace=False,
      progress_bar=False,
  ):
      """Adjust point coordinates using Laplacian smoothing.
  
      The effect is to "relax" the mesh, making the cells better shaped and
      the vertices more evenly distributed.
  
      Parameters
      ----------
      n_iter : int, default: 20
          Number of iterations for Laplacian smoothing.
  
      relaxation_factor : float, default: 0.01
          Relaxation factor controls the amount of displacement in a single
          iteration. Generally a lower relaxation factor and higher number of
          iterations is numerically more stable.
  
      convergence : float, default: 0.0
          Convergence criterion for the iteration process. Smaller numbers
          result in more smoothing iterations. Range from (0 to 1).
  
      edge_angle : float, default: 15
          Edge angle to control smoothing along edges (either interior or boundary).
  
      feature_angle : float, default: 45
          Feature angle for sharp edge identification.
  
      boundary_smoothing : bool, default: True
          Flag to control smoothing of boundary edges. When ``True``,
          boundary edges remain fixed.
  
      feature_smoothing : bool, default: False
          Flag to control smoothing of feature edges.  When ``True``,
          boundary edges remain fixed as defined by ``feature_angle`` and
          ``edge_angle``.
  
      inplace : bool, default: False
          Updates mesh in-place.
  
      progress_bar : bool, default: False
          Display a progress bar to indicate progress.
  
      Returns
      -------
      pyvista.PolyData
          Smoothed mesh.
  
      Examples
      --------
      Smooth the edges of an all triangular cube
  
      >>> import pyvista as pv
      >>> cube = pv.Cube().triangulate().subdivide(5)
      >>> smooth_cube = cube.smooth(1000, feature_smoothing=False)
      >>> n_edge_cells = cube.extract_feature_edges().n_cells
      >>> n_smooth_cells = smooth_cube.extract_feature_edges().n_cells
      >>> f'Sharp Edges on Cube:        {n_edge_cells}'
      'Sharp Edges on Cube:        384'
      >>> f'Sharp Edges on Smooth Cube: {n_smooth_cells}'
      'Sharp Edges on Smooth Cube: 12'
      >>> smooth_cube.plot()
  
      See :ref:`surface_smoothing_example` for more examples using this filter.
  
      """
      alg = _vtk.vtkSmoothPolyDataFilter()
      alg.SetInputData(self)
      alg.SetNumberOfIterations(n_iter)
      alg.SetConvergence(convergence)
      alg.SetFeatureEdgeSmoothing(feature_smoothing)
      alg.SetFeatureAngle(feature_angle)
      alg.SetEdgeAngle(edge_angle)
      alg.SetBoundarySmoothing(boundary_smoothing)
      alg.SetRelaxationFactor(relaxation_factor)
      _update_alg(alg, progress_bar, "Smoothing Mesh")
  
      mesh = _get_output(alg)
      if inplace:
          self.copy_from(mesh, deep=False)
          return self
      return mesh
  
imports: import collections.abc
  import warnings
  import numpy
  import pyvista
  from pyvista.core import _vtk_core
  from pyvista.core.errors import MissingDataError, NotAllTrianglesError, PyVistaFutureWarning, VTKVersionError
  from pyvista.core.filters import _get_output, _update_alg
  from pyvista.core.filters.data_set import DataSetFilters
  from pyvista.core.utilities.arrays import FieldAssociation, get_array, get_array_association, set_default_active_scalars, vtk_id_list_to_array
  from pyvista.core.utilities.geometric_objects import NORMALS
  from pyvista.core.utilities.helpers import generate_plane, wrap
  from pyvista.core.utilities.misc import abstract_class, assert_empty_kwargs
label_desc: Use image node_id 14 for calling the PolyDataFilters obj's underlying member method code with example usage: obj.smooth(n_iter, relaxation_factor, convergence, edge_angle, feature_angle, boundary_smoothing, feature_smoothing, inplace, progress_bar) and returns: mesh, self