A simple CNN be able to recognize numbers from 1 to 5 do with hand pose developed in Java.
The overall accuracy is over 99%.
The image is preprocessed using the Canny algorithm, in order to extract only the edge of the image.
See Result for more information about the model used.