License Details
Relevant source files
The following files were used as context for generating this wiki page:
This document outlines the licensing information and project metadata for the mbbank-capcha-ocr library. The project is an open-source Optical Character Recognition (OCR) base library specifically designed for MBBank CAPTCHA recognition using PyTorch and ONNX.
The project is released under a permissive license that allows for broad use, modification, and distribution. Proper attribution and adherence to the license terms are required when integrating this library into other applications or distributing its components.
Sources: README.md:1-5, setup.py:16-18
License Classification
The project is officially licensed under the MIT License. This choice of license provides a flexible framework for developers to utilize the OCR model and its training scripts in both open-source and proprietary projects.
License Implementation in Project Metadata
The license is declared in two primary locations within the repository to ensure visibility for both users reading the documentation and automated tools parsing package metadata.
| Location | Description |
|---|---|
README.md | Contains a dedicated "License" section pointing to the LICENSE file for more details. |
setup.py | Defines the license parameter as "MIT" within the setup() function for PyPI/distribution metadata. |
Sources: README.md:54-56, setup.py:18
Metadata Overview
The project distribution details are managed via setup.py, which links the MIT license to specific author and repository information.
The diagram above shows the relationship between the project identity and its licensing/authorship metadata.
Sources: setup.py:16-23, mb_capcha_ocr/init.py:3
Software Distribution and Usage
The MIT license applies to the core library components, which include the prediction logic and the training infrastructure.
Component Breakdown
The following table summarizes the primary components covered under the project's license and distribution structure:
| Component | Path | Description |
|---|---|---|
| Core Library | mb_capcha_ocr/ | Contains the OcrModel for inference using ONNX. |
| Training Logic | train_model/ | Contains scripts for training the ResNet18-based model. |
| Pre-trained Model | mb_capcha_ocr/model.onnx | Included as package data in the distribution. |
Sources: setup.py:24-27, README.md:8-10, mb_capcha_ocr/predict.py:12-15
Installation and Dependencies
The license permits the installation of dependencies required to run or train the model. These are managed through standard Python requirement files.
The flow shows how the setup.py file utilizes the MIT license to distribute the package alongside its dependencies.
Sources: setup.py:4-5, setup.py:28
Credits and Attributions
While the project is MIT licensed, it acknowledges the use of external datasets. The project credits CookieGMVN for providing the CAPTCHA image datasets (V1 and V2) used for training the model.
Sources: README.md:58-60
Summary
The mbbank-capcha-ocr project is distributed as a lightweight OCR solution under the MIT License. This licensing model ensures that the code, including the OcrModel and training modules found in train_model/core.py and mb_capcha_ocr/predict.py, can be freely utilized in various software environments provided the license conditions are met.
Sources: README.md:54-56, setup.py:18