Member-only story
Text detection (OCR) and Language identification using Google Cloud Vision API
In this post , we are going to see how to use google cloud computer vision api to detect texts in an image (Object character recognition) and identify the language type.
To start , first enable the cloud vision api in the google cloud console or via the gcloud command.
gcloud services enable vision.googleapis.com
Next, create a service account with “AI platform admin” permissions.
Create a json key for this service account.
Now you can create a jupyter notebook in your local machine or you can create notebook in Google cloud AI platform . ( Please note that creating a python notebook instance in GCP will incur costs).
- Pip install the langcodes package , langcodes implements BCP 47, the IETF Best Current Practices on tags for identifying Languages.
- Import the required libraries
- Visualize the images with text