Skip to content

Commit 491d022

Browse files
VRU example
1 parent 2ff494b commit 491d022

1 file changed

Lines changed: 10 additions & 13 deletions

File tree

docs/user_guide/quickstart.rst

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -256,29 +256,26 @@ The :class:`~smsfusion.FixedIntervalSmoother` implements fixed-interval smoothin
256256
for an :class:`~smsfusion.AidedINS` instance or one of its subclasses (:class:`~smsfusion.AHRS`
257257
or :class:`~smsfusion.VRU`). After a complete forward pass using the AINS algorithm,
258258
the smoother applies a backward pass using the Rauch-Tung-Striebel (RTS) algorithm [1]
259-
to refine the state (and covariance) estimates:
259+
to refine the state (and covariance) estimates.
260+
261+
The following example demonstrates how to use the :class:`~smsfusion.FixedIntervalSmoother`
262+
to refine a VRU's roll and pitch estimates when future measurements are available:
263+
260264

261265
.. code-block:: python
262266
263267
import smsfusion as sf
264268
265-
smoother = sf.FixedIntervalSmoother(ains)
269+
vru_smoother = sf.FixedIntervalSmoother(vru)
266270
267-
for f_i, w_i, p_i, h_i in zip(acc_imu, gyro_imu, pos_aid, head_aid):
268-
smoother.update(
271+
for f_i, w_i in zip(acc_imu, gyro_imu):
272+
vru_smoother.update(
269273
f_i,
270274
w_i,
271-
degrees=False,
272-
pos=p_i,
273-
pos_var=pos_noise_std**2 * np.ones(3),
274-
head=h_i,
275-
head_var=head_noise_std**2,
276-
head_degrees=False,
275+
degrees=False
277276
)
278277
279-
pos_est = smoother.position()
280-
vel_est = smoother.velocity()
281-
euler_est = smoother.euler(degrees=False)
278+
roll_pitch_est = vru_smoother.smooth()[:2] # smoothed roll and pitch estimates
282279
283280
284281
References

0 commit comments

Comments
 (0)