I have tried the following:
import numpy as np
a = np.array([[1,2,3],[4,5,6],[7,8,9],[10,11,12]])
print a
rows = a.shape[0]
cols = a.shape[1]
print rows
print cols
for x in range(0, cols - 1):
for y in range(0, rows -1):
print a[x,y]
This only prints the numbers 1 through 6.
I have also tried only subtracting 1 from either rows or cols in the range, but that either leads to an out-of-bounds error or not all numbers being printed.