Extracting email addresses from an actual paper list with Google Vision API

Step 1: Scan the papers

Step 2: Get your tools

sudo apt-get install cmake libpoppler-cpp-dev python-poppler
git clone git@github.com:erwan-lemonnier/pdf2emails.git
cd pdf2emails
pip install -r requirements.txt

Step 3: Setup your google cloud credentials

{
"auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs",
"auth_uri": "https://accounts.google.com/o/oauth2/auth",
"client_email": <your google client email>,
"client_id": <your google client id>,
"client_x509_cert_url": <your cert url>,
"private_key": <your private key>,
"private_key_id": <your private key id>,
"project_id": <your google cloud project name>,
"token_uri": "https://oauth2.googleapis.com/token",
"type": "service_account"
}

Step 4: Run pdf2emails

python pdf2emails.py \
--gcloud-json-cred <path to json creds> \
--bucket-name <name of your storage bucket> \
--pdf my.pdf | grep '@' > list.csv

So how does it work?

CTO at GoFrendly. Fullstack developer turned entrepreneur. Ex-employee of Spotify and Trustly. Author of the PyMacaron microservice framework.

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Toast Notification Configurations

Monthly Dev Update — February 2021

Must Read: Why Choose the Best Joomla Hosting

END to END Automation of Website hosting in AWS using Terraform.

What is the Meaning of the Direction of the Relationship in Power BI?

Paint House Problem

Photo by bruce mars on Unsplash

The Latest Features of DataWorks: How to Choose the Right Edition of DataWorks

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Erwan Lemonnier

Erwan Lemonnier

CTO at GoFrendly. Fullstack developer turned entrepreneur. Ex-employee of Spotify and Trustly. Author of the PyMacaron microservice framework.

More from Medium

AWS — Elastic Load Balancer (ELB) Overview

Optimise Costs And Build A Secure Cloud Platform With AWS Cost and Security Optimisation Clinics

Leon Golub — Figuration and Monsters

SAML Authentication with Apache Guacamole 1.4