diff --git a/Dockerfile b/Dockerfile index 4d2b306..9431241 100644 --- a/Dockerfile +++ b/Dockerfile @@ -14,4 +14,4 @@ RUN cd /app \ WORKDIR /app -ENTRYPOINT ["sh", "entrypoint.sh"] \ No newline at end of file +CMD ["python3", "ocr_server.py", "--port", "9898", "--ocr", "--det"] \ No newline at end of file diff --git a/entrypoint.sh b/entrypoint.sh deleted file mode 100644 index 503363b..0000000 --- a/entrypoint.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -python3 ocr_server.py --port 9898 --ocr --det \ No newline at end of file diff --git a/test_api.py b/test_api.py index 1c06e12..3c38f4e 100644 --- a/test_api.py +++ b/test_api.py @@ -17,6 +17,8 @@ print(' ') # 目标检测就把ocr改成det,其他相同 # 方式一 file = open(r'test.jpg', 'rb').read() +# file = open(r'test_calc.png', 'rb').read() + api_url = f"{host}/ocr/file" resp = requests.post(api_url, files={'image': file}) diff --git a/test_calc.png b/test_calc.png new file mode 100644 index 0000000..08b7e1c Binary files /dev/null and b/test_calc.png differ