• R/O
  • SSH
  • HTTPS

particle-filter: 提交


Commit MetaInfo

修订版31 (tree)
时间2011-01-04 17:38:29
作者linuxchecker

Log Message

fixed location of value checks

更改概述

差异

--- test/test_filter.cc (revision 30)
+++ test/test_filter.cc (revision 31)
@@ -229,18 +229,18 @@
229229 a.set_robserve_density_func(&sin_reversed_observed_density_func);
230230
231231 a.createInitialParticles();
232+ // initial value
233+ for(unsigned int i=0;i<num_particle;++i)
234+ {
235+ // initial values should be zero[currently]
236+ cut_assert_equal_double(0.0, 0.1, a.get_particles()[i][0]);
237+ }
232238 for(unsigned l=0;l<100;++l)
233239 {
234240 a.create_system_noise(0.0, 1.0);
235241
236- // initial value
237242 for(unsigned int i=0;i<num_particle;++i)
238243 {
239- // initial values should be zero[currently]
240- cut_assert_equal_double(0.0, 0.1, a.get_particles()[i][0]);
241- }
242- for(unsigned int i=0;i<num_particle;++i)
243- {
244244 // initial values should be near zero
245245 cut_assert_equal_double(0.0, 10.0, a.get_system_noise()[i][0]);
246246 }
Show on old repository browser