def index(uuid, analysis_ready_bam_list_path, engine, logger):
  with open (analysis_ready_bam_list_path) as f:
    analysis_ready_bam_path = f.read().splitlines()
    for path in analysis_ready_bam_path:
      analysis_ready_bai_path = path + '.bai'
      if os.path.isfile(analysis_ready_bai_path):
        logger.info('analysis_ready_bai_path=%s' % analysis_ready_bai_path)
      else:
        analysis_ready_bai_path = bam_util.samtools_bam_index(uuid, path, engine, logger)
def index(uuid, harmonized_bam_list_path, engine, logger):
  with open(harmonized_bam_list_path) as f:
    harmonized_bam_path = f.read().splitlines()
    for path in harmonized_bam_path:
      harmonized_bai_path = path + '.bai'
      if os.path.isfile(harmonized_bai_path):
        logger.info('harmonized_bai_path=%s' % harmonized_bai_path)
      else:
        harmonized_bai_path = bam_util.samtools_bam_index(uuid, path, engine, logger)