findAll() makes 10 attempts before giving up?
I've noticed that when using findAll(), it appears to make multiple attempts (ten to be exact) to find an object before giving up. I'm basing the off of this pair of messages that I see popping up when findAll() is invoked:
[profile] Finder.findAll START
[profile] Finder.findAll END: 23ms
When the image is *not* present inside of the region, that pair of messages repeats 10 times (and time is wasted as it apparently keeps trying in vain to find something that isn't there) Whenever the image *is* present, it only appears to make one attempt before it successfully returns the match object. My script is working fine, but it's significantly slower since I'm performing a bunch of these findAll() operations on images that may or may not be present.
Is this intended behavior? If so, why? Can I make it give up after the first attempt?
The code looks something like this:
for filename in somelist:
go_on = False
try:
bqr = Pattern(filename)
bqr = bqr.similar(0.95)
checkzone.
bMatch = checkzone.
go_on = True
except FindFailed:
pass
if go_on == True:
#do more stuff
Thanks!
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: