title: split a numpy array both horizontally and vertically
body: <p>What is the most pythonic way of splitting a NumPy matrix (a 2-D array) into equal chunks both vertically and horizontally?</p>
  
  <p>For example :</p>
  
  <pre><code>aa = np.reshape(np.arange(270),(18,15)) # a 18x15 matrix
  </code></pre>
  
  <p>then a "function" like</p>
  
  <pre><code>ab = np.split2d(aa,(2,3))
  </code></pre>
  
  <p>would result in a list of 6 matrices shaped (9,5) each. The first guess is combine hsplit, map and vsplit, but how the mar has to be applied if there are two parameters to define for it, like :</p>
  
  <pre><code>map(np.vsplit(@,3),np.hsplit(aa,2))
  </code></pre>