Shape recognition algorithms/code for Java
-
22-09-2019 - |
Question
I'm looking for a shape recognition tool for Java. In particular, I'd like to find a Java library that given an image file (in jpeg, bmp, gif or any common image file format) gives me information about the regular shapes (rectangles, lines, ...) found in the picture and their coordinates.
In previous questions on this topic I've seen recommendations for C# but I'm unable to find any implementation in Java.
Hope somebody can help me!
Solution
Have you taken a look at OpenCV? I believe there are Java wrappers for it. What exactly are you trying to accomplish?
OTHER TIPS
if you want to recognise human drawn 2d shapes I would recommend you to look into neural networks more specific, kohonen networks or self organizing maps this network is usually fed a 2d boolean array specifying the user drawn shape marking true
if the pixel is the foreground color and false
if the pixel is a background color. Jeff Heaton has written several books on kohonen networks and has provided a working OCR example recognizing user drawn characters based on a set of predefines samples (shapes) being taught to the network. You can find the source code here and an applet here.
I believe the Encog framework is what you're looking for.