[Enhancement] Find All possible matches from an list of input images

Asked by Chetan

problem:
currently we use findbest to find the best match from a list of input images. however sometimes we need to find all matches as the best match image is not the image we need. for this there is no method where we pass a list of images to findALL and it returns all the matches from each of the input image

alternatively we use loop in findalllist where we feed it with one image at a time

  for imgall in imagelistwithMatchpercent:
            closestImagesfindAll=[]
            closestImagesfindAll=regiontoSearch.findAllList(imgall)

enhancement
it would be helpful we we can pass all the images to findAllList in one go

Question information

Language:
English Edit question
Status:
Solved
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Solved by:
RaiMan
Solved:
Last query:
Last reply:
Revision history for this message
Best RaiMan (raimund-hocke) said :
#1

I understand your request.

But if you pack such an implementation into a function (def) and put it into your global module, then you are there.

findAll principally is the same as find, but in case returns all matches with an appropriate score instead of only that with the highest score.

An enhancement IMHO for your situation would be to internally run the find ops for each target in parallel (as for findAny) instead of sequentially, which takes longer in average and uses a new shot for every sequential findAll (your workaround).

So I accept your request as an enhancement for findAny, so that for each given target a list of all found matches (as with findAllList) is returned.

Revision history for this message
Chetan (cshamdas) said :
#2

Thanks RaiMan, that solved my question.

Revision history for this message
Chetan (cshamdas) said :
#3

thanks Raiman for your inputs. yes we are already using it as a def function.
can you please share us the expected build and if possible link to track this