ORTRunOptions
Objective-C
@interface ORTRunOptions : NSObject
Swift
class ORTRunOptions : NSObject
Options for configuring a run.
-
Unavailable
Declaration
Objective-C
- (instancetype)init NS_UNAVAILABLE; -
Creates run configuration options.
Declaration
Objective-C
- (nullable instancetype)initWithError:(NSError *_Nullable *_Nullable)error;Swift
init() throwsParameters
errorOptional error information set if an error occurs.
Return Value
The instance, or nil if an error occurs.
-
Sets the run log tag.
Declaration
Objective-C
- (BOOL)setLogTag:(nonnull NSString *)logTag error:(NSError *_Nullable *_Nullable)error;Swift
func setLogTag(_ logTag: String) throwsParameters
logTagThe log tag.
errorOptional error information set if an error occurs.
Return Value
Whether the option was set successfully.
-
Sets the run log severity level.
Declaration
Objective-C
- (BOOL)setLogSeverityLevel:(ORTLoggingLevel)loggingLevel error:(NSError *_Nullable *_Nullable)error;Swift
func setLogSeverityLevel(_ loggingLevel: ORTLoggingLevel) throwsParameters
loggingLevelThe log severity level.
errorOptional error information set if an error occurs.
Return Value
Whether the option was set successfully.
-
Sets a run configuration key-value pair. Any value for a previously set key will be overwritten. The run configuration keys and values are documented here: https://github.com/microsoft/onnxruntime/blob/main/include/onnxruntime/core/session/onnxruntime_run_options_config_keys.h
Declaration
Objective-C
- (BOOL)addConfigEntryWithKey:(nonnull NSString *)key value:(nonnull NSString *)value error:(NSError *_Nullable *_Nullable)error;Swift
func addConfigEntry(withKey key: String, value: String) throwsParameters
keyThe key.
valueThe value.
errorOptional error information set if an error occurs.
Return Value
Whether the option was set successfully.
View on GitHub
ORTRunOptions Class Reference