splinepy.utils.data.SplineDataAdaptor#

class splinepy.utils.data.SplineDataAdaptor(data, locations=None, function=None, parametric_bounds=None)[source]#

Bases: SplinepyBase

Prepares data to be presentable on spline. To support both scalar-data and vector-data, which are representable with colors and arrows respectively, this class will prepare data accordingly.

Parameters:
  • data (any) – Any data that you want to plot on to the spline. If this is not a spline, it requires a function that takes this data to create appropriate values.

  • locations (2D array-like) – Optional. If specified, used to evaluate data at specific locations. Applicable for arrow data

  • function (callable) – Optional. A callable used to evaluate values using data at query points. function(data, queries) -> values

  • parametric_bounds (2D array-like) – Optional. Parametric bounds of supporting spline. Required for stand-alone use. Otherwise, set by helping spline. Used to compute query points for resolution based sampling.

Methods

Attributes