Module Expr Str Import alias Import alias Import alias ImportFrom alias alias FunctionDef arguments args NameParam NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Str keyword NameLoad Assign NameStore Num Assign NameStore Num For NameStore Call NameLoad NameLoad body If Call NameLoad NameLoad body AugAssignAdd NameStore Num AugAssignAdd NameStore Num Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str TupleLoad NameLoad NameLoad decorator_list FunctionDef arguments args defaults body Print NameLoad Print Str Expr Call AttributeLoad NameLoad attr Num decorator_list If CompareEq NameLoad Str body Assign NameStore NameLoad Assign NameStore NameLoad Assign NameStore NameLoad For NameStore SubscriptLoad AttributeLoad NameLoad attr Slice Num body If CompareEq NameLoad Str body Expr Call NameLoad orelse If CompareEq NameLoad Str body Assign NameStore NameLoad orelse If UnaryOpNot NameLoad body If Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad orelse Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str NameLoad Expr Call NameLoad orelse If UnaryOpNot NameLoad body If BoolOpOr NameLoad UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Assign NameStore NameLoad orelse Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str NameLoad Expr Call NameLoad orelse Expr Call NameLoad If BoolOpOr UnaryOpNot NameLoad UnaryOpNot NameLoad body Expr Call NameLoad Expr Call NameLoad NameLoad NameLoad
N/A N/A 
Fixes BAM files where the CIGAR alignment has a zero length element
 N/A sys N/A os N/A pysam ngsutils.bam bam_iter read_cleancigar bam_cleancigar N/A N/A infile outfile N/A N/A N/A bam N/A N/A pysam Samfile infile rb N/A out N/A N/A pysam Samfile outfile wb template bam N/A total 0 N/A count 0 N/A read N/A bam_iter bam N/A N/A N/A read_cleancigar read N/A N/A count 1 N/A total 1 N/A N/A N/A out write read N/A N/A N/A bam close N/A N/A N/A out close N/A N/A N/A N/A sys stderr write N/A Wrote: %s reads
Altered: %s
 N/A total count N/A usage N/A N/A N/A N/A N/A __doc__ N/A Usage: bamutils cleancigar {-f} inbamfile outbamfile

Options:
  -f     Force overwriting an existing outfile
 N/A N/A N/A sys exit -1 N/A N/A N/A __name__ __main__ N/A N/A infile None N/A outfile None N/A force False N/A arg N/A N/A sys argv N/A 1 N/A N/A N/A arg -h N/A N/A N/A usage N/A N/A N/A arg -f N/A N/A force True N/A N/A N/A infile N/A N/A N/A N/A N/A os path exists N/A N/A N/A os path expanduser arg N/A N/A infile N/A N/A N/A os path expanduser arg N/A N/A N/A N/A N/A sys stderr write N/A File: %s not found! arg N/A N/A usage N/A N/A N/A outfile N/A N/A N/A force N/A N/A N/A N/A os path exists N/A N/A N/A os path expanduser arg N/A N/A outfile arg N/A N/A N/A N/A N/A sys stderr write N/A File: %s exists! Not overwriting without -f force. arg N/A N/A usage N/A N/A N/A usage N/A N/A N/A infile N/A outfile N/A N/A N/A usage N/A N/A bam_cleancigar infile outfile