v2026.4.1
All Bundles

ResNetSession

ResNet inference session for image classification. Performs ImageNet-style classification with softmax probability normalization. Example labels := ["tabby cat", "golden retriever", "sports car"]; session := ResNetSession->New("resnet50.onnx"); result := session->Inference(image_bytes, 224, 224, labels); "Top: {result->GetName()} ({result->GetConfidence()})"->PrintLine(); session->Close();

Operations

Close

Closes the session

method : public : Close() ~ Nil

Inference

ResNet image inference

method : public : Inference(image:Byte[], height:Int, labels:String[]) ~ API.Onnx.ResNetResult

Parameters

NameTypeDescription
imageBytewidth width
heightIntimage height
labelsStringclassification labels

New

Constructor.

New(model:String)

Parameters

NameTypeDescription
modelStringResNet model path

New

Constructor.

New(model:String, config:Map<String,String>)

Parameters

NameTypeDescription
modelStringResNet model path
configMap<String,String>session configuration parameters