ONNX networks¶
-
class OnnxNetwork : public virtual klartraum::ComputeGraphElement, public virtual klartraum::ComputeGraphGroup¶
Public Functions
-
OnnxNetwork(VulkanContext &vulkanContext, const std::string &modelPath)¶
ONNX Neural Network Graph Representation.
This class provides GPU-accelerated execution of ONNX models using Klartraum ComputeGraph Framework. It supports:
Loading and parsing ONNX model files
Converting ONNX operations to ComputeGraphElement instances
Managing GPU memory for tensors and intermediate results by ComputeGraphElement instances
-
virtual void _setup(VulkanContext &vulkanContext, uint32_t numberPaths, VkQueue setupQueue = VK_NULL_HANDLE) override¶
Initializes resources for the graph paths.
- Parameters:
vulkanContext – The context providing the resources and queues.
numberPaths – The number of execution paths.
setupQueue – The queue for uploads and immediate submissions. VK_NULL_HANDLE uses the graphics queue. Pass this queue to nested elements.
-
OnnxNetwork(VulkanContext &vulkanContext, const std::string &modelPath)¶