Updated Blocks Sample TensorFlow Object Detection Op Mode (markdown)
@ -41,9 +41,9 @@ In this example, the Op Mode activates the TensorFlow object detector before wai
|
|||||||
<p align="center">[[/images/Blocks-Sample-TensorFlow-Object-Detection-Op-Mode/blocksTensorFlowActivate.png]]<br/>Activate TensorFlow.<p>
|
<p align="center">[[/images/Blocks-Sample-TensorFlow-Object-Detection-Op-Mode/blocksTensorFlowActivate.png]]<br/>Activate TensorFlow.<p>
|
||||||
|
|
||||||
### Setting the Zoom Factor
|
### Setting the Zoom Factor
|
||||||
When TensorFlow receives an image from the robot's camera, the library downgrades the resolution of the image (presumably to achieve a higher detection rate). As a result, if a target is at a distance of around 24" (61cm) or more, the detection accuracy of the system tends to diminish, in spite of the accuracy of your inference model. You can specify a zoom factor in your op mode to offset the effect of this automatic scaling by the TensorFlow library.
|
When TensorFlow receives an image from the robot's camera, the library downgrades the resolution of the image (presumably to achieve a higher detection rate). As a result, if a target is at a distance of around 24" (61cm) or more, the detection accuracy of the system tends to diminish. This degradation in detection accuracy can occur, even if your inference model is very accurate.
|
||||||
|
|
||||||
If you specify a zoom factor, the image will be cropped by this factor and the artificially magnified image will be passed to the TensorFlow library. The net result is that the robot should be able to detect and track an object at a significantly larger distance.
|
You can specify a zoom factor in your op mode to offset the effect of this automatic scaling by the TensorFlow library. If you specify a zoom factor, the image will be cropped by this factor and this artificially magnified image will be passed to the TensorFlow library. The net result is that the robot should be able to detect and track an object at a significantly larger distance.
|
||||||
|
|
||||||
<p align="center">[[/images/Blocks-Sample-TensorFlow-Object-Detection-Op-Mode/setZoom.png]]<br/>Set Zoom Factor.<p>
|
<p align="center">[[/images/Blocks-Sample-TensorFlow-Object-Detection-Op-Mode/setZoom.png]]<br/>Set Zoom Factor.<p>
|
||||||
|
|
||||||
@ -51,7 +51,6 @@ If a zoom factor has been set, then the Camera Stream preview on the Driver Stat
|
|||||||
|
|
||||||
<p align="center">[[/images/Blocks-Sample-TensorFlow-Object-Detection-Op-Mode/magnifiedArea.png]]<br/>Camera Stream Preview Indicating Magnified Area.<p>
|
<p align="center">[[/images/Blocks-Sample-TensorFlow-Object-Detection-Op-Mode/magnifiedArea.png]]<br/>Camera Stream Preview Indicating Magnified Area.<p>
|
||||||
|
|
||||||
|
|
||||||
### Iterating and Processing List of Recognized Objects
|
### Iterating and Processing List of Recognized Objects
|
||||||
|
|
||||||
The Op Mode will then check with the object detector to see how many objects it recognizes in its field of view. In the screenshot below, the variable "recognitions" is set to a list of objects that were recognized using the TensorFlow technology. The Op Mode adds a telemetry message to indicate on the Driver Station how many objects were detected in the camera's field of view.
|
The Op Mode will then check with the object detector to see how many objects it recognizes in its field of view. In the screenshot below, the variable "recognitions" is set to a list of objects that were recognized using the TensorFlow technology. The Op Mode adds a telemetry message to indicate on the Driver Station how many objects were detected in the camera's field of view.
|
||||||
|
Reference in New Issue
Block a user