This repository has been archived by the owner on Oct 25, 2023. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 30
feat: implement multiple image detection #212
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
khaong
commented
Jan 5, 2021
Performance enhancement - use Mat.at() instead of unnecessary array conversion
…ividual occurrence
KazuCocoa
approved these changes
Jan 6, 2021
Could you please attach a visualized example with multiple matches highlighted? |
feat: Add match_neighbour_threshold as option refactor: make nonzero match loop more succinct
Reply: #212 (comment) I've got a local spec to generate the images |
fix: return all matches visualisation at the top level; multiple is now just an array of occurrences refactor: filterNearMatches to a more elegant reduce function
lib/image-util.js
Outdated
@@ -419,6 +423,8 @@ async function getImagesSimilarity (img1Data, img2Data, options = {}) { | |||
* region is highlighted with a rectangle. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We probably should mention that this is going to have all matches highlighted when multiple
is enabled
mykola-mokhnach
approved these changes
Jan 9, 2021
Thanks @khaong , this was a long journey. Please don't forget to update https://github.com/appium/appium/blob/master/docs/en/writing-running-appium/image-comparison.md after the whole implementation is completed |
Published in 2.50.0 |
Thank you @mykola-mokhnach for your guidance and your patience with me! I have learnt a lot through the process 😃 |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi,
For my appium use case, there may be multiple places on the screen which has the same image and I'd like to find them all.
I am not a javascript dev by trade, so would definitely welcome any comments on this!
Thanks
Alex