title: numpy.loadtxt, converters error
body: <p>I am trying to read CSV's type file. And it conclude a dates line.
  I write the code like this, as others teach me, but it is wrong.
  I don't know why. please help me.</p>
  
  <pre><code>from matplotlib.dates import strpdate2num
  import matplotlib.pyplot as plt
  import pandas as pd
  import numpy as np
  import os
  dates=np.loadtxt('data.csv',delimiter=',',usecols=(1,),
                   converters={ 1:strpdate2num('%d-%m-%Y')})
  </code></pre>
  
  <p>and the error information as below:</p>
  
  <pre><code>---------------------------------------------------------------------------
  TypeError                                 Traceback (most recent call last)
  &lt;ipython-input-24-e58dd0485173&gt; in &lt;module&gt;()
        1 dates=np.loadtxt('data.csv',delimiter=',',usecols=(1,),
  ----&gt; 2                  converters={ 1:strpdate2num('%d-%m-%Y')})
  
  C:\Anaconda3\lib\site-packages\numpy\lib\npyio.py in loadtxt(fname, dtype, comments, delimiter, converters, skiprows, usecols, unpack, ndmin)
      928 
      929             # Convert each value according to its column and store
  --&gt; 930             items = [conv(val) for (conv, val) in zip(converters, vals)]
      931             # Then pack it according to the dtype's nesting
      932             items = pack_items(items, packing)
  
  C:\Anaconda3\lib\site-packages\numpy\lib\npyio.py in &lt;listcomp&gt;(.0)
      928 
      929             # Convert each value according to its column and store
  --&gt; 930             items = [conv(val) for (conv, val) in zip(converters, vals)]
      931             # Then pack it according to the dtype's nesting
      932             items = pack_items(items, packing)
  
  C:\Anaconda3\lib\site-packages\matplotlib\dates.py in __call__(self, s)
      285            return value: a date2num float
      286         """
  --&gt; 287         return date2num(datetime.datetime(*time.strptime(s, self.fmt)[:6]))
      288 
      289 
  
  C:\Anaconda3\lib\_strptime.py in _strptime_time(data_string, format)
      557     """Return a time struct based on the input string and the
      558     format string."""
  --&gt; 559     tt = _strptime(data_string, format)[0]
      560     return time.struct_time(tt[:time._STRUCT_TM_ITEMS])
      561 
  
  C:\Anaconda3\lib\_strptime.py in _strptime(data_string, format)
      327         if not isinstance(arg, str):
      328             msg = "strptime() argument {} must be str, not {}"
  --&gt; 329             raise TypeError(msg.format(index, type(arg)))
      330 
      331     global _TimeRE_cache, _regex_cache
  
  TypeError: strptime() argument 0 must be str, not &lt;class 'bytes'&gt;
  </code></pre>