code: def column_needs_resampling(i, X, Y=None):
      # column i of X needs resampling if either
      # it is parallel to a previous column of X or
      # it is parallel to a column of Y
      n, t = X.shape
      v = X[:, i]
      if any(vectors_are_parallel(v, X[:, j]) for j in range(i)):
          return True
      if Y is not None:
          if any(vectors_are_parallel(v, w) for w in Y.T):
              return True
      return False
  
file_path: scipy/scipy/sparse/linalg/_onenormest.py
imports: import numpy
  from scipy.sparse.linalg import aslinearoperator
label_desc: Use image node_id 9 for calling a global function with example usage: column_needs_resampling(i, X, Y) and returns: False, True, True