code: def pointset_to_polydata_algorithm(inp):
      """Add a filter that casts PointSet to PolyData.
  
      Parameters
      ----------
      inp : pyvista.PointSet
          Input point set to be cast to PolyData.
  
      Returns
      -------
      vtk.vtkAlgorithm
          Filter that casts the input PointSet to PolyData.
      """
      alg = PointSetToPolyDataAlgorithm()
      set_algorithm_input(alg, inp)
      return alg
  
imports: import traceback
  import numpy
  import pyvista
  from pyvista.core.errors import PyVistaPipelineError
  from pyvista.core.utilities.helpers import wrap
  from pyvista.plotting import _vtk
label_desc: Use image node_id 6 for calling a global function with example usage: pointset_to_polydata_algorithm(inp) and returns: alg