Net.fromCaffe constructor
Reads a network model stored in Caffe framework's format. https://docs.opencv.org/4.x/d6/d0f/group__dnn.html#ga7117752a0216d9f84a9677eefdabf514
Implementation
factory Net.fromCaffe(String prototxt, String caffeModel) {
return using<Net>((arena) {
final cProto = prototxt.toNativeUtf8(allocator: arena).cast<ffi.Char>();
final cCaffe = caffeModel.toNativeUtf8(allocator: arena).cast<ffi.Char>();
final p = calloc<cvg.Net>();
cvRun(() => cffi.Net_ReadNetFromCaffe(cProto, cCaffe, p));
final net = Net._(p);
return net;
});
}