Hi,
I am sharing my work on computer vision using logic. I have used jetson nano / orin nano to implement the idea. Thanks for helping me with my forum posts. Please take a look at my github repo called pyrebel and pyrebel-ml. There is a demo program in the repo. Let me know what you think about the project.
This video demonstrates pattern recognition. The program does not use neural nets instead uses an image abstraction technique in which the model is trained using very few datasets. In this case, the model (knowledge base) is trained (learned) using a single image of each alphabets and the program recognizes novel inputs.
When i run the jtop utility i see that the CPU load is around 25 percent and the GPU load is around 40 percent. This is the output of tegrastats at a moment
The GPU is responsible for processing the images and forming abstract representation while CPU is responsible for taking that abstract representation and running the learning and inference routines. The demo program takes on 320x240 pixels camera stream. I am sure you could run the program and test for yourself.
You run python3 pyvision.py --learn <filename.png> or <path/to/learn/> --layer <layers> for learning a symbol/pattern.
For example, python3 pyvision.py --layer 30 --learn images/hand-alphabet/ for learning all alphabets in the hand-alphabet directory.
You run python3 pyvision.py --recognize <filename.png> --layer <layers> for recognizing a single image.
or python3 pyvision.py --recognize 1 --camera 1 --layer <layers> for recognizing the camera stream.
The value of “layers” may be tweaked. It is the depth at the which the abstract representation is formed. I give it 30. It works for example alphabet images.
Hi all,
This is a demo of edge detection achieved using data abstraction.
Run the following commands, git clone https://github.com/ps-nithin/pyrebel cd pyrebel python3 pyvision_edge_detection.py --preprocess <filename>
For eq. python3 pyvision_edge_detection.py --preprocess images/wildlife.jpg
Running the above program will show the edges in the image.
Hi,
There is now a pattern recognition demo. First, you have to update the package by running, pip install pyrebel --upgrade or pip install pyrebel==1.0.2
For eq. running python3 pyrebel_main_learn.py --learn images/letters_standard/ learns all the images in the directory and links the filename with the signatures.
For eq. running python3 pyrebel_main_learn.py --recognize images/letters_ripple/c_ripple.png displays the symbols recognized.
To reset the knowledge base just delete file ‘know_base.pkl’ in the current working directory.
The program expects a single pattern in the input image.
Hi,
This is a demo of forming a 2D sketch from the input image.
Below is a sample input. python3 pyrebel_main_vision.py --input photo.jpg --edge_threshold 5 --bound_threshold 100 --abs_threshold 20
You could tweak the output by changing --edge_threshold and also by changing the value of n(defaults to 20) in pyrebel_main_paint.py. The above output was obtained using --edge_threshold 30 and n=50