code: def _get_resource_programs(progs, algs):
      
      checks = {"gatk-vqsr": config_utils.use_vqsr,
                "snpeff": config_utils.use_snpeff,
                "bcbio-variation-recall": config_utils.use_bcbio_variation_recall}
      parent_child = {"vardict": _parent_prefix("vardict")}
      out = set([])
      for p in progs:
          if p == "aligner":
              for alg in algs:
                  aligner = alg.get("aligner")
                  if aligner and not isinstance(aligner, bool):
                      out.add(aligner)
          elif p in ["variantcaller", "svcaller", "peakcaller"]:
              if p == "variantcaller":
                  for key, fn in parent_child.items():
                      if fn(algs):
                          out.add(key)
              for alg in algs:
                  callers = alg.get(p)
                  if callers and not isinstance(callers, bool):
                      if isinstance(callers, dict):
                          callers = reduce(operator.add, callers.values())
                      if isinstance(callers, (list, tuple)):
                          for x in callers:
                              out.add(x)
                      else:
                          out.add(callers)
          elif p in checks:
              if checks[p](algs):
                  out.add(p)
          else:
              out.add(p)
      return sorted(list(out))
docs: Retrieve programs used in analysis based on algorithm configurations.
      Handles special cases like aligners and variant callers.