title: Removing duplicate columns and rows from a NumPy  2D array
body: <p>I'm using a 2D shape array to store pairs of longitudes+latitudes. At one point, I have to merge two of these 2D arrays, and then remove any duplicated entry. I've been searching for a function similar to numpy.unique, but I've had no luck. Any implementation I've been
  thinking on looks very "unoptimizied". For example, I'm trying with converting the array to a list of tuples, removing duplicates with set, and then converting to an array again:</p>
  
  <pre><code>coordskeys = np.array(list(set([tuple(x) for x in coordskeys])))
  </code></pre>
  
  <p>Are there any existing solutions, so I do not reinvent the wheel?</p>
  
  <p>To make it clear, I'm looking for:</p>
  
  <pre><code>&gt;&gt;&gt; a = np.array([[1, 1], [2, 3], [1, 1], [5, 4], [2, 3]])
  &gt;&gt;&gt; unique_rows(a)
  array([[1, 1], [2, 3],[5, 4]])
  </code></pre>
  
  <p>BTW, I wanted to use just a list of tuples for it, but the lists were so big that they consumed my 4Gb RAM + 4Gb swap (numpy arrays are more memory efficient).</p>