class ngraph::runtime::reference::InterpolateEvalHelper

Helper class to implent non-template parts of the interpolation calculation.

#include <interpolate.hpp>

class InterpolateEvalHelper
{
public:
    // structs

    struct ICoords;
    struct InfoForGenericLinearONNXMode;
    struct InfoForLinearMode;
    struct LinearModeInnerIterationResult;

    // construction

    InterpolateEvalHelper();

    InterpolateEvalHelper(
        const op::v4::Interpolate::InterpolateAttrs& attrs,
        const Shape& input_data_shape,
        const std::vector<int64_t>& axes,
        const Shape& out_shape,
        const std::vector<float>& scales
        );

    // methods

    float triangle_coeff(float dz);
    std::array<float, 4> get_cubic_coeff(float s, float a);
    float get_in_coord(float coord, int64_t axis_idx);
    Coordinate get_input_coords_for_nearest_mode(const Coordinate& output_coord);
    InfoForGenericLinearONNXMode get_info_for_generic_linear_onnx();
    InfoForLinearMode get_info_for_linear_mode();
    ICoords get_icoords(const Coordinate& output_coord);

    LinearModeInnerIterationResult inner_calculation(
        const Coordinate& output_coord,
        const ICoords& icoords_data,
        const InfoForLinearMode& info,
        const Coordinate& index
        );
};