Skip to content

Instantly share code, notes, and snippets.

@vaibhavgehani
Created July 26, 2020 17:19
Show Gist options
  • Select an option

  • Save vaibhavgehani/687bfc6660d1a3721bc332bd9cba03ab to your computer and use it in GitHub Desktop.

Select an option

Save vaibhavgehani/687bfc6660d1a3721bc332bd9cba03ab to your computer and use it in GitHub Desktop.
@app.route('/getText',methods=['POST'])
def getText():
file=request.files['file']
text = ocr_extraction(file)
# print(type(text))
sentiment = predictSentiment(text)
print(sentiment)
return jsonify(outputText=text,predSentiment=sentiment)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment