def test_sqrt_cov_update_with_nans(self): kf.sqrt_linear_update( self.states, self.mcovs, self.like_vec, self.y, self.c, self.delta, self.h, self.sqrt_r, self.positions, self.weights) cholcovs = self.mcovs[:, :, 1:, 1:] make_unique(cholcovs.reshape(12, 3, 3)) aaae(cholcovs, self.exp_cholcovs)
def test_sqrt_cov_update_with_nans(self): kf.sqrt_linear_update(self.states, self.mcovs, self.like_vec, self.y, self.c, self.delta, self.h, self.sqrt_r, self.positions, self.weights) cholcovs = self.mcovs[:, :, 1:, 1:] make_unique(cholcovs.reshape(12, 3, 3)) aaae(cholcovs, self.exp_cholcovs)
def update(square_root_filters, update_args): """Select and call the correct update function. The actual update functions are implemented in several modules in :ref:`fast_routines` """ if square_root_filters is True: sqrt_linear_update(*update_args) else: normal_linear_update(*update_args)
def test_sqrt_weight_update_with_nans(setup_linear_update, expected_linear_update): d = setup_linear_update kf.sqrt_linear_update( d["state"], d["mcovs"], d["like_vector"], d["y"], d["c"], d["delta"], d["h"], d["sqrt_r"], d["positions"], d["weights"], ) aaae(d["weights"], expected_linear_update["expected_weights"])
def update(square_root_filters, update_type, update_args): """Select and call the correct update function. The actual update functions are implemented in several modules in :ref:`fast_routines` """ if square_root_filters is True: if update_type == 'linear': sqrt_linear_update(*update_args) else: sqrt_probit_update(**update_args) else: if update_type == 'linear': normal_linear_update(*update_args) else: normal_probit_update(**update_args)
def test_sqrt_cov_update_with_nans(setup_linear_update, expected_linear_update): d = setup_linear_update kf.sqrt_linear_update( d["state"], d["mcovs"], d["like_vector"], d["y"], d["c"], d["delta"], d["h"], d["sqrt_r"], d["positions"], d["weights"], ) modified_mcovs = d["cholcovs"] make_unique(modified_mcovs.reshape(12, 3, 3)) aaae(modified_mcovs, expected_linear_update["exp_cholcovs"])
def test_sqrt_weight_update_with_nans(self): kf.sqrt_linear_update( self.states, self.mcovs, self.like_vec, self.y, self.c, self.delta, self.h, self.sqrt_r, self.positions, self.weights) aaae(self.weights, self.exp_weights)
def test_sqrt_weight_update_with_nans(self): kf.sqrt_linear_update(self.states, self.mcovs, self.like_vec, self.y, self.c, self.delta, self.h, self.sqrt_r, self.positions, self.weights) aaae(self.weights, self.exp_weights)