Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add tests for differentiability #146

Merged
merged 1 commit into from
Nov 7, 2024
Merged

add tests for differentiability #146

merged 1 commit into from
Nov 7, 2024

Conversation

baggepinnen
Copy link
Owner

This PR adds tests to make sure all Kalman filters are differentiable w.r.t.

  • R1
  • R2
  • p in the dynamics

The important thing to ensure that filters are differentiable is to let the initial state distribution d0 have the correct element type, e.g., something like

function costfun1(p::AbstractArray{T}) where T
    d0 = MvNormal(@SVector(zeros(T, nx)), T(1.0))   # Initial state Distribution with correct element type
    # construct filter
    ...
end

@baggepinnen baggepinnen merged commit 56bceab into master Nov 7, 2024
2 checks passed
@baggepinnen baggepinnen deleted the test_diff branch November 7, 2024 06:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant