title: Converting list to numpy array
body: <p>I have managed to load images in a folder using the command line sklearn: <code>load_sample_images()</code></p>
  
  <p>I would now like to convert it to a <code>numpy.ndarray</code> format with <code>float32</code> datatype</p>
  
  <p>I was able to convert it to <code>np.ndarray</code> using : <code>np.array(X)</code>, however <code>np.array(X, dtype=np.float32)</code> and <code>np.asarray(X).astype('float32')</code> give me the error:</p>
  
  <blockquote>
  <pre><code>ValueError: setting an array element with a sequence.
  </code></pre>
  </blockquote>
  
  <p>Is there a way to work around this?</p>
  
  <pre><code>from sklearn_theano.datasets import load_sample_images
  import numpy as np  
  
  kinect_images = load_sample_images()
  X = kinect_images.images
  
  X_new = np.array(X)  # works
  X_new = np.array(X[1], dtype=np.float32)  # works
  
  X_new = np.array(X, dtype=np.float32)  # does not work
  </code></pre>