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

TypeError: int() argument must be a string, a bytes-like object or a number, not 'DType' #63

Open
Single430 opened this issue Aug 1, 2019 · 2 comments

Comments

@Single430
Copy link

Single430 commented Aug 1, 2019

Error

File "./gen_client/gen_client.py", line 76, in gen_tensorflow_client
    if dtype == int(tf.int8) or dtype == int(tf.uint8) or dtype == int(

TypeError: int() argument must be a string, a bytes-like object or a number, not 'DType'

change

dtype = input_opname_dtype_map[opname]
if dtype in [6, 4, 5, 17, 3, 22]:
    default_value = 1
elif dtype in [9, 23]:
    default_value = 1
elif dtype in [3]:
    default_value = True
elif dtype in [7]:
    default_value = ""
# if dtype == int(tf.int8) or dtype == int(tf.uint8) or dtype == int(
#     tf.int16) or dtype == int(tf.uint16) or dtype == int(
#         tf.int32) or dtype == int(tf.uint32):
#   default_value = 1
# elif dtype == int(tf.int64) or dtype == int(tf.uint64):
#   default_value = 1
# elif dtype == int(tf.int32):
#   default_value = True
# elif dtype == int(tf.string):
#   default_value = ""

result

  • is run
@GaoQ1
Copy link

GaoQ1 commented Sep 25, 2019

i met the same problem. and didn't generate client.py file

@Single430
Copy link
Author

@GaoQ1 file path is: simple_tensorflow_serving/gen_client/gen_client.py

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

2 participants