diff --git a/timing/timeLago.cpp b/timing/timeLago.cpp index 7aaf37e924..c3ee6ff4bc 100644 --- a/timing/timeLago.cpp +++ b/timing/timeLago.cpp @@ -41,11 +41,11 @@ int main(int argc, char *argv[]) { // add noise to create initial estimate Values initial; - Sampler sampler(42u); Values::ConstFiltered poses = solution->filter(); SharedDiagonal noise = noiseModel::Diagonal::Sigmas((Vector(3) << 0.5, 0.5, 15.0 * M_PI / 180.0).finished()); + Sampler sampler(noise); for(const Values::ConstFiltered::KeyValuePair& it: poses) - initial.insert(it.key, it.value.retract(sampler.sampleNewModel(noise))); + initial.insert(it.key, it.value.retract(sampler.sample())); // Add prior on the pose having index (key) = 0 noiseModel::Diagonal::shared_ptr priorModel = //