Skip to content
Costa Rican license plate dataset generator
Python
Branch: master
Clone or download
pereiraa
Latest commit c7b3759 Sep 14, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
templates general development Feb 22, 2019
.gitignore - Fixed rotated bbox calculations. Apr 4, 2019
LICENSE
README.md Changed perspective angles configuration to range instead of single i… Sep 2, 2019
annotations.py -Added annotator classes to handle json and csv annotations May 24, 2019
configuration.cfg Changed perspective angles configuration to range instead of single i… Sep 2, 2019
context.py Added bouding box generation for each character in the plate. Mar 18, 2019
jsonutil.py Added bouding box generation for each character in the plate. Mar 18, 2019
main.py
perspective.py
plate.py
requirements.txt Updating requirments Mar 26, 2019
scene.py Updates to random plate scaling and bg sizes Mar 26, 2019
templates.json Basic dataset generation main code Mar 26, 2019
utils.py Basic dataset generation main code Mar 26, 2019

README.md

cr-plates-generator

Costa Rica license plate generator for computer vision

Features

  • Plate formats: car, motorcycle, trucks, taxi, disabled drivers.
  • Perspective rotations, size and random backgrounds.
  • Annotations with character bounding boxes (class, cx, cy, w, h)
  • configuration.cfg and templates.json files for customization.

Examples

[Pending]

Getting Started

Prerequisites

  • Python >= 3.6.0
  • Modules on requirements.txt pip3 install -r requirements.txt

Running sample code

  1. Add some images to ./backgrounds directory, these will work as random backgrounds for the plates. SUN Database is recommended.

  2. Run the main file python ./main.py

  3. Random plates will be generated on ./output directory

Settings

configuration.cfg

The following is a description of all the settings on this file.

Setting Description Value
[General]
dataset_size Quantity of images to generate int
templates_path Path to directory containing base plate images string
templates_config Path to JSON configuration for each type of plate string
[Image]
resize_plate Apply resizing to the base plate images setting bool
plate_scales List of scaling factors to be used list
resize_bg Apply resizing to background images to a fixed size bool
bg_sizes List of target (width,height) pairs to resize bgs list
draw_bboxes Whether to draw bounding boxes (Use for testing only) bool
bbox_padding Spacing between bbox and inner object (px) int
[Perspective]
theta_range Maximum angle (degrees) to rotate plate over z-plane float
phi_range Maximum angle (degrees) to rotate plate over y-plane float
gamma_range Maximum angle (degrees) to rotate plate over x-plane float

templates.cfg

[Pending]

Authors

License

This project is licensed under the GNU General Public License v3.0 - see the LICENSE.md file for details

References

You can’t perform that action at this time.