DynamicHMC does not deal well with incorrect deriatives. These can result from AD errors (conceptual errors in mature AD libraries are rare, but numerical corner cases can still happen), or bugs in manually coded derivatives.
There should be functionality to test for these things. Ideally independently of AD, eg with finite differences, possibly using Richardson extrapolation (is there a package for that?).
Decisions to make: should this be part of stresstest, or something else?
DynamicHMC does not deal well with incorrect deriatives. These can result from AD errors (conceptual errors in mature AD libraries are rare, but numerical corner cases can still happen), or bugs in manually coded derivatives.
There should be functionality to test for these things. Ideally independently of AD, eg with finite differences, possibly using Richardson extrapolation (is there a package for that?).
Decisions to make: should this be part of
stresstest, or something else?