VAI_C Usage - 3.5 English

Vitis AI User Guide (UG1414)

Document ID
Release Date
3.5 English

The corresponding Vitis AI compilers for Caffe and TensorFlow frameworks are vai_c_caffe, vai_c_tensorflow, vai_c_tensorflow2, and vai_c_xir across Data Center-to-Edge DPUs. The standard options for VAI_C are shown in the following table.

Table 1. VAI_C Common Options for Data Center and Edge DPU
Parameters Description
--arch The DPU architecture configuration file for the VAI_C compiler in JSON format. For pre-built DPU xclbins in AMD Vitis™ AI releases, you can find the corresponding arch.json file in AMD Vitis™ AI Docker (/opt/vitis_ai/compiler/arch). The contents should be something like {"target": "DPUCZDX8G_ISA0_B4096"}. For customized DPU IPs, the corresponding arch.json files are generated by the DPU reference design and DPU IPs. The contents should be something like {“fingerprint”:"0x0101000016010407"}. The fingerprint is a 64-bit digital signature to identify a DPU target. It consists of 1 byte to indicate the DPU type, 1 byte to indicate the ISA version, and 6 bytes to indicate specific configurations. The fingerprint is unique to each DPU configuration, and runtime relies on it to identify DPU instances running on the current platform and to verify that the model is compiled for the same DPU target. "DPUCZDX8G_ISA0_B4096" is an alias for a specific fingerprint which is pre-defined in the compiler.
--output_dir Path of output directory for vai_c_tensorflow after compilation process.
--net_name Name of DPU kernel for network model after compiled by VAI_C.
--options The list for the extra options in the format of 'key':'value'. If there are multiple options to be specified, they are separated by ‘,’.

Use --options '{"input_shape": "1,224,224,3"}' to specify the input shape manually.

Use --options '{"plugins": "plugin0,plugin1"}' to specify plugin libraries.

Use --options '{"output_ops": "op_name0,op_name1"}' to specify output ops.

Use --options '{"prefetch": "true"}' to enable cross-layer prefetch.

Use --options '{"hd_opt": "true"}' to enable special optimization for HD input.

Note: Arguments specified with “--options” have the highest priorities and override values specified elsewhere.