verify()

verify()#

ShiftTransformer.verify(tol: float = 0.0001)#

Verify that transform() and inverse_transform() are consistent and that transform_ddts(), if implemented, is consistent with transform().

  • The transform() / inverse_transform() consistency check verifies that inverse_transform(transform(states)) == states.

  • The transform_ddts() consistency check uses opinf.ddt.ddt() to estimate the time derivatives of the states and the transformed states, then verfies that the relative difference between transform_ddts(opinf.ddt.ddt(states, t)) and opinf.ddt.ddt(transform(states), t) is less than tol, where t = numpy.linspace(0, 0.1, 20).

Parameters:
tolfloat > 0

Tolerance for the finite difference check of transform_ddts(). Only used if transform_ddts() is implemented.