English | 한국어 | 日本語 | Tiếng Việt |
Python サンプル
https://github.com/bobhyun/TS-ANPR/tree/main/examples/Python/anpr
1. エンジンファイルのコピー
【参考】 この例では、他のサンプルとエンジンファイルを共有するために examples/bin/
ディレクトリに展開しますが、実際の配布時には通常、アプリケーションの実行ファイルがあるディレクトリにエンジンファイルをコピーします。
- Windows x86 64 ビット
エンジンファイルを
examples/bin/windows-x86_64
ディレクトリに展開unzip tsanpr*-windows-x86_64.zip
- Windows x86 32 ビット
エンジンファイルを
examples/bin/windows-x86
ディレクトリに展開unzip tsanpr*-windows-x86.zip
- Linux x86 64 ビット
エンジンファイルを
examples/bin/linux-x86_64
ディレクトリに展開tar xvf tsanpr*-linux-x86_64.tar.xz
- Linux ARM 64 ビット
エンジンファイルを
examples/bin/linux-aarch64
ディレクトリに展開tar xvf tsanpr*-linux-aarch64.tar.xz
- ディレクトリ構成
examples ├── bin │ ├─── windows-x86_64 # engine directory for Windows (x86_64) │ │ ├── tsanpr.dll │ │ ├── tsanpr-2505M.eon │ │ └── tshelper.exe │ ├─── windows-x86 # engine directory for Windows (x86) │ │ ├── tsanpr.dll │ │ ├── tsanpr-2505M.eon │ │ └── tshelper.exe │ ├── linux-x86_64 # engine directory for Linux (x86_64) │ │ ├── libtsanpr.so │ │ ├── tsanpr-2505M.eon │ │ └── tshelper │ └── linux-aarch64 # engine directory for Linux (arm64) │ ├── libtsanpr.so │ ├── tsanpr-2505M.eon │ └── tshelper ├── img # image directory └── Python └── anpr # source directory ├── anpr.py ├── webcam.py └── tsanpr └── tsanpr.py
2. 実行方法
-
依存関係のインストール
pip install opencv-python
-
anpr
の実行python anpr.py
-
webcam
の実行python webcam.py