nimbleEcology
nimbleEcology copied to clipboard
warning in AD-enabled nimbleEcology
We'll need to address this warning that arises for dCJS
:
[Note] Detected use of function(s) that are not supported for derivative tracking in a function or method for which `buildDerivs` has been requested: is.na.
@perrydv @danielturek @dochvam Looks like this was overlooked in nimbleEcology 0.5.0.
This comes from dCJS
, and I presume it means it won't work with AD.
Ok, so dCJS
works fine with AD (I tried HMC on the dCJS_vs
example). is.na
is run on a variable that is the output of ADbreak
.
So this is really a nimble question in terms of the warning we emit about non-AD enabled function in DSL code. I'll make an issue in nimble-dev/nimble
.
Actually I will leave this open as one path forward here (if we leave the AD checking) is to set up a nimble option that turns off the checking and temporarily invoke that before the dCJS
functions are given in dCJS.R
so that when the file is sourced, the warning is not emitted.
Turns out we already had an option in nimble
to turn this off (doADerrorTraps
), so I just toggled that off/on in various places in the R files and committed to master
.