Refactor PP5 comparison handling

Introduce PP5GalleryTransform, a transform that compares incoming templates
against a fixed gallery (thereby avoiding the cost of repeatedly setting up
pp5 galleries for the same templates).

Modify AlgorithmCore to support supplying Transforms to the right of the
: in an algorithm string. If a distance cannot be created (testing if
defaultDistance is returned from Distance::make), store the comparison
part as a string, and use it to make a replacement for GalleryCompareTransfrom
in calls to AlgorithmCore::compare

This commit essentially disables DefaultDistance (which could previously
be used as a shorthand for DistDistance with some specific metric),
instead leaving DefaultDistance as a non-functional distance.
Specifically what do you mean? Default distance does something similar to
what it does now, but creates a transform instead of a DistDistance? And
then we would retrieve the transform I guess?

One issue (that will be addressed fairly soon) is that we have to set the
specific gallery we are using when building the transform, but if in the
future it is possible to set properties in memory then that would no longer
be an issue.


On Thu, Jul 3, 2014 at 8:30 AM, Josh Klontz <notifications@github.com>
wrote:

> In openbr/plugins/distance.cpp:
>
> > @@ -135,7 +135,7 @@ class DefaultDistance : public Distance
> >
> >      void init()
> >      {
> > -        distance = Distance::make("Dist("+file.suffix()+")");
> > +     //   distance = Distance::make("Dist("+file.suffix()+")");
>
> Can the galleryCompareString/compareRegionDesc logic be moved into
> DefaultDistance? In other words, DefaultDistance is a transform-based
> distance?
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/biometrics/openbr/pull/213/files#r14510627>.
>