SegmentationModel
This class represents high-level API for segmentation models
SegmentationModel allows to set params for preprocessing input image. SegmentationModel creates net from file with trained weights and config, sets preprocessing input, runs forward pass and returns the class prediction for each pixel.
Member of Dnn
-
Create segmentation model from network represented in one of the supported formats. An order of @p model and @p config arguments does not matter.
Declaration
Objective-C
- (nonnull instancetype)initWithModel:(nonnull NSString *)model config:(nonnull NSString *)config;
Swift
init(model: String, config: String)
Parameters
model
Binary file contains trained weights.
config
Text file contains network configuration.
-
Create segmentation model from network represented in one of the supported formats. An order of @p model and @p config arguments does not matter.
Declaration
Objective-C
- (nonnull instancetype)initWithModel:(nonnull NSString *)model;
Swift
init(model: String)
Parameters
model
Binary file contains trained weights.