You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current implementation of the loop's body in the reverse pass of the Reverse mode is not very clear. Consider this example:
doublefn(double u, double v) {
double res = 11 * u;
for (int i = 0; i < 3; i++) {
if (i==2){
res += u * i;
continue;
}
else {
res -= u * i;
}
res += u;
}
return res;
}
The for loop in the reverse pass, after the fix of #710, is derived like so:
The current implementation of the loop's body in the reverse pass of the Reverse mode is not very clear. Consider this example:
The for loop in the reverse pass, after the fix of #710, is derived like so:
Even though the results are correct and the cases handled as expected, the indexing of the code is not very traditional.
The proposed change evaluates this snippet as:
The text was updated successfully, but these errors were encountered: