My model accept input in the form NCHW, but according to the documentation for tensor_order
:
num TensorOrder with order types: TENSOR_ORDER_NONE, TENSOR_ORDER_LINEAR, TENSOR_ORDER_NHWC. It can deduce the value from backend layers info if set to TENSOR_ORDER_NONE
How can I feed the data as NCHW
to my model? I am running a custom model in Triton Server.
pgie_config.txt
:
infer_config {
unique_id: 5
gpu_ids: [0]
max_batch_size: 4
backend {
trt_is {
model_name: "yolov5n-onnx"
version: -1
model_repo {
root: "./"
log_level: 2
tf_gpu_memory_fraction: 0.4
tf_disable_soft_placement: 0
}
}
}
preprocess {
network_format: IMAGE_FORMAT_RGB
tensor_order: TENSOR_ORDER_NCHW <---- INVALID
maintain_aspect_ratio: 0
normalize {
scale_factor: 1.0
channel_offsets: [0, 0, 0]
}
}
postprocess {
labelfile_path: "yolov5n-onnx/labels.txt"
other {}
}
extra {
copy_input_to_host_buffers: false
}
custom_lib {
path: "libnvdsinfer_custom_impl_Yolo.so"
}
}
input_control {
process_mode: PROCESS_MODE_FULL_FRAME
interval: 0
}
output_control {
output_tensor_meta: true
}
model repo config:
name: "yolov5n-onnx"
backend: "onnxruntime"
input [
{
name: "images"
data_type: TYPE_FP32
# format: FORMAT_NCHW
dims: [3,640,640]
}
]
output [
{
name: "output"
data_type: TYPE_FP32
dims: [1,25200,85]
}
]
instance_group [{ kind: KIND_CPU }]