Skip to content

Revert "Generalized sigma-points"#272

Merged
rlabbe merged 1 commit into
masterfrom
revert-247-master
Jun 29, 2022
Merged

Revert "Generalized sigma-points"#272
rlabbe merged 1 commit into
masterfrom
revert-247-master

Conversation

@rlabbe
Copy link
Copy Markdown
Owner

@rlabbe rlabbe commented Jun 29, 2022

Reverts #247

Unit tests are failing.

filterpy/kalman/tests/test_ukf.py::test_generalized_sigma_points_2D_positively_constrained
c:\pcloud\filterpy\filterpy\kalman\sigma_points.py:731: RuntimeWarning: divide by zero encountered in true_divide
self.s[i] = self.k*np.min(self.x/np.sqrt(self.P)[:, i_])


def test_generalized_sigma_points_weights_1D():
    ''' test for Ebeigbe weights (example from paper: III.B)'''

    P, S, K = 0.2, -0.5, 1.3
    sp = GeneralizedSigmaPoints(1, P, S, K)


    Wm, Wc, s = sp.Wm, sp.Wc, sp.s
    assert np.allclose(Wm, Wc, 1e-12)

    ref_w = np.array([0.2, 0.0286, 0.7714])
    ref_s = np.array([0.0, 5.8055, 0.2153])
  assert np.allclose(ref_w, Wm, 1e-4)

E assert False
E + where False = <function allclose at 0x00000234893198B0>(array([0.2 , 0.0286, 0.7714]), array([0.2 , 0.02860932, 0.77139068]), 0.0001)
E + where <function allclose at 0x00000234893198B0> = np.allclose

tests\test_ukf.py:204: AssertionError

@rlabbe rlabbe merged commit 8044b16 into master Jun 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant