code: def facetintervalrecordlookup(table, key, start='start', stop='stop',
                                include_stop=False):
      
  
      trees = facetrecordtrees(table, key, start=start, stop=stop)
      out = dict()
      for k in trees:
          out[k] = IntervalTreeLookup(trees[k], include_stop=include_stop)
      return out
docs: As :func:`petl.transform.intervals.facetintervallookup` but return records.