Skip to main content

Q&A Python and OpenCV OMR (optical mark recognition)

Project description


This package can create a form which can be read in with OMR and can read those forms.


Creating an OMR form

To create an OMR enabled form you must make a form (with Word, LaTeX or similar software) and mark the first bullet points with a red background and the last with a green background. At last the corners should be marked: the bottom right corner must be marked with a black square and the three other corners with a QR code like corner. At this moment the user must do this themselfes (this may change in the future). The imput to OMR must be an image file. An empty OMR form

Running the following will generate a printable output sheet with barcodes at the bottom which OMR uses to detect the settings

qandaomr -c input_file output_file columns rows points_per_question questions_per_block

Created omr form

Reading an OMR form

To get the answers back from the form a scanned image can be the input to OMR. OMR will print the answers to the terminal in a CSV format.

qandaomr -r input_file

Generating intermediate files

For debug purposes the -d flag can be used. This will generate multiple images which are used in the steps within OMR. This can be useful if OMR does not react the way it should


To install this package clone this repository and install via pip:

pip install qandaomr

Uninstalling can be done via pip:

pip uninstall qandaomr

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

qandaomr-1.2.3.post1.tar.gz (6.8 kB view hashes)

Uploaded source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page