Skip to content

OpenCV 5: TextDetectorCNN unusable (Caffe importer removed from DNN) #1905

Description

@shimat

Summary

On the OpenCV 5 (5.x) branch, TextDetectorCNN.Create(modelArch, modelWeights) fails. The class still exists, but OpenCV 5's DNN module removed the Caffe importer:

OpenCvSharp.OpenCVException : Caffe importer has been removed. Please use ONNX-converted models or use an older OpenCV version.

TextDetectorCNN (textboxes) shipped Caffe .prototxt + .caffemodel weights, which can no longer be loaded.

Affected tests

  • Text.TextDetectorTest.Create
  • Text.TextDetectorTest.Detect

Workaround

Both tests are marked Skip on 5.x.

TODO

  • Decide the OpenCV 5 story for TextDetectorCNN: provide an ONNX-converted model, or deprecate/remove the wrapper.
  • Re-enable or remove the tests accordingly.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions