TeamCode/src/main/java/org/firstinspires/ftc/teamcode/TensorFlowBot.java
/**
     * Initialize the TensorFlow Object Detection engine.
     */
Initialize the TensorFlow Object Detection engine.
Initialize the TensorFlow Object Detection engine .
private void initTfod(HardwareMap hardwareMap) {
        int tfodMonitorViewId = hardwareMap.appContext.getResources().getIdentifier(
                "tfodMonitorViewId", "id", hardwareMap.appContext.getPackageName());
        TFObjectDetector.Parameters tfodParameters = new TFObjectDetector.Parameters(tfodMonitorViewId);
        tfodParameters.minimumConfidence = 0.75;
        tfod = ClassFactory.getInstance().createTFObjectDetector(tfodParameters, vuforia);
        tfod.loadModelFromAsset(TFOD_MODEL_ASSET, LABEL_FIRST_ELEMENT, LABEL_SECOND_ELEMENT);
    }
private void initTfod ( HardwareMap hardwareMap ) { int tfodMonitorViewId = hardwareMap . appContext . getResources ( ) . getIdentifier ( "tfodMonitorViewId" , "id" , hardwareMap . appContext . getPackageName ( ) ) ; TFObjectDetector . Parameters tfodParameters = new TFObjectDetector . Parameters ( tfodMonitorViewId ) ; tfodParameters . minimumConfidence = 0.75 ; tfod = ClassFactory . getInstance ( ) . createTFObjectDetector ( tfodParameters , vuforia ) ; tfod . loadModelFromAsset ( TFOD_MODEL_ASSET , LABEL_FIRST_ELEMENT , LABEL_SECOND_ELEMENT ) ; }
Initialize the TensorFlow Object Detection engine.
Initialize the TensorFlow Object Detection engine .