code: def calculate_include_paths(targets, is_thrift_target):
    
  
    basedirs = set()
    def collect_paths(target):
      basedirs.add(target.target_base)
  
    for target in targets:
      target.walk(collect_paths, predicate=is_thrift_target)
    return basedirs
docs: Calculates the set of import paths for the given targets.
  
    :targets: The targets to examine.
    :is_thrift_target: A predicate to pick out thrift targets for consideration in the analysis.
  
    :returns: Include basedirs for the target.