Showing
1 changed file
with
1 additions
and
2 deletions
1 | - | ||
2 | var express = require("express"); | 1 | var express = require("express"); |
3 | var app = express(); | 2 | var app = express(); |
4 | const line = require('@line/bot-sdk'); | 3 | const line = require('@line/bot-sdk'); |
... | @@ -64,7 +63,7 @@ const visionclient = new vision.ImageAnnotatorClient(); | ... | @@ -64,7 +63,7 @@ const visionclient = new vision.ImageAnnotatorClient(); |
64 | // const fileName = 'Local image file, e.g. /path/to/image.png'; | 63 | // const fileName = 'Local image file, e.g. /path/to/image.png'; |
65 | 64 | ||
66 | // Performs text detection on the local file | 65 | // Performs text detection on the local file |
67 | -const [result] = await visionclient.textDetection('/home/ubuntu/a/LINEBOT/photo/Fancy-TWICE.jpg'); | 66 | +const [result] = visionclient.textDetection('/home/ubuntu/a/LINEBOT/photo/Fancy-TWICE.jpg'); |
68 | const detections = result.textAnnotations; | 67 | const detections = result.textAnnotations; |
69 | console.log('Text:'); | 68 | console.log('Text:'); |
70 | detections.forEach(text => console.log(text)); | 69 | detections.forEach(text => console.log(text)); | ... | ... |
-
Please register or login to post a comment