Skip to content

ibrahimhabibeg/receipt-understanding

Repository files navigation

Building a Receipt Understanding Model

This repository provides a step-by-step guide to building a receipt understanding model using LayoutLMv3, a powerful pre-trained model designed for document understanding tasks.

Notebooks

  • Building a Receipt Understanding Model.ipynb: This comprehensive notebook delves into the full process of building the model, including:

    • Understanding the model architecture and its components
    • Preprocessing the data for training
    • Fine-tuning the model on the SROIE dataset
    • Using the Receipt Understanding model
  • Building a Receipt Understanding Model Summarized.ipynb: This simplified version focuses on the core concepts and functionality of the model, skipping the preprocessing and fine-tuning details for easier exploration. Note: This notebook requires the preprocessed data and trained model generated by the Finetuning.ipynb and Preprocessing.ipynb notebooks.

  • Finetuning.ipynb: This notebook provides a dedicated look at the fine-tuning process on the SROIE dataset.

  • Preprocessing.ipynb: This notebook focuses on the image and text preprocessing techniques used for training the model.

PDFs

The pdfs folder contains all the notebooks in PDF format for easy offline access.

Getting Started

The notebooks in this repository can be run in Google Colab or locally on your machine.

To use the notebooks in the repository, you can open them in GitHub, copy the link to the notebook, and paste it into Google Colab. This will allow you to run the code and experiment with the model without any setup required.

You can also download the notebooks and run them locally on your machine. To do this, you will need to install the required libraries using the following command.

Contributing

We welcome contributions to this project! If you have any suggestions, improvements, or bug fixes, feel free to create a pull request.