################################################################################
# SPDX-FileCopyrightText: Copyright (c) 2018-2022 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
# SPDX-License-Identifier: LicenseRef-NvidiaProprietary
#
# NVIDIA CORPORATION, its affiliates and licensors retain all intellectual
# property and proprietary rights in and to this material, related
# documentation and any modifications thereto. Any use, reproduction,
# disclosure or distribution of this material and related documentation
# without an express license agreement from NVIDIA CORPORATION or
# its affiliates is strictly prohibited.
################################################################################

infer_config {
  unique_id: 1
  gpu_ids: [0]
  max_batch_size: 1
  backend {
    inputs: [ {
      name: "images"
    }]
    outputs: [
      {name: "output"},
      {name: "462"},
      {name: "520"}
    ]
    triton {
      model_name: "Primary_Detector"
      version: 1
      model_repo {
        root: "/workspace/shared_docker/packages/opt/nvidia/deepstream/deepstream-7.1/sugon_samples/triton_model_repo"
        strict_model_config: true
        backend_dir: "/workspace/shared_docker/packages/opt/nvidia/deepstream/deepstream-7.1/sugon_samples/backends"
      }
    }
  }

  preprocess {
    network_format: MEDIA_FORMAT_NONE
    tensor_order: TENSOR_ORDER_LINEAR
    tensor_name: "images"
    maintain_aspect_ratio: 0
    frame_scaling_hw: FRAME_SCALING_HW_DEFAULT
    frame_scaling_filter: 1
    normalize {
      scale_factor: 0.00392156862745098
      channel_offsets: [0, 0, 0]
    }
  }

  postprocess {
    labelfile_path: "/workspace/shared_docker/packages/opt/nvidia/deepstream/deepstream-7.1/sugon_samples/models/Primary_Detector/labels.txt"
    detection {
      num_detected_classes: 80
      per_class_params {
        key: 0
        value { pre_threshold: 0.4 }
      }
      nms {
        confidence_threshold:0.2
        topk:20
        iou_threshold:0.5
      }
    }
  }

  extra {
    copy_input_to_host_buffers: false
    output_buffer_pool_size: 2
  }
}
input_control {
  process_mode: PROCESS_MODE_FULL_FRAME
  operate_on_gie_id: -1
  interval: 0
}
