def test_smoother_ref_traj3_2(): """ test_smoother_ref_traj3_1 . Just check if it can be computed and does not trigger underflow warnings. """ traj = simple_traj3() theta = np.array([-1.0, 1.0]) smoother_1 = TrajectorySmootherRef(traj, theta) smoother_1.computeProbs()
def test_smoother_ref_traj6_1(): """ test_smoother_ref_traj6_1 """ traj = simple_traj6() theta = np.array([-1.0, 1.0]) smoother_ref = TrajectorySmootherRef(traj, theta) smoother_ref.computeProbs() smoother_1 = TrajectorySmoother1(traj, theta) smoother_1.computeProbs() check_probs(smoother_1, smoother_ref)
def test_smoother_ref_traj3_2(): """ test_smoother_ref_traj3_1 . Just check if it can be computed and does not trigger underflow warnings. """ traj = simple_traj3() theta = np.array([-1.0, 1.0]) smoother_1 = TrajectorySmootherRef(traj, theta) smoother_1.computeProbs()
def test_smoother_ref_traj6_1(): """ test_smoother_ref_traj6_1 """ traj = simple_traj6() theta = np.array([-1.0, 1.0]) smoother_ref = TrajectorySmootherRef(traj, theta) smoother_ref.computeProbs() smoother_1 = TrajectorySmoother1(traj, theta) smoother_1.computeProbs() check_probs(smoother_1, smoother_ref)
def test_filter_ref_2(): """ test_filter_ref_2 """ traj = simple_traj2() theta = np.array([1.0, -1.0]) filter_0 = TrajectoryFilterRef(traj, theta, 0) filter_0.computeProbs() # The forward probabilities should equal the probabilities check_prob_fields(filter_0.forward, filter_0.probabilities) # Run the filter in inneficient smooting mode filter_L = TrajectoryFilterRef(traj, theta, traj.L) filter_L.computeProbs() smoother = TrajectorySmootherRef(traj, theta) smoother.computeProbs() check_prob_fields(filter_L.forward, smoother.forward) check_prob_fields(filter_L.backward, smoother.backward) check_prob_fields(filter_L.probabilities, smoother.probabilities)
def test_filter_ref_2(): """ test_filter_ref_2 """ traj = simple_traj2() theta = np.array([1.0, -1.0]) filter_0 = TrajectoryFilterRef(traj, theta, 0) filter_0.computeProbs() # The forward probabilities should equal the probabilities check_prob_fields(filter_0.forward, filter_0.probabilities) # Run the filter in inneficient smooting mode filter_L = TrajectoryFilterRef(traj, theta, traj.L) filter_L.computeProbs() smoother = TrajectorySmootherRef(traj, theta) smoother.computeProbs() check_prob_fields(filter_L.forward, smoother.forward) check_prob_fields(filter_L.backward, smoother.backward) check_prob_fields(filter_L.probabilities, smoother.probabilities)