Skip to content

Commit

Permalink
change default m and c for skani to even lower values based on experi…
Browse files Browse the repository at this point in the history
…mentation on rhino/entero genomes
  • Loading branch information
dpark01 committed Mar 28, 2024
1 parent f88c8f9 commit 3045822
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions assembly.py
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@ def parser_gapfill_gap2seq(parser=argparse.ArgumentParser(description='Close gap
__commands__.append(('gapfill_gap2seq', parser_gapfill_gap2seq))


def cluster_references_ani(inRefs, outClusters, m=50, s=50, c=20, min_af=15, threads=None):
def cluster_references_ani(inRefs, outClusters, m=15, s=50, c=10, min_af=15, threads=None):
''' This step uses the skani triangle tool to define clusters of highly-related genomes.
'''
skani = assemble.skani.SkaniTool()
Expand All @@ -391,9 +391,9 @@ def cluster_references_ani(inRefs, outClusters, m=50, s=50, c=20, min_af=15, thr
def parser_cluster_references_ani(parser=argparse.ArgumentParser(description='Cluster references')):
parser.add_argument('inRefs', nargs='+', help='FASTA files containing reference genomes')
parser.add_argument('outClusters', help='Output file containing clusters of highly-related genomes. Each line contains the filenames of the genomes in one cluster.')
parser.add_argument('-m', type=int, default=50, help='marker k-mer compression factor (default: %(default)s)')
parser.add_argument('-m', type=int, default=15, help='marker k-mer compression factor (default: %(default)s)')
parser.add_argument('-s', type=int, default=50, help='screen out pairs with < percent identity using k-mer sketching (default: %(default)s)')
parser.add_argument('-c', type=int, default=20, help='compression factor (k-mer subsampling ratio) (default: %(default)s)')
parser.add_argument('-c', type=int, default=10, help='compression factor (k-mer subsampling ratio) (default: %(default)s)')
parser.add_argument('--min_af', dest='min_af', type=int, default=15, help='minimum alignment fraction (default: %(default)s)')
util.cmd.common_args(parser, (('threads', None), ('loglevel', None), ('version', None), ('tmp_dir', None)))
util.cmd.attach_main(parser, cluster_references_ani, split_args=True)
Expand All @@ -402,7 +402,7 @@ def parser_cluster_references_ani(parser=argparse.ArgumentParser(description='Cl
__commands__.append(('cluster_references_ani', parser_cluster_references_ani))


def skani_contigs_to_refs(inContigs, inRefs, out_skani_dist, out_skani_dist_filtered, out_clusters_filtered, m=50, s=50, c=20, min_af=15, threads=None):
def skani_contigs_to_refs(inContigs, inRefs, out_skani_dist, out_skani_dist_filtered, out_clusters_filtered, m=15, s=50, c=10, min_af=15, threads=None):

skani = assemble.skani.SkaniTool()
clusters = skani.find_reference_clusters(inRefs, m=m, s=s, c=c, min_af=min_af, threads=threads)
Expand Down Expand Up @@ -436,9 +436,9 @@ def parser_skani_contigs_to_refs(parser=argparse.ArgumentParser(description='Fin
parser.add_argument('out_skani_dist', help='Output file containing ANI distances between contigs and references')
parser.add_argument('out_skani_dist_filtered', help='Output file containing ANI distances between contigs and references, with only the top reference hit per cluster')
parser.add_argument('out_clusters_filtered', help='Output file containing clusters of highly-related genomes, with only clusters that have a hit to the contigs')
parser.add_argument('-m', type=int, default=50, help='marker k-mer compression factor (default: %(default)s)')
parser.add_argument('-m', type=int, default=15, help='marker k-mer compression factor (default: %(default)s)')
parser.add_argument('-s', type=int, default=50, help='screen out pairs with < percent identity using k-mer sketching (default: %(default)s)')
parser.add_argument('-c', type=int, default=20, help='compression factor (k-mer subsampling ratio) (default: %(default)s)')
parser.add_argument('-c', type=int, default=10, help='compression factor (k-mer subsampling ratio) (default: %(default)s)')
parser.add_argument('--min_af', dest='min_af', type=int, default=15, help='minimum alignment fraction (default: %(default)s)')
util.cmd.common_args(parser, (('threads', None), ('loglevel', None), ('version', None), ('tmp_dir', None)))
util.cmd.attach_main(parser, skani_contigs_to_refs, split_args=True)
Expand Down

0 comments on commit 3045822

Please sign in to comment.