title: Comparing two methods to get the same array
body: <pre><code>    np.random.seed(123456)
      X = np.random.normal(0,1,1000)
      Y = np.random.normal(0,1,1000)
      Z = np.random.normal(0.5, 1.7,1000)
      W = np.random.normal(0,1,1000)
      stream_A = np.concatenate((X,Y,Z,W))
  </code></pre>
  <p>Then I am running the code below: Basically I need to create a iterator to feed one sample at a time to another function.</p>
  <pre><code>    # 4 chunks of 1000 samples, so X,Y,W and Z arrays
      n = 4 
      iter_array = iter(stream_A) # Size 4000
      result = [[] for _ in range(n)]
      for _ in itertools.repeat(None, 1000):
          for i in range(n):
              result[i].append(next(iter_array))
  </code></pre>
  <p>The problem is:</p>
  <p><code>results[0]</code> is a list with all elements of stream X defined above.</p>
  <p>If a compare <code>results[0] == X</code>  I get <code>false</code></p>
  <p>If I transform the list into np.array:</p>
  <pre><code>y=np.array([np.array(xi) for xi in result], dtype=object)
  </code></pre>
  <p>and then:</p>
  <p><code>y[0] == X</code> I also get <code>false</code></p>
  <p>Can someone help me why I am getting False?</p>
  <p>And they are somehow not same because the results I am getting when I apply <code>X</code> to the function is not the same of them result when I apply <code>y[0]</code> to the same function.</p>