-
Notifications
You must be signed in to change notification settings - Fork 45.7k
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
NameError: name 'unicode' is not defined in object_detection/utils/object_detection_evaluation.py #5203
Comments
@jillelajitta It's better to ask this question on StackOverflow. Adding more class increase the conv nodes in detection head, so it should be slower. |
anyone solute the problem? i am not |
@kunerer As mentioned by pkulzc, You need to replace the unicode by string in the particular line of code mentioned in the error. |
Python 3 renamed the unicode type to str, the old str type has been replaced by bytes |
Write for Python3 |
just replace unicode(category_name, 'utf-8') to str(category_name.encode('utf-8')) everywhere in the document. |
@pkulzc I ran the legacy/eval.py and the error shows up NameError: name 'unicode' is not defined in object_detection/utils/object_detection_evaluation.py, line 332
The Python3 doesn't have the type unicode anymore and it has been renamed to str.
Is there any better way to avoid this error?
Most people work in Python 3, it's great to be compatible with python 3.
The text was updated successfully, but these errors were encountered: