def parse_rarefaction_fname(name_string):
 (root, ext) = os.path.splitext(name_string)
 root_list = root.split('_')
 iters = int(root_list.pop())
 seqs_per_sam = int(root_list.pop())
 base_name = '_'.join(root_list)
 return (base_name, seqs_per_sam, iters, ext)

def parse_rarefaction_fname ( name_string ) : ( root , ext ) = os . path . splitext ( name_string ) root_list = root . split ( '_' ) iters = int ( root_list . pop ( ) ) seqs_per_sam = int ( root_list . pop ( ) ) base_name = '_' . join ( root_list ) return ( base_name , seqs_per_sam , iters , ext )
returns base .