Skip to content

Commit

Permalink
run black
Browse files Browse the repository at this point in the history
  • Loading branch information
tanghaibao committed May 1, 2024
1 parent f6a14cf commit 37e4bd7
Show file tree
Hide file tree
Showing 11 changed files with 15 additions and 45 deletions.
4 changes: 1 addition & 3 deletions jcvi/apps/align.py
Original file line number Diff line number Diff line change
Expand Up @@ -216,9 +216,7 @@ def nucmer(args):
from jcvi.formats.base import split

p = OptionParser(nucmer.__doc__)
p.add_option(
"--chunks", type=int, help="Split both query and subject into chunks"
)
p.add_option("--chunks", type=int, help="Split both query and subject into chunks")
p.set_params(prog="nucmer", params="-l 100 -c 500")
p.set_cpus()
opts, args = p.parse_args(args)
Expand Down
4 changes: 1 addition & 3 deletions jcvi/apps/uclust.py
Original file line number Diff line number Diff line change
Expand Up @@ -556,9 +556,7 @@ def consensus(args):
errors according to error rate, calls consensus.
"""
p = OptionParser(consensus.__doc__)
p.add_option(
"--ploidy", default=2, type=int, help="Number of haplotypes per locus"
)
p.add_option("--ploidy", default=2, type=int, help="Number of haplotypes per locus")
add_consensus_options(p)
p.set_verbose()
opts, args = p.parse_args(args)
Expand Down
12 changes: 3 additions & 9 deletions jcvi/assembly/allmaps.py
Original file line number Diff line number Diff line change
Expand Up @@ -1395,12 +1395,8 @@ def path(args):
)
p.add_option("--seqid", help="Only run partition with this seqid")
p.add_option("--partitions", help="Use predefined partitions of LGs")
p.add_option(
"--links", default=10, type=int, help="Only plot matchings more than"
)
p.add_option(
"--mincount", default=1, type=int, help="Minimum markers on a contig"
)
p.add_option("--links", default=10, type=int, help="Only plot matchings more than")
p.add_option("--mincount", default=1, type=int, help="Minimum markers on a contig")
p.add_option(
"--noplot",
default=False,
Expand Down Expand Up @@ -1783,9 +1779,7 @@ def add_allmaps_plot_options(p):
choices=distance_choices,
help="Plot markers based on distance",
)
p.add_option(
"--links", default=10, type=int, help="Only plot matchings more than"
)
p.add_option("--links", default=10, type=int, help="Only plot matchings more than")
p.add_option(
"--panels", default=False, action="store_true", help="Add panel labels A/B"
)
Expand Down
4 changes: 1 addition & 3 deletions jcvi/assembly/syntenypath.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,9 +140,7 @@ def bed(args):
action="store_true",
help="Switch reference and aligned map elements",
)
p.add_option(
"--scale", type=float, help="Scale the aligned map distance by factor"
)
p.add_option("--scale", type=float, help="Scale the aligned map distance by factor")
p.set_beds()
p.set_outfile()
opts, args = p.parse_args(args)
Expand Down
4 changes: 1 addition & 3 deletions jcvi/compara/catalog.py
Original file line number Diff line number Diff line change
Expand Up @@ -509,9 +509,7 @@ def omgprepare(args):

p = OptionParser(omgprepare.__doc__)
p.add_option("--norbh", action="store_true", help="Disable RBH hits")
p.add_option(
"--pctid", default=0, type=int, help="Percent id cutoff for RBH hits"
)
p.add_option("--pctid", default=0, type=int, help="Percent id cutoff for RBH hits")
p.add_option("--cscore", default=90, type=int, help="C-score cutoff for RBH hits")
p.set_stripnames()
p.set_beds()
Expand Down
4 changes: 1 addition & 3 deletions jcvi/compara/synteny.py
Original file line number Diff line number Diff line change
Expand Up @@ -1454,9 +1454,7 @@ def mcscan(args):
tandem cluster as one line, tab separated.
"""
p = OptionParser(mcscan.__doc__)
p.add_option(
"--iter", default=100, type=int, help="Max number of chains to output"
)
p.add_option("--iter", default=100, type=int, help="Max number of chains to output")
p.add_option(
"--ascii",
default=False,
Expand Down
4 changes: 1 addition & 3 deletions jcvi/formats/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -785,9 +785,7 @@ def group(args):

p = OptionParser(group.__doc__)
p.set_sep()
p.add_option(
"--groupby", default=None, type=int, help="Default column to groupby"
)
p.add_option("--groupby", default=None, type=int, help="Default column to groupby")
p.add_option(
"--groupsep", default=",", help="Separator to join the grouped elements"
)
Expand Down
4 changes: 1 addition & 3 deletions jcvi/formats/bed.py
Original file line number Diff line number Diff line change
Expand Up @@ -2440,9 +2440,7 @@ def flanking(args):
p.add_option(
"--coord", default=None, type=int, help="coordinate of the position in query."
)
p.add_option(
"-n", default=10, type=int, help="number of flanking features to get"
)
p.add_option("-n", default=10, type=int, help="number of flanking features to get")
p.add_option(
"--side",
default="both",
Expand Down
4 changes: 1 addition & 3 deletions jcvi/formats/fasta.py
Original file line number Diff line number Diff line change
Expand Up @@ -540,9 +540,7 @@ def qual(args):
from jcvi.formats.sizes import Sizes

p = OptionParser(qual.__doc__)
p.add_option(
"--qv", default=31, type=int, help="Dummy qv score for extended bases"
)
p.add_option("--qv", default=31, type=int, help="Dummy qv score for extended bases")
p.set_outfile()
opts, args = p.parse_args(args)

Expand Down
4 changes: 1 addition & 3 deletions jcvi/graphics/grabseeds.py
Original file line number Diff line number Diff line change
Expand Up @@ -297,9 +297,7 @@ def add_seeds_options(p, args):
g2.add_option(
"--maxsize", default=50, type=float, help="Max percentage of object to image"
)
g2.add_option(
"--count", default=100, type=int, help="Report max number of objects"
)
g2.add_option("--count", default=100, type=int, help="Report max number of objects")
g2.add_option(
"--watershed",
default=False,
Expand Down
12 changes: 3 additions & 9 deletions jcvi/projects/str.py
Original file line number Diff line number Diff line change
Expand Up @@ -2044,9 +2044,7 @@ def compare2(args):
Compare performances of various variant callers on simulated STR datasets.
"""
p = OptionParser(compare2.__doc__)
p.add_option(
"--maxinsert", default=300, type=int, help="Maximum number of repeats"
)
p.add_option("--maxinsert", default=300, type=int, help="Maximum number of repeats")
add_simulate_options(p)
opts, args, iopts = p.set_image_options(args, figsize="10x5")

Expand Down Expand Up @@ -2101,9 +2099,7 @@ def power(args):
This compares the power of various evidence types.
"""
p = OptionParser(power.__doc__)
p.add_option(
"--maxinsert", default=300, type=int, help="Maximum number of repeats"
)
p.add_option("--maxinsert", default=300, type=int, help="Maximum number of repeats")
add_simulate_options(p)
opts, args, iopts = p.set_image_options(args, figsize="10x10", format="png")

Expand Down Expand Up @@ -2200,9 +2196,7 @@ def tredparse(args):
Adds coverage comparisons as panel C and D.
"""
p = OptionParser(tredparse.__doc__)
p.add_option(
"--maxinsert", default=300, type=int, help="Maximum number of repeats"
)
p.add_option("--maxinsert", default=300, type=int, help="Maximum number of repeats")
add_simulate_options(p)
opts, args, iopts = p.set_image_options(args, figsize="10x10")

Expand Down

0 comments on commit 37e4bd7

Please sign in to comment.