Class LocalModelProvider
- Namespace
- InferenceEngine.Core.ModelProviders
- Assembly
- InferenceEngine.Core.dll
Model provider for locally stored model files. Validates that the file exists but does not perform any network operations.
public class LocalModelProvider : IModelProvider
- Inheritance
-
LocalModelProvider
- Implements
- Inherited Members
Constructors
LocalModelProvider(string)
Creates a provider for a local model file.
public LocalModelProvider(string modelPath)
Parameters
modelPathstringAbsolute or relative path to the .onnx model file
Properties
ModelPath
The model file path (absolute or relative).
public string ModelPath { get; }
Property Value
Methods
GetModelPathAsync(CancellationToken)
Gets the local path to the model file. Implementations should ensure the model is available at the returned path (downloading if necessary) before returning.
public Task<string> GetModelPathAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationTokenCancellation token for the operation