Skip to content
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

Type error #4

Open
Clamps251 opened this issue Sep 20, 2018 · 5 comments
Open

Type error #4

Clamps251 opened this issue Sep 20, 2018 · 5 comments

Comments

@Clamps251
Copy link

Hi,

I am getting the following error when i navigate to either /local or /video:

server.py", line 61, in image print('POST /image error: %e' % e)
TypeError: must be real number, not RuntimeError

Has anyone come across this issue?

Thanks for any help :)

@chadwallacehart
Copy link
Member

I would try changing that line to just print(e) and see what happens.

@Clamps251
Copy link
Author

Hi,

Thanks for getting back to me. I have tried it and now it says typeerror: a float is required.

@AmitKKhanchandani
Copy link

Any Solution to this?

@AmitKKhanchandani
Copy link

AmitKKhanchandani commented Dec 14, 2018

@chadwallacehart

I would try changing that line to just print(e) and see what happens.

Traceback (most recent call last):
  File "C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\flask\app.py", line 2309, in __call__
    return self.wsgi_app(environ, start_response)
  File "C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\flask\app.py", line 2295, in wsgi_app
    response = self.handle_exception(e)
  File "C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\flask\app.py", line 1741, in handle_exception
    reraise(exc_type, exc_value, tb)
  File "C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\flask\_compat.py", line 35, in reraise
    raise value
  File "C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\flask\app.py", line 2292, in wsgi_app
    response = self.full_dispatch_request()
  File "C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\flask\app.py", line 1815, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\flask\app.py", line 1718, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\flask\_compat.py", line 35, in reraise
    raise value
  File "C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\flask\app.py", line 1813, in full_dispatch_request
    rv = self.dispatch_request()
  File "C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\flask\app.py", line 1799, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "C:\laragon\www\temp\tfObjWebrtc\server.py", line 61, in image
    print('POST /image error: %e' % e)
TypeError: a float is required

any idea how to fix this?

Specs:
Tensorflow: 1.12.0
Python 3.5 using Anaconda

@chadwallacehart
Copy link
Member

Sorry, I haven't worked with this project for a while.

I think that %e should be a %s on line 61 or it should be changed to print('POST /image error: ', e) . However, if that is occurring you are still getting an exception so there is still some issue. At least if you can see the error that might tell you what to look at next.

I guess you are not running this inside the docker container?
docker run -it -p 5000:5000 chadhart/tensorflow-object-detection:runserver

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants