The main concept behind object detection is to import a particular image or video stream and find any instances of pre-defined objects in the source media. To perform object detection, we can use a variety of deep-learning image processing and annotation tools.
One of the most well-liked technologies for image processing and annotation is TensorFlow. It's a free, open-source software library that Google created for artificial intelligence, image processing, and machine learning.
We'll cover how to use the TensorFlow Node-RED for object identification today. Node-RED is a flow-based programming environment that is simple to use and requires little code.
To learn how to install Node-RED in windows, please go through the article titled:
How to Install Node-RED on Windows? alert-info
Installing Node-RED TensorFlow node:
We will need to install the Node-RED TensorFlow library using the following npm command using the command prompt or terminal.
npm install node-red-contrib-tensorflow
Or, we can install the latest stable library from the manage palette option in Node-RED. For this, go to the MENU - MANAGE PALETTE - INSTALL option, search for node-red-contrib-tensorflow and click the install button.
Installing Node-RED TensorFlow Library Node |
TensorFlow Models:
These four pre-trained model library nodes comes with the TensorFlow js node.
- Object Detection (cocossd) -- The node to identify objects in an image
- MediaPipe Handpose -- The node to detect fingers in a hand
- MobileNet -- The node to classify images with MobileNet
- PoseNet Model -- The node to estimate human pose
Our main objective is to explore the Object Detection node.
Let's plot the flow and start image processing using Node-RED and TensorFlow.
We are going to need one more flow to import the test pictures. The node is called the file inject node. To install, run the following command or search for the node-red-contrib-browser-utils node from the manage palette option.
npm install node-red-contrib-browser-utils
The example flow:
Image processing output:
By importing the subject image by using the browser utils node to the flow, the cocossd Node-RED TensorFlow node will process the image and output the result in msg.payload. Using the debug node, we can print the output in the debug message area.
Node-RED TensorFlow node output result |
Post a Comment