darrenlafreniere / lafarren-image-completer

Implementation of the research titled: "Image Completion Using Efficient Belief Propagation via Priority Scheduling and Dynamic Pruning"
http://www.lafarren.com/image-completer/
GNU General Public License v3.0
32 stars 18 forks source link

Check for no valid source patches #60

Open daviddoria opened 13 years ago

daviddoria commented 13 years ago

If the mask is such that there are no source patches with all of their pixels known, currently

PriorityBpRunner.cpp(136): assert "node" failed in ForwardPass().

is produced, but it should be something more like

"There are no completely known source patches."

daviddoria commented 13 years ago

This may be a case where we allow source patches to have some unknown points? This might be the PolicyMaskB? Where we check both patches' pixel to see if either is unknown before comparing them. It would be slower (but only if this is the case) but would allow the algorithm to continue on even such an input.