Multi-Template Matching for object-localisation in Fiji

fiji
knime
jython
opencv
acquifer
ij-opencv
#1

I am glad to announce the release of our Fiji plugin for object-localisation using multiple template matching.

Installation

Enable the following update sites: Multi-Template-Matching and IJ-OpenCV

Documentation

You can find extensive documentation on the GitHub repository.

Video tutorials

Check our serie of video tutorials on youtube :wink:

Datasets

We also uploaded some test datasets on Zenodo :wink:
Medaka embryos: 10.5281/zenodo.2650146
Zebrafish larvae : 10.5281/zenodo.2650161.

In KNIME

We also have an equivalent KNIME implementation

Acknowlegements

Thanks to @imagejan, @ctrueden, @Wayne, @gab1one @stelfrich for supporting this project by answering the forum(s) !

9 Likes
Template Matching plugin issues
Template matching plugin
#2

Can this be scripted in Fiji?

#3

Yes it is! Check video 3 for the macro recording :wink:

1 Like
#4

And Python is also possible?

#5

Thanks @LThomas, this is amazing!

In testing, matching a single object in each slice of a stack to the template seems to work very very well. Using the attached stack and template, I was able to detect many vesicles throughout mystack using vert/horiz flip and 90,180,270 rotation as demonstrated in the preprint.

Multiple matching seems to fail. Any number over 1 in expected objects results in no objects being found, using the same settings as above. Any advice on why this might be happening? This is all using the plugin freshly installed from the update site this morning.

Thanks for this awesome work!

Stack.tif (13.0 MB)
Template.tif (1.1 KB)

#6

Every command that is macro-recordable can also be called from Jython. Just use the macro recorder in Javascript or Beanshell mode to get the required command (in Python you can omit the semicolons at the end, of course).

In essence, it’s usually just IJ.run() instead of run().

1 Like
#7

Hi I am glad that you found it useful :wink:
Can you check the version of imagej you are using.
There was a bug in imageJ1.52n that lead to such issue. Updating to 1.52o or daily build fixes the bug.
Help>Update ImageJ

1 Like
#8

That was it! Thanks again for such a great tool!