Dojo.jl icon indicating copy to clipboard operation
Dojo.jl copied to clipboard

MRP Test sometimes fails with slightly violated tolerance

Open janbruedigam opened this issue 2 years ago • 3 comments

See for example CI#299 (attempt 1). https://github.com/dojo-sim/Dojo.jl/actions/runs/1972726645/attempts/1

janbruedigam avatar Mar 12 '22 08:03 janbruedigam

This test has been problematic before and I often have difficulty replicating it locally. The finite-difference and analytical Jacobians should match more closely. Not sure what the best fix for this is...

thowell avatar Mar 12 '22 19:03 thowell

Maybe a naive question, haven't looked at the tests in detail: Why are we doing finit-diffing and not auto-diffing? Can finite-differences achieve the desired numerical accuracy?

janbruedigam avatar Mar 13 '22 17:03 janbruedigam

I think we started using finite-diff everywhere because it's easier to use than ForwardDiff. Especially when you are dealing with structures or functions that have a fixed element type (say Float64). Forward diff will pass it's own type and the function might break. So this is just for convenience, and I think that most of the tests would work fine with ForwardDiff.

simon-lc avatar Mar 13 '22 18:03 simon-lc