-
Notifications
You must be signed in to change notification settings - Fork 191
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Image inference error #47
Comments
@NorthLatitudeOne i got a similar error |
sorry ,correct my above code, I just used below code to convert local jpg to base64, and then used the base64 in postman (post body) with open("./mew.jpg", "rb") as image_file: comments: if I use base64.urlsafe_b64encode to encode, it will raise another error |
Hi @serlina , it depends on your TensorFlow SavedModel's op. If you use
|
Hi, can somebody help to have a look my problem, thanks!
Image inference in web menu test image inference:
Predict result: [{"error": "Inference error <class 'KeyError'>: 'input_image'"}, 400]
Image inference in command line:
<title>500 Internal Server Error</title>`E:\Anaconda\Lib\site-packages\simple_tensorflow_serving>curl -X POST -F 'image=images/NG0093.jpg' -F "model_version=3" 127.0.0.1:8500
Internal Server Error
The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there is an error in the application.
`Simple tensorflow serving log:
2019-04-18 09:00:46 ERROR Need to set image or images for form-data 2019-04-18 09:00:46 ERROR Exception on / [POST] Traceback (most recent call last): File "e:\anaconda\lib\site-packages\flask\app.py", line 2292, in wsgi_app response = self.full_dispatch_request() File "e:\anaconda\lib\site-packages\flask\app.py", line 1815, in full_dispatch_request rv = self.handle_user_exception(e) File "e:\anaconda\lib\site-packages\flask_cors\extension.py", line 161, in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) File "e:\anaconda\lib\site-packages\flask\app.py", line 1718, in handle_user_exception reraise(exc_type, exc_value, tb) File "e:\anaconda\lib\site-packages\flask\_compat.py", line 35, in reraise raise value File "e:\anaconda\lib\site-packages\flask\app.py", line 1813, in full_dispatch_request rv = self.dispatch_request() File "e:\anaconda\lib\site-packages\flask\app.py", line 1799, in dispatch_request return self.view_functions[rule.endpoint](**req.view_args) File "e:\anaconda\lib\site-packages\simple_tensorflow_serving\server.py", line 184, in decorated return f(*decorator_args, **decorator_kwargs) File "e:\anaconda\lib\site-packages\simple_tensorflow_serving\server.py", line 308, in inference json_result, status_code = do_inference() File "e:\anaconda\lib\site-packages\simple_tensorflow_serving\server.py", line 349, in do_inference if "model_name" in json_data: TypeError: argument of type 'NoneType' is not iterable 2019-04-18 09:00:46 INFO 127.0.0.1 - - [18/Apr/2019 09:00:46] "�[1m�[35mPOST / HTTP/1.1�[0m" 500 -
The text was updated successfully, but these errors were encountered: