dusty-nv / jetson-inference

Hello AI World guide to deploying deep-learning inference networks and deep vision primitives with TensorRT and NVIDIA Jetson.
https://developer.nvidia.com/embedded/twodaystoademo
MIT License
7.75k stars 2.97k forks source link

Demo compatibility with jetpack 4.3 #475

Closed rahairi closed 1 year ago

rahairi commented 4 years ago

Look like the demo cannot be run with tensorRT 6.0.1. Tried detectnet-camera not working.

dusty-nv commented 4 years ago

What error do you get? I am able to run it with JetPack 4.3.

rahairi commented 4 years ago

no camera output, never ending loop on tactic

[gstreamer] initialized gstreamer, version 1.14.5.0 [gstreamer] gstCamera attempting to initialize with GST_SOURCE_NVARGUS, camera 0 [gstreamer] gstCamera pipeline string: nvarguscamerasrc sensor-id=0 ! video/x-raw(memory:NVMM), width=(int)1280, height=(int)720, framerate=30/1, format=(string)NV12 ! nvvidconv flip-method=2 ! video/x-raw ! appsink name=mysink [gstreamer] gstCamera successfully initialized with GST_SOURCE_NVARGUS, camera 0

detectnet-camera: successfully initialized camera device width: 1280 height: 720 depth: 12 (bpp)

detectNet -- loading detection network model from: -- model networks/SSD-Mobilenet-v2/ssd_mobilenet_v2_coco.uff -- input_blob 'Input' -- output_blob 'NMS' -- output_count 'NMS_1' -- class_labels networks/SSD-Mobilenet-v2/ssd_coco_labels.txt -- threshold 0.500000 -- batch_size 1

[TRT] TensorRT version 6.0.1 [TRT] loading NVIDIA plugins... [TRT] Plugin Creator registration succeeded - GridAnchor_TRT [TRT] Plugin Creator registration succeeded - GridAnchorRect_TRT [TRT] Plugin Creator registration succeeded - NMS_TRT [TRT] Plugin Creator registration succeeded - Reorg_TRT [TRT] Plugin Creator registration succeeded - Region_TRT [TRT] Plugin Creator registration succeeded - Clip_TRT [TRT] Plugin Creator registration succeeded - LReLU_TRT [TRT] Plugin Creator registration succeeded - PriorBox_TRT [TRT] Plugin Creator registration succeeded - Normalize_TRT [TRT] Plugin Creator registration succeeded - RPROI_TRT [TRT] Plugin Creator registration succeeded - BatchedNMS_TRT [TRT] Could not register plugin creator: FlattenConcat_TRT in namespace: [TRT] completed loading NVIDIA plugins. [TRT] detected model format - UFF (extension '.uff') [TRT] desired precision specified for GPU: FASTEST [TRT] requested fasted precision for device GPU without providing valid calibrator, disabling INT8 [TRT] native precisions detected for GPU: FP32, FP16 [TRT] selecting fastest native precision for GPU: FP16 [TRT] attempting to open engine cache file networks/SSD-Mobilenet-v2/ssd_mobilenet_v2_coco.uff.1.1.GPU.FP16.engine [TRT] cache file not found, profiling network model on device GPU [TRT] device GPU, loading /usr/local/bin/ networks/SSD-Mobilenet-v2/ssd_mobilenet_v2_coco.uff [TRT] UFFParser: Parsing Input[Op: Input]. [TRT] UFFParser: Input -> [3,300,300] [TRT] UFFParser: Applying order forwarding to: Input [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/weights[Op: Const]. [TRT] UFFParser: FeatureExtractor/MobilenetV2/Conv/weights -> [3,3,3,32] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/weights [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/Conv2D[Op: Conv]. Inputs: Input, FeatureExtractor/MobilenetV2/Conv/weights [TRT] UFFParser: FeatureExtractor/MobilenetV2/Conv/Conv2D -> [32,150,150] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/Conv2D [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/moving_variance[Op: Const]. [TRT] UFFParser: FeatureExtractor/MobilenetV2/Conv/BatchNorm/moving_variance -> [32] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/moving_variance [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/add/y[Op: Const]. [TRT] UFFParser: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/add/y -> [] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/add/y [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/add[Op: Binary]. Inputs: FeatureExtractor/MobilenetV2/Conv/BatchNorm/moving_variance, FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/add/y [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/add [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/Rsqrt[Op: Unary]. Inputs: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/add [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/Rsqrt [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/gamma[Op: Const]. [TRT] UFFParser: FeatureExtractor/MobilenetV2/Conv/BatchNorm/gamma -> [32] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/gamma [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/mul[Op: Binary]. Inputs: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/Rsqrt, FeatureExtractor/MobilenetV2/Conv/BatchNorm/gamma [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/mul [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/mul_1[Op: Binary]. Inputs: FeatureExtractor/MobilenetV2/Conv/Conv2D, FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/mul [TRT] UFFParser: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/mul_1 -> [32,150,150] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/mul_1 [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/beta[Op: Const]. [TRT] UFFParser: FeatureExtractor/MobilenetV2/Conv/BatchNorm/beta -> [32] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/beta [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/moving_mean[Op: Const]. [TRT] UFFParser: FeatureExtractor/MobilenetV2/Conv/BatchNorm/moving_mean -> [32] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/moving_mean [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/mul_2[Op: Binary]. Inputs: FeatureExtractor/MobilenetV2/Conv/BatchNorm/moving_mean, FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/mul [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/mul_2 [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/sub[Op: Binary]. Inputs: FeatureExtractor/MobilenetV2/Conv/BatchNorm/beta, FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/mul_2 [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/sub [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/add_1[Op: Binary]. Inputs: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/mul_1, FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/sub [TRT] UFFParser: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/add_1 -> [32,150,150] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/add_1 [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/Conv/Relu6[Op: Activation]. Inputs: FeatureExtractor/MobilenetV2/Conv/BatchNorm/batchnorm/add_1 [TRT] Setting dynamic range for (Unnamed Layer* 9) [Activation]_output to [0,6] [TRT] UFFParser: FeatureExtractor/MobilenetV2/Conv/Relu6 -> [32,150,150] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/Conv/Relu6 [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/expanded_conv/depthwise/depthwise_weights[Op: Const]. [TRT] UFFParser: FeatureExtractor/MobilenetV2/expanded_conv/depthwise/depthwise_weights -> [3,3,32,1] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/expanded_conv/depthwise/depthwise_weights [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/expanded_conv/depthwise/depthwise[Op: Conv]. Inputs: FeatureExtractor/MobilenetV2/Conv/Relu6, FeatureExtractor/MobilenetV2/expanded_conv/depthwise/depthwise_weights [TRT] UFFParser: FeatureExtractor/MobilenetV2/expanded_conv/depthwise/depthwise -> [32,150,150] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/expanded_conv/depthwise/depthwise [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/expanded_conv/depthwise/BatchNorm/moving_variance[Op: Const]. [TRT] UFFParser: FeatureExtractor/MobilenetV2/expanded_conv/depthwise/BatchNorm/moving_variance -> [32] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/expanded_conv/depthwise/BatchNorm/moving_variance [TRT] UFFParser: Parsing FeatureExtractor/MobilenetV2/expanded_conv/depthwise/BatchNorm/batchnorm/add/y[Op: Const]. [TRT] UFFParser: FeatureExtractor/MobilenetV2/expanded_conv/depthwise/BatchNorm/batchnorm/add/y -> [] [TRT] UFFParser: Applying order forwarding to: FeatureExtractor/MobilenetV2/expanded_conv/depthwise/BatchNorm/batchnorm/add/y

rahairi commented 4 years ago
dusty-nv commented 4 years ago

The SSD models take a few minutes to load the first time (around 5 minutes). I just tried it again here, and it loads and runs as expected on JetPack 4.3.

Philliec459 commented 4 years ago

Can I ask what actually is going on the first time you try to run a model vs. every time after that? The first time I tried a few models with my web cam it seemed to go on and on so I killed the program thinking that I had the wrong webcam. Now it works perfect. I would just like to know what the program does the fist time that is do different. Thanks

WyattAutomation commented 4 years ago

Confirmed that this is the case with running the python detectnet-camera.py example on the Nano; both the coco and the SSD models had to run for 8 and 5 minutes respectively on the loop of 'tactic' information that whizzes by on their first load. Subsequent uses start up right away.

Might be worth a quick mention in the documentation for the examples. I did the same thing and fuddled around with swapping/testing cams before I found this thread; wasn't expecting that to be the issue but I'm glad it works and appreciate the help here!