<h4 dir="auto">Description</h4>

<p dir="auto">Error in call of Scikit-Learn</p>
<h4 dir="auto">Steps/Code to Reproduce</h4>

<p dir="auto">Simple call of "import sklearn"</p>
<h4 dir="auto">Expected Results</h4>

<p dir="auto">Normal run</p>
<h4 dir="auto">Actual Results</h4>

<p dir="auto">Traceback (most recent call last):<br>
File "D:/code/python/hybrid3/borrar.py", line 5, in <br>
import sklearn; print("Scikit-Learn", sklearn.<strong>version</strong>)<br>
File "C:\Users\braun00r\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn_<em>init</em>_.py", line 57, in <br>
from .base import clone<br>
File "C:\Users\braun00r\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\base.py", line 12, in <br>
from .utils.fixes import signature<br>
File "C:\Users\braun00r\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\utils_<em>init</em>_.py", line 11, in <br>
from .validation import (as_float_array,<br>
File "C:\Users\braun00r\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\utils\validation.py", line 18, in <br>
from ..utils.fixes import signature<br>
File "C:\Users\braun00r\AppData\Local\Programs\Python\Python36\lib\site-packages\sklearn\utils\fixes.py", line 406, in <br>
if np_version &lt; (1, 12, 0):<br>
TypeError: '&lt;' not supported between instances of 'str' and 'int'</p>
<h4 dir="auto">Versions</h4>

<p dir="auto">Windows-7-6.1.7601-SP1<br>
Python 3.6.0 (v3.6.0:41df79263a11, Dec 23 2016, 08:06:12) [MSC v.1900 64 bit (AMD64)]<br>
NumPy 1.12.1rc1<br>
SciPy 0.19.0</p>
<p dir="auto">There is a new bug in master brunch, <code class="notranslate">scikit-learn/sklearn/utils/fixes.py</code><br>
in line 406: <code class="notranslate">if np_version &lt; (1, 12, 0):</code> , an error occured, <code class="notranslate">TypeError: unorderable types: str() &lt; int()</code>.<br>
It's because in the function :</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="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)"><pre class="notranslate"><code class="notranslate">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)
</code></pre></div>
<p dir="auto">However， my numpy version is：<code class="notranslate">1.12.0b1</code>, this funciotn return a tuple(1,12,'0b1') , but in line 406, It is compared with integer type, so the error occured.<br>
I just in a simple way to solve it. I change the code to <code class="notranslate">if np_version &lt; (1, 12, '0'):</code> in line 406, just change the third tuple index to string type.<br>
Of course, this is not a common method.</p>