You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

CNNRecognizer.h 492 B

6 years ago
123456789101112131415161718192021222324
  1. //
  2. // Created by 庾金科 on 21/10/2017.
  3. //
  4. #ifndef SWIFTPR_CNNRECOGNIZER_H
  5. #define SWIFTPR_CNNRECOGNIZER_H
  6. #include "Recognizer.h"
  7. namespace pr{
  8. class CNNRecognizer: public GeneralRecognizer{
  9. public:
  10. const int CHAR_INPUT_W = 14;
  11. const int CHAR_INPUT_H = 30;
  12. CNNRecognizer(std::string prototxt,std::string caffemodel);
  13. label recognizeCharacter(cv::Mat character);
  14. private:
  15. cv::dnn::Net net;
  16. };
  17. }
  18. #endif //SWIFTPR_CNNRECOGNIZER_H