patch from bug report #84: encoder bug for affine 6-parameter search

Patch provided by: Yuwen He
Status Job ID Name Coverage
  External
passed jenkins