EasyPR Linuxテスト

1361 ワード

Ubuntu 14でEasyPRを行う.04でコンパイルを行い、いくつかの問題に遭遇して記録した.
  • はOpenCV 3.0と2である.xは互換性がなく、現在のバージョンのEasyPRはOpenCVのみ互換性がある.x.
  • ソースファイルはGBK符号化を使用しているが、LinuxではUTF-8の符号化がデフォルトであり、デフォルトでコンパイルされた実行可能ファイルには中国語の文字化けが発生する.私が採用した解決策は、ソースファイルを符号化変換してからコンパイルすることです.
  • cd test
    mv main.cpp main_gbk.cpp
    iconv -f gbk -t utf8 main_gbk.cpp > main.cpp
    cd ../src/core
    mv chars_identify.cpp chars_identify_gbk.cpp
    iconv -f gbk -t utf8 chars_identify_gbk.cpp > chars_identify.cpp

      3. test_plate_locateエラー
    test_plate_locateOpenCV Error: Unspecified error (The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Carbon support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script) in cvShowImage, file/opencv-2.4.11/modules/highgui/src/window.cpp, line 501terminate called after throwing an instance of 'cv::Exception'  what(): /opencv-2.4.11/modules/highgui/src/window.cpp:501: error: (-2) The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Carbon support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script in function cvShowImage
    apt-get install libgtk2.0-dev
    cd/opencv-2.4.11/
    cmake
    make
    make install
    破棄済み(コアダンプ済み)
    後で問題があったら更新します.