Exemplo n.º 1
0
                                  mysql_user,
                                  mysql_pwd,
                                  mysql_db,
                                  main_blastnr_table=True,
                                  alternate_tables=True)

    if args.load_tables:

        server, db = manipulate_biosqldb.load_db(biodb)

        sys.stdout.write("creating locus_tag2seqfeature_id")
        locus_tag2seqfeature_id = manipulate_biosqldb.locus_tag2seqfeature_id_dict(
            server, biodb)

        sys.stdout.write("creating protein_id2seqfeature_id")
        protein_id2seqfeature_id = manipulate_biosqldb.protein_id2seqfeature_id_dict(
            server, biodb)

        sys.stdout.write("getting seqfeature_id2locus_tag")
        seqfeature_id2locus_tag = manipulate_biosqldb.seqfeature_id2locus_tag_dico(
            server, biodb)

        sys.stdout.write("getting locus_tag2accession")
        locus_tag2accession = manipulate_biosqldb.locus_tag2accession(
            server, args.mysql_database)

        blastnr2biosql(seqfeature_id2locus_tag, locus_tag2seqfeature_id,
                       protein_id2seqfeature_id, locus_tag2accession, biodb,
                       args.n_procs, mysql_host, mysql_user, mysql_pwd,
                       mysql_db, *args.input_blast)
Exemplo n.º 2
0
    print("creating orthology table")
    print("number of groups", len(orthogroup2detailed_count))
    create_orthology_mysql_table(server, orthogroup2detailed_count,
                                 args.db_name)

    print("get locus_tag2taxon_id dictionnary...")
    locus_tag2genome_taxon_id = manipulate_biosqldb.locus_tag2genome_taxon_id(
        server, args.db_name)

    print('creating locustag2seqfature_id table')
    get_locus2seqfeature_table.create_locus_tag2seqfeature_table(
        args.db_name, locus_tag2seqfeature_id, locus_tag2genome_taxon_id)

    print("get protein_id2seqfeature_id")
    protein_id2seqfeature_id = manipulate_biosqldb.protein_id2seqfeature_id_dict(
        server, args.db_name)

    print("get locus_tag2accession dictionnary...")
    locus_tag2accession = manipulate_biosqldb.locus_tag2accession(
        server, args.db_name)

    print("get protein_id2accession dictionnary...")
    protein_id2accession = manipulate_biosqldb.protein_id2accession(
        server, args.db_name)

    print("getting location")
    seqfeature_id2seqfeature_location = manipulate_biosqldb.seqfeature_id2feature_location_dico(
        server, args.db_name)

    print("getting seqfeature_id2protein_id")
    seqfeature_id2protein_id = manipulate_biosqldb.seqfeature_id2protein_id_dico(