Wait Conditions detector module detects intersections, traffic lights and traffic signs from camera images. NVIDIA proprietary DNN named WaitNet will return the detected bounding box of intersections, traffic signs and traffic lights.
Wait Conditions classifier module classifies detected traffic signs and traffic lights from camera images. NVIDIA proprietary DNN named LightNet will return the state (color(s) and shape(s)) of a detected traffic light. NVIDIA proprietary DNN named SignNet will return the class of a detected traffic sign.
Wait Conditions detector module can create default parameters:
With the generated default parameters, Wait Conditions detector module can be initialized by:
where dwWaitNetHandle_t specifies the handle to the WaitNet module, dwWaitConditionsDetectorParams is pointer to WaitConditionsDetector parameters, dwTransformation3f is camera extrinsic transformation, dwCameraModelHandle_t is camera intrinsic transformation, dwEgomotionConstHandle_t is egomotion module handle and dwContextHandle_t specifies the handle to the drivework context. The camera extrinsic can be set by:
The output of the module need to be created by the application and bind to the detector module by:
where dwWaitConditionsDetectorOutput holds the output.
CUDA stream can be set and get by:
After module initialization, the network to detect the intersection, traffic light and traffic sign can be inferred by:
where imageArray stores pointers to images where the detector is to be applied. The inferred result can be interpreted by:
After the interpretation, the detection result can be accessed in the output bound to the detector.
The module can be released by:
Wait Conditions classifier module initialization takes either a user customized sign detection network module handle or a user customized light detection network module handle as an input. To initialize NVIDIA Traffic Light/Sign Classifier module:
With the initialized LightNet module handle, Wait Conditions classifier module can be initialized by:
With the initialized SignNet module handle, Wait Conditions classifier module can be initialized by:
After module initialization, the sequential API calls to classify detected input traffic signs and traffic lights are as follows. To perform network inference on GPU:
To interpret the network inferred results into traffic light states or traffic sign classes:
To get the per frame interpreted results in the format of subClassId
field on each traffic sign or traffic light dwObject:
To release the Wait Conditions classifier module, the module itself needs to be released first by:
then the SignNet module:
or the LightNet module: