caruofc
November 19, 2020, 8:07pm
1
Can I avoid using sample::gLogger as demonstrated in the SampleYolo.cpp of the tensorrt_yolov4 program in the following link?
# YOLOv4 Standalone Program of Multi-Tasks
## 1. Contents
- **`common`** Some common code dependencies and utilities
- **`source`** Source code of standalone Program
- `main.cpp`: Program main entrance where parameters are configured here
- `SampleYolo.hpp`: YOLOv4 inference class definition file
- `SampleYolo.cpp`: YOLOv4 inference class functions definition file
- `onnx_add_nms_plugin.py`: Python script to add BatchedNMSPlugin node into ONNX model
- `generate_coco_image_list.py`: Python script to get list of image names from MS COCO annotation or information file
- **`data`** This directory saves:
- `yolov4.onnx`: the ONNX model (User generated)
- `yolov4.engine`: the TensorRT engine model (would be generated by this program)
- `demo.jpg`: The demo image (Already exists)
- `demo_out.jpg`: Image detection output of the demo image (Already exists, but would be renewed by the program)
- `names.txt`: MS COCO dataset label names (have to be downloaded or generated via COCO API)
- `categories.txt`: MS COCO dataset categories where IDs and names are separated by `"\t"` (have to be generated via COCO API)
- `val2017.txt`: MS COCO validation set image list (have to be generated from corresponding COCO annotation file)
This file has been truncated. show original
My issue is, I do not want to use the logger and it does not seem I can use nullptr in this case as some of the functions parameter in SampleYolo.cpp use the reference of sample::gLogger as the parameter instead of the pointer.
Please advice.
Hi @caruofc ,
Logger is necessary in TRT, if you do not want gLogger we provided, you may have to write a logger yourself.
Thanks!