Another way to do something similar might be to use Artificial Intelligence.
You might use something like shown in the tutorial mentioned here> PICaboo app draft . This is not what you suggest but a different way to determine what an object or thing is from an image.
The aix can help determine if the image you provide is one of several different objects. ![]()
Good luck with your project.
.