Updated Java Sample TensorFlow Object Detection Op Mode (markdown)
@ -114,7 +114,7 @@ The origin of the coordinate system is in the upper left-hand corner of the imag
|
|||||||
In the landscape image above, the approximate coordinate values for the Left, Top, Right, and Bottom boundaries are 455, 191, 808, and 547 respectively (pixel coordinates). The width and height for the landscape image above is 1280 and 720 respectively.
|
In the landscape image above, the approximate coordinate values for the Left, Top, Right, and Bottom boundaries are 455, 191, 808, and 547 respectively (pixel coordinates). The width and height for the landscape image above is 1280 and 720 respectively.
|
||||||
|
|
||||||
### Activating TensorFlow
|
### Activating TensorFlow
|
||||||
In this example, the Op Mode activates the TensorFlow object detector before waiting for the start command from the Driver Station. This is done so that the user can access the "Camera Stream" preview from the Driver Station menu while it waits for the start command. Also note that in this example, the op mode does not activate the Vuforia tracking feature, it only activates TensorFlow object detection. If you want to incorporate Vuforia image detection and tracking you will also need to activate (and later deactivate when you are done) the Vuforia tracking feature.
|
In this example, the op mode activates the TensorFlow object detector before waiting for the start command from the Driver Station. This is done so that the user can access the "Camera Stream" preview from the Driver Station menu while it waits for the start command. Also note that in this example, the op mode does not activate the Vuforia tracking feature, it only activates TensorFlow object detection. If you want to incorporate Vuforia image detection and tracking you will also need to activate (and later deactivate when you are done) the Vuforia tracking feature.
|
||||||
|
|
||||||
```
|
```
|
||||||
/**
|
/**
|
||||||
@ -264,7 +264,7 @@ Note that Android devices can be locked into Portrait Mode so that the screen im
|
|||||||
<p align="center">[[/images/Blocks-Sample-TensorFlow-Object-Detection-Op-Mode/autorotate.png]]<br/>Auto-rotate must be enabled in order to operate in Landscape mode.<p>
|
<p align="center">[[/images/Blocks-Sample-TensorFlow-Object-Detection-Op-Mode/autorotate.png]]<br/>Auto-rotate must be enabled in order to operate in Landscape mode.<p>
|
||||||
|
|
||||||
### Deactivating TensorFlow
|
### Deactivating TensorFlow
|
||||||
When the example Op Mode is no longer active (i.e., when the user has pressed the stop button on the Driver Station) the Op Mode will attempt to deactivate the TensorFlow library before it's done. It's important to deactivate the library to free up system resources.
|
When the example op mode is no longer active (i.e., when the user has pressed the stop button on the Driver Station) the op mode will attempt to deactivate the TensorFlow library before it's done. It's important to deactivate the library to free up system resources.
|
||||||
|
|
||||||
```
|
```
|
||||||
if (tfod != null) {
|
if (tfod != null) {
|
||||||
|
Reference in New Issue
Block a user