Open jhengyilin opened 8 months ago
New findings......
Is the Jacobain adding a negate sign, i.e. -1.0 because of the reason stating in book ch7.7.3 (page 187) such that the error is defined as "observation - prediction" rather than "prediction - observation".
If the above statement is true, it will self-explained the issue I suppose in the previous comment.
Thanks for any relevant help in advance!
optical_flow.cpp .......
At line 229 and 238, calculate the Jacobian using central difference for derivative and times -1 for the opposite direction of gradient for iterative minimizing is fine to understand.
However, at line 246, bias is computed with b += -error * J; which is weird since already added the negative sign when defining Jacobian.
If we delete the -1 for Jacobian definition, the bias calculation would be correct.
Is it typo or anything I am missing about the math behind all this Gauss-Newton thing?
Thanks in advance for any help!