code: def getfiledata(directories):
      columns = None
      data = []
      counter = 1
      for directory in directories:
          for f in os.listdir(directory):
              if not os.path.isfile(os.path.join(directory, f)):
                  continue
              counter += 1
              st = os.stat(os.path.join(directory, f))
              if columns is None:
                  columns = ["rowid", "name", "directory"] + [
                      x for x in dir(st) if x.startswith("st_")
                  ]
              data.append(
                  [counter, f, directory]
                  + [getattr(st, x) for x in columns[3:]]
              )
      return columns, data
  
imports: from __future__ import print_function
  import sys
  import os
  import time
  import apsw
  import random
label_desc: Use image node_id 11 for calling a global function with example usage: getfiledata(directories) and returns: columns,  data