Skip to content

Commit cbe8efa

Browse files
willtebbuttgdalle
andauthored
Update tutorials/docs-10-using-turing-autodiff/index.qmd
Co-authored-by: Guillaume Dalle <[email protected]>
1 parent f6c8a4d commit cbe8efa

File tree

1 file changed

+2
-1
lines changed
  • tutorials/docs-10-using-turing-autodiff

1 file changed

+2
-1
lines changed

tutorials/docs-10-using-turing-autodiff/index.qmd

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ For `ReverseDiff`, pass `adtype=AutoReverseDiff()` to the sampler constructor. A
2424

2525

2626

27-
Cached tapes should only be used if you are absolutely certain that the sequence of operations performed in your code does not change between different executions of your model.
27+
Pre-recorded tapes should only be used if you are absolutely certain that the sequence of operations performed in your code does not change between different executions of your model.
28+
2829
Thus, e.g., in the model definition and all implicitly and explicitly called functions in the model, all loops should be of fixed size, and `if`-statements should consistently execute the same branches.
2930
For instance, `if`-statements with conditions that can be determined at compile time or conditions that depend only on fixed properties of the data will always execute the same branches during sampling (if the data is constant throughout sampling and, e.g., no mini-batching is used).
3031
However, `if`-statements that depend on the model parameters can take different branches during sampling; hence, the compiled tape might be incorrect.

0 commit comments

Comments
 (0)