Skip to content

Commit

Permalink
unnecessary try except
Browse files Browse the repository at this point in the history
  • Loading branch information
davek44 committed May 27, 2024
1 parent a475d01 commit eff21a1
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions src/baskerville/scripts/hound_data_align.py
Original file line number Diff line number Diff line change
Expand Up @@ -537,13 +537,8 @@ def break_large_contigs(contigs, break_t, verbose=False):

# break in two
ctg_mid = ctg.start + ctg_len // 2

try:
ctg_left = Contig(ctg.genome, ctg.chr, ctg.start, ctg_mid)
ctg_right = Contig(ctg.genome, ctg.chr, ctg_mid, ctg.end)
except AttributeError:
ctg_left = Contig(ctg.chr, ctg.start, ctg_mid)
ctg_right = Contig(ctg.chr, ctg_mid, ctg.end)
ctg_left = Contig(ctg.genome, ctg.chr, ctg.start, ctg_mid)
ctg_right = Contig(ctg.genome, ctg.chr, ctg_mid, ctg.end)

# add left
ctg_left_len = ctg_left.end - ctg_left.start
Expand Down

0 comments on commit eff21a1

Please sign in to comment.