Testing environment
ubuntu14.04 + python2.7
Direct dependencies
Installation pipeline recommended
1 Install Anaconda (alternative) to replace default python;
2 Configure CUDA and alter ~/.theanorc
(ignore the step if not use GPU);
vim ~/.theanorc
Then add:
[global]
device = gpu
floatX = float32
3 Install keras: using the default or specified version (0.1.2) to avoid the problems caused by changed API of the latest version;
cd keras-master
python setup.py install
4 Configure openCV: sudo apt-get install python-opencv
, then add cv2.so to the python path.
Note: the codes work for windows as well, just make sure the python dependencies have been installed.
1 Change the input (where the CAPTCHA pictures are stored) and output path in the script;
2 run python test_type*N*.py
.
Type | Accuracy |
---|---|
type1 | 0.92 |
type2 | 0.99 |
type3 | 0.99 |
type4 | 1 |
type5 | 0.74 |
type6 | 0.37 |
Find more testing data here
测试环境:ubuntu14.04+python2.7
直接依赖:
推荐安装步骤:
配置CUDA并修改~/.theanorc
文件(不使用gpu可省略这一步)
vim ~/.theanorc
然后添加:[global]
device=gpu
floatX=float32
由于最新版keras API发生改变,请使用自带版本,或下载指定版本(0.1.2)
cd keras-master
python setup.py install
配置opencv: sudo apt-get install python-opencv
然后将cv2.so添加到PYTHON路径
代码在windows下也测试通过,安装windows版本python依赖即可
python test_type*N*.py
类型 | 识别率 |
---|---|
type1 | 0.92 |
type2 | 0.99 |
type3 | 0.99 |
type4 | 1 |
type5 | 0.74 |
type6 | 0.37 |
更多测试数据下载地址