code: def gather_files(path: str, patterns: list, antipatterns: list):
      """
      Gather files, based on `path`, that match `patterns` unix-like specification
      and do not match `antipatterns` regexes
      """
      curr_path = os.getcwd()
      os.chdir(path)
      positive_iterators = [
          glob.iglob(os.path.join("**", pattern), recursive=True)
          for pattern in patterns
      ]
      linted_files = itertools.chain(*positive_iterators)
      linted_files = (os.path.join(path, file) for file in linted_files)
      linted_files = negative_filtering(
          antipatterns.copy(), linted_files
      )
      ret = list(linted_files)
      os.chdir(curr_path)
      return ret
  
file_path: DALI/tools/lint.py
imports: import os
  import glob
  import itertools
  import re
  import argparse
  import sys
  import subprocess
label_desc: Use image node_id 2 for calling a global function with example usage: gather_files(path, patterns, antipatterns) and returns: ret