Deep Learning Data Type
Data type for generating code that uses NVIDIA TensorRT high performance inference library
Since R2024a
Model Configuration Pane: Code Generation / Interface
Description
The Data type parameter specifies the data type to be used by TensorRT library for deep learning code generation.
Dependencies
This parameter requires a GPU Coder™ license.
To set the data type for TensorRT libraries, in the Configuration Parameters dialog, in the Code Generation settings, set Language to
C++
and enable Generate GPU Code. Then in Code Generation > Interface settings, in the Deep learning section, set Target library toTensorRT
.
Settings
"fp32"
(default) | "fp16"
- fp32
Generate code in 32-bit floating-point.
- fp16
Generate code in half-precision floating-point.
Recommended Settings
Application | Setting |
---|---|
Debugging | |
Traceability | |
Efficiency | |
Safety precaution |
Programmatic Use
Parameter:
DLDataType
|
Value:
"fp32" | "fp16" |
Default:
"fp32" |
Version History
Introduced in R2024a
See Also
coder.DeepLearningConfig
| codegen
| coder.CodeConfig
| coder.TensorRTConfig
(GPU Coder)