Code Monkey home page Code Monkey logo

serverless-ktp-ocr's Introduction

CodeFactor

Serverless Indonesian KTP OCR with GCP

This is reproducible work from Ekstraksi Informasi e-KTP dengan Google Cloud Function dan Cloud Vision API. It also contains code fix to match with ES6 compliant module usages.

KTP OCR Architecture

Alt text

Pre-requisites

  1. Google Cloud Account
  2. gcloud CLI
  3. Create New Google Cloud project gcloud projects create ektp-ocr
  4. Enable Google Cloud Functions gcloud services enable cloudfunctions.googleapis.com
  5. Enable Google Cloud Storage gcloud services enable storage-api.googleapis.com gcloud services enable storage-component.googleapis.com, create bucket name uploaded_ktp
  6. Enable Google Cloud PubSub gcloud services enable pubsub.googleapis.com, create topic name ektp-text-extracted
  7. Enable Google Cloud Vision this link

How to deploy

  1. Deploy HTTP
$ cd http-ktp
$ npm i
$ gcloud functions deploy http-ktp --entry-point uploadKtp --trigger-http
  1. Deploy KTP Image Event Trigger
$ cd ktp-iamge-event-trigger
$ npm i
$ gcloud functions deploy processImageFromGCSEvent --trigger-resource uploaded_ektp --trigger-event google.storage.object.finalize
  1. Deploy Extraction Data
$ gcloud functions deploy extract_ktp --runtime python37 --trigger-topic ektp-text-extracted

Results

View Stackdriver logs from extract-ktp function.

Love it?

Please support me by *stars this Github repo. Thank you!

serverless-ktp-ocr's People

Contributors

rhzs avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.