We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
When running the tfdeploy model, I got this error
File "/home/sutony/git/facenet/src/align/tfdeploy.py", line 1838, in Max axis=tuple(reduction_indices) TypeError: 'numpy.int32' object is not iterable
It happens when the reduction_indices is an integer
#does not work when reduction_indices is an numpy integer (e.g., np.int32) tuple(reduction_indices)
I changed the code in Max() and Sum() to make the program runnable, but the code is not neat and I'm not sure if it works for other cases.
if not isinstance(reduction_indices, np.ndarray): return np.amax(a, axis=reduction_indices, keepdims=keep_dims), else: return np.amax(a, axis=tuple(reduction_indices), keepdims=keep_dims),
The other reduction functions might cause the same error.
The text was updated successfully, but these errors were encountered:
aead7cf
Thanks for reporting this.
The isinstance query cannot be avoided imho to ensure the interface between tf and np is working in all situations.
isinstance
Sorry, something went wrong.
No branches or pull requests
When running the tfdeploy model, I got this error
File "/home/sutony/git/facenet/src/align/tfdeploy.py", line 1838, in Max
axis=tuple(reduction_indices)
TypeError: 'numpy.int32' object is not iterable
It happens when the reduction_indices is an integer
I changed the code in Max() and Sum() to make the program runnable, but the code is not neat and I'm not sure if it works for other cases.
The other reduction functions might cause the same error.
The text was updated successfully, but these errors were encountered: