Opencv4nodejs: template matching example

Created on 5 Jan 2018  路  5Comments  路  Source: justadudewhohacks/opencv4nodejs

Hey,
this looks really cool. Does template matching work? :)

All 5 comments

Hey,
yes matchTemplate is implemented: https://opencv4nodejs.herokuapp.com/docs/core#Mat-matchTemplate.

This looks awesome. I am gonna definitely try it out this weekend and maybe create a pull request with working javascript example.

And is performance improved? I have a project with template matching and haar object detection. I use the haar detection on web camera. (https://github.com/peterbraden/node-opencv) Is it possible to choose whether to use cpu/gpu when using template matching/haar cascade detection? :)

What do you mean by performance improved? You can expect the same performance as with the C++ or Python library. Furthermore you can use the async API and run multiple threads if you need to.

So far I have only added a ocl GPU version of detectMultiScale. In general if you want more GPU bindings you can add them or I can add them for you.

However I will only add the OpenCV GPU functions working with OpenCL as I do not have access to a NVIDIA GPU in order to implement functions from the CUDA API. If you do, you can of course add CUDA bindings if you want.

@justadudewhohacks I just created #138 this library looks awesome. :)

I feel like template matching has changed a lot. I was always using "opencv": "5.0.0", because matchTemplate method in that version returns an array of coordinates, not the black and white matrice.

When finding waldo I had to use method 5. I guess I was a little bit confused because I don't how the template matching actually works in opencv.

Awesome, thanks! It is always good to have more examples.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

je3f0o picture je3f0o  路  6Comments

developer239 picture developer239  路  5Comments

goulash1971 picture goulash1971  路  7Comments

seanquijote picture seanquijote  路  6Comments

asishap007 picture asishap007  路  6Comments