code: def _setdiff2d(A, B):
      """Utility function equivalent to numpy.setdiff1d on 2d arrays.
  
      Parameters
      ----------
  
      A : ndarray, shape [n, m]
  
      B : ndarray, shape [n, m]
  
      Returns
      -------
      subset_A : np.array, shape [k, m]
          Rows of A that are not in B.
  
      """
  
      if len(A.shape) != 2 or len(B.shape) != 2:
          raise RuntimeError("Input arrays must be 2-dimensional.")
  
      tmp = np.prod(np.swapaxes(A[:, :, None], 1, 2) == B, axis=2)
      return A[
          ~np.sum(np.cumsum(tmp, axis=0) * tmp == 1, axis=1).astype(
              bool
          )
      ]
  
file_path: AmpliGraph/ampligraph/discovery/discovery.py
imports: import logging
  import networkx
  import numpy
  from scipy import optimize, spatial
  from sklearn.cluster import DBSCAN
  from sklearn.neighbors import NearestNeighbors
label_desc: Use image node_id 3 for calling a global function with example usage: _setdiff2d(A, B) and returns: A