A TensorFlow-based CNN solution for recognizing character-based CAPTCHAs, providing training, validation, and API modules.
cnn_captcha is an open-source tool that uses convolutional neural networks (CNNs) built with TensorFlow to automatically recognize character-based image CAPTCHAs. It solves the problem of bypassing CAPTCHA challenges in web scraping and automation by providing a trainable model that can be customized for different CAPTCHA styles. The project includes a full pipeline from dataset preparation to a deployable API, making it a practical solution for developers needing reliable CAPTCHA recognition.
Developers and researchers working on web scraping, automation, or computer vision projects that require bypassing CAPTCHA protections. It is also suitable for those looking for a hands-on introduction to applying CNNs for image recognition tasks.
Developers choose cnn_captcha because it offers a ready-to-use, modular framework that significantly reduces the complexity and time required to build a CAPTCHA recognition system from scratch. Unlike generic OCR tools, it is specifically optimized for character-based CAPTCHAs and provides high accuracy with minimal configuration, along with tools for performance monitoring and easy deployment via a web API.
use cnn recognize captcha by tensorflow. 本项目针对字符型图片验证码,使用tensorflow实现卷积神经网络,进行验证码识别。
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Provides a complete workflow from dataset validation and splitting to training and API deployment, reducing manual steps in CAPTCHA recognition. The README includes detailed scripts for each phase, like verify_and_split_data.py and train_model.py.
Uses JSON configuration files for easy customization of image dimensions, character sets, and training parameters, allowing adaptation to various CAPTCHA styles. Sample configs like sample_config.json let users tweak settings without code changes.
Includes a Flask-based REST API for real-time recognition, making it easy to integrate into automation scripts or web scraping tools. The webserver_recognize_api.py file exposes endpoints with example usage in recognize_local.py.
Comes with batch testing and pressure testing scripts to measure accuracy and response times, helping users optimize models. The recognize_time_test.py logs detailed metrics like recognition and request durations.
Relies on TensorFlow 1.x-era code, which may cause compatibility issues with modern TensorFlow 2.x installations and lack support for newer features. The README's last major update was in 2019, and dependencies in requirements.txt are not recent.
Requires users to create multiple directories, prepare datasets with specific naming conventions, and tune configurations, which can be error-prone. The README mentions known bugs like OOM errors and path issues that need troubleshooting.
Training models demands significant GPU memory and time, with the README noting OOM happens if batch sizes are too large or resources are limited. This makes it less suitable for low-power environments.
Only supports character-based image CAPTCHAs, excluding dynamic or interactive types like those with moving elements, which requires switching to other projects like darknet_captcha.