Model Config

get_model_config(model_id)

Get the model config for a given model ID

Return type

ModelConfig

class ModelConfig(model_id, model_path)

The model configuration parameters.

Parameters
  • model_id (str) – The ID of the model

  • model_path (str) – The path to the root directory of the model

property id

The model ID

Return type

str

property label_file

Relative path to the label file

Return type

str

property colors_file

Relative path to the colors file

Return type

str

property config_file

Relative path to the model framework config file

Return type

str

property model_file

Relative path to the model weights file

Return type

str

property mean

The RGB/BGR mean values for the model

Return type

Tuple[float, float, float]

property scalefactor

The scale factor for the model input

Return type

float

property size

The input image size of the model

Return type

Tuple[int, int]

property purpose

The purpose of the model

Return type

str

property framework_type

The framework type of the model

Return type

str

property crop

Whether or not to crop the image prior to inferencing

Return type

bool

property colors_dtype

The data type of the color values

Return type

str

property labels

The labels of the model

Return type

List[str]

property colors

The colors for each label of the model

Return type

List[Tuple[int, int, int]]

property swaprb

Whether to swap the red and blue channels of the image prior to inference

Return type

bool

property architecture

The architecture of the model

Return type

str

property softmax

Whether to perform softmax after the inference

Return type

bool

property device

The device the model was built for

Return type

Optional[SupportedDevices]

property output_layer_names

The output layer names of the model

Return type

List[str]

property hailo_quantize_input

Whether to quantize input of Hailo model

Return type

Optional[bool]

property hailo_quantize_output

Whether to quantize output of Hailo model

Return type

Optional[bool]

property hailo_input_format

Input format for Hailo model

Return type

Optional[str]

property hailo_output_format

Output format of Hailo model

Return type

Optional[str]

property dnn_support

Whether the model supports the DNN Engine

Return type

bool

property dnn_myriad_support

Whether the model supports the DNN Myriad Engine

Return type

bool

property dnn_cuda_support

Whether the model supports the DNN CUDA Engine

Return type

bool

property tensor_rt_support

Whether the model supports the TensorRT Engine

Return type

bool

property eyecloud_support

Whether the model supports Eyecloud cameras

Return type

bool

property hailo_support

Whether the model supports Hailo Engine

Return type

bool