[ADOL-C] Branch switch when using same inputs as taping
noam.gat at mail.huji.ac.il
Mon Jun 20 08:35:32 EDT 2011
I have a strange problem when using adol-c to create a gradient.
Before I try to prevent re-taping, I am currently retaping before each
The general structure of the code is :
for (int i=0; i<N; i++)
rawGradParams[i] <<= X[i];
adouble result = objective(rawGradParams);
result >>= retVal;
int gradientRetVal = gradient(0,N,X,G);
And I get -1 as the retVal, with the error being
"ADOL-C Warning: Branch switch detected in comparison "
"Forward sweep aborted! Retaping
Seeing as retaping won't do anything, I don't know how to attack this
The code of the objective function is rather long and sadly I can't post it.
Does anyone have any general ideas on how to attack this problem?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the ADOL-C