From f25ea20ddc136981a77f91f2274e40b0a23828e3 Mon Sep 17 00:00:00 2001 From: stef Date: Sun, 11 Apr 2021 13:33:29 +0000 Subject: [PATCH 1/3] annotation mode on --- functions/app/main.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/functions/app/main.py b/functions/app/main.py index 6a6e762..028f18c 100644 --- a/functions/app/main.py +++ b/functions/app/main.py @@ -37,7 +37,7 @@ from google.protobuf import json_format # generate PNGs for each page and labeled CSV for annotation -ANNOTATION_MODE = False +ANNOTATION_MODE = True # AutoML Tables configs compute_region = "us-central1" From 8a487283dbeb145af6f51213303d84a05a7f43f2 Mon Sep 17 00:00:00 2001 From: stef Date: Sun, 11 Apr 2021 15:00:11 +0000 Subject: [PATCH 2/3] readme.md update --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index ba21b79..3acc229 100644 --- a/README.md +++ b/README.md @@ -19,4 +19,10 @@ Register the code with Cloud Functions the following command. You need to create - Annotation mode usage: to use pdf2audiobook for generating annotation data, set `ANNOTATION_MODE = True` and re-register the code with Cloud Funtions, so the tool will generate CSV files for annotation instead of mp3 files. - Annotation tool: use /apps-script code for running the annotation tool with Google Apps Script +1. Install Node.JS (version higher than 10.0.0) [Tutorial here](https://hackernoon.com/how-to-install-node-js-on-ubuntu-16-04-18-04-using-nvm-node-version-manager-668a7166b854 "hackernoon's Homepage") +2. Install Google clasp (`sudo npm install @google/clasp -g`) +3. Go to script.google.com, specifically [https://script.google.com/home/usersettings], +4. Enable Google App Scripts API (`gcloud services enable cloudapis.googleapis.com`) +5. Run `clasp login`, `clasp push` in the /apps-script directory + From 568ef108755a70bcdaab84f9b434087e24de9204 Mon Sep 17 00:00:00 2001 From: stef Date: Sun, 11 Apr 2021 15:59:12 +0000 Subject: [PATCH 3/3] deploy_all.sh --- deploy_all.sh | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100755 deploy_all.sh diff --git a/deploy_all.sh b/deploy_all.sh new file mode 100755 index 0000000..fa18853 --- /dev/null +++ b/deploy_all.sh @@ -0,0 +1,6 @@ +#!/bin/bash + +gcloud services enable cloudfunctions.googleapis.com +gcloud services enable vision.googleapis.com +gcloud services enable cloudapis.googleapis.com +gcloud services enable automl.googleapis.com