Trait Interp2DStrategyBuilder

Source
pub trait Interp2DStrategyBuilder<Sd, Sx, Sy, D>
where Sd: Data, Sd::Elem: Num + PartialOrd + NumCast + Copy + Debug + Sub + Send, Sx: Data<Elem = Sd::Elem>, Sy: Data<Elem = Sd::Elem>, D: Dimension + RemoveAxis, D::Smaller: RemoveAxis,
{ type FinishedStrat: Interp2DStrategy<Sd, Sx, Sy, D>; const MINIMUM_DATA_LENGHT: usize; // Required method fn build( self, x: &ArrayBase<Sx, Ix1>, y: &ArrayBase<Sy, Ix1>, data: &ArrayBase<Sd, D>, ) -> Result<Self::FinishedStrat, BuilderError>; }

Required Associated Constants§

Required Associated Types§

Required Methods§

Source

fn build( self, x: &ArrayBase<Sx, Ix1>, y: &ArrayBase<Sy, Ix1>, data: &ArrayBase<Sd, D>, ) -> Result<Self::FinishedStrat, BuilderError>

initialize the strategy by validating data and possibly calculating coefficients This method is called in Interp2DBuilder::build

When this method is called by Interp2DBuilder the following properties are guaranteed:

  • x and y is strictly monotonically rising
  • the lenght of x equals the lenght of the data Axis 0
  • the lenght of y equals the lenght of the data Axis 1
  • the lenght is at least MINIMUM_DATA_LENGHT
  • Interpolation in x will happen along Axis 0
  • Interpolation in y will happen along Axis 1

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<Sd, Sx, Sy, D> Interp2DStrategyBuilder<Sd, Sx, Sy, D> for Bilinear
where Sd: Data, Sd::Elem: Num + PartialOrd + NumCast + Copy + Debug + Sub + Send, Sx: Data<Elem = Sd::Elem>, Sy: Data<Elem = Sd::Elem>, D: Dimension + RemoveAxis, D::Smaller: RemoveAxis,