code: def get_analysis_intervals(data, vrn_file, base_dir):
      
      from bcbio.bam import callable
      if vrn_file and vcfutils.is_gvcf_file(vrn_file):
          callable_bed = _callable_from_gvcf(data, vrn_file, base_dir)
          if callable_bed:
              return callable_bed
  
      if data.get("ensemble_bed"):
          return data["ensemble_bed"]
      elif dd.get_sample_callable(data):
          return dd.get_sample_callable(data)
      elif data.get("align_bam"):
          return callable.sample_callable_bed(data["align_bam"], dd.get_ref_file(data), data)[0]
      elif data.get("work_bam"):
          return callable.sample_callable_bed(data["work_bam"], dd.get_ref_file(data), data)[0]
      elif data.get("work_bam_callable"):
          data = utils.deepish_copy(data)
          data["work_bam"] = data.pop("work_bam_callable")
          return callable.sample_callable_bed(data["work_bam"], dd.get_ref_file(data), data)[0]
      elif tz.get_in(["config", "algorithm", "callable_regions"], data):
          return tz.get_in(["config", "algorithm", "callable_regions"], data)
      elif tz.get_in(["config", "algorithm", "variant_regions"], data):
          return tz.get_in(["config", "algorithm", "variant_regions"], data)
docs: Retrieve analysis regions for the current variant calling pipeline.