Commit 167e59c2 authored by wuzekai's avatar wuzekai

Update ocr.py

parent a02485a6
Pipeline #570 canceled with stages
......@@ -23,4 +23,8 @@ os.makedirs(result_dir, exist_ok=True)
@ocr.route("/process", methods=["POST"])
def ocr_inference():
if "file" not in request.files:
return jsonify({"error": "No file provided"}), 400
\ No newline at end of file
return jsonify({"error": "No file provided"}), 400
file = request.files["file"]
if file.filename == "":
return jsonify({"error": "No selected file"}), 400
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment