コード例 #1
0
def align_against_genomes(cur, args, path):
    for g in args.chromolist:
        output = os.path.abspath(
            os.path.join(
                args.output,
                "{0}_v_{1}.lastz".format(os.path.basename(args.probefile), g)))
        target = path.format(g)
        prefab = False
        if os.path.isfile(output + '.clean'):
            inpt = raw_input(
                "The output file {0} exists.  Do you want to use it [Y/n]? ".
                format(g))
            if inpt == 'Y' or inpt == 'Yes':
                prefab = True
                clean = output + '.clean'
            else:
                prefab = False
        if not prefab:
            multi_lastz_runner(output, args.cores, target, args.probefile,
                               False, args.coverage, args.identity)
            clean = clean_lastz_data(output)
        if args.db:
            create_species_lastz_tables(cur, g)
            insert_species_to_lastz_tables(cur, g, clean)
            cur.execute('INSERT INTO species (name) VALUES (?)', (g, ))
コード例 #2
0
ファイル: run_lastz.py プロジェクト: crinfante/phyluce
def main():
    start_time = time.time()
    print 'Started: ', time.strftime("%a %b %d, %Y  %H:%M:%S",
                                     time.localtime(start_time))
    options, arg = interface()
    multi_lastz_runner(options.output, options.nprocs, options.target,
                       options.query, options.huge, options.coverage,
                       options.identity, options.size)
    end_time = time.time()
    print 'Ended: ', time.strftime("%a %b %d, %Y  %H:%M:%S",
                                   time.localtime(end_time))
    print 'Time for execution: ', (end_time - start_time) / 60, 'minutes'
コード例 #3
0
ファイル: run_lastz.py プロジェクト: GrahamDB/phyluce
def main():
    start_time = time.time()
    print 'Started: ', time.strftime("%a %b %d, %Y  %H:%M:%S", time.localtime(start_time))
    options, arg = interface()
    multi_lastz_runner(
            options.output,
            options.nprocs,
            options.target,
            options.query,
            options.huge,
            options.coverage,
            options.identity,
            options.size
        )
    end_time = time.time()
    print 'Ended: ', time.strftime("%a %b %d, %Y  %H:%M:%S", time.localtime(end_time))
    print 'Time for execution: ', (end_time - start_time) / 60, 'minutes'
コード例 #4
0
def align_against_genomes(cur, args, path):
    for g in args.chromolist:
        output = os.path.abspath(os.path.join(args.output, "{0}_v_{1}.lastz".format(os.path.basename(args.probefile), g)))
        target = path.format(g)
        prefab = False
        if os.path.isfile(output + '.clean'):
            inpt = raw_input("The output file {0} exists.  Do you want to use it [Y/n]? ".format(g))
            if inpt == 'Y' or inpt == 'Yes':
                prefab = True
                clean = output + '.clean'
            else:
                prefab = False
        if not prefab:
            multi_lastz_runner(output, args.cores, target, args.probefile, False, args.coverage, args.identity)
            clean = clean_lastz_data(output)
        if args.db:
            create_species_lastz_tables(cur, g)
            insert_species_to_lastz_tables(cur, g, clean)
            cur.execute('INSERT INTO species (name) VALUES (?)', (g,))