-
-
Notifications
You must be signed in to change notification settings - Fork 26.2k
Closed
Description
There is a new bug in master brunch, scikit-learn/sklearn/utils/fixes.py
in line 406: if np_version < (1, 12, 0):
, an error occured, TypeError: unorderable types: str() < int()
.
It's because in the function :
def _parse_version(version_string):
version = []
for x in version_string.split('.'):
try:
version.append(int(x))
except ValueError:
# x may be of the form dev-1ea1592
version.append(x)
return tuple(version)
However, my numpy version is:1.12.0b1
, this funciotn return a tuple(1,12,'0b1') , but in line 406, It is compared with integer type, so the error occured.
I just in a simple way to solve it. I change the code to if np_version < (1, 12, '0'):
in line 406, just change the third tuple index to string type.
Of course, this is not a common method.
naoko
Metadata
Metadata
Assignees
Labels
No labels