sys.stderr.write("############# PATHS\n") _print_paths(blastn_app_path, gmap_app_path, gmapl_app_path, hsblastn_app_path, blastn_dbs_path, gmap_dbs_path, hsblastn_dbs_path, split_blast_path, genmap_path, tmp_files_path) sys.stderr.write("\n") ############################ Databases configuration ################################# ###################################################################################### ############### Configured databases ############### sys.stderr.write("############# DATABASES\n\n") databases_conf_file = __app_path + DATABASES_CONF databases_config = DatabasesConfig(databases_conf_file, verbose=False) for database_id in databases_config.get_databases(): database_name = databases_config.get_database_name(database_id) database_type = databases_config.get_database_type(database_id) sys.stderr.write("DB: " + database_name + " --> ID: " + database_id + ", type: " + database_type + "\n") sys.stderr.write("\n") ############## External databases ############## # In blastn DBs path databases_ids = databases_config.get_databases_ids() # set(databases_ids) other_dbs = set() num_found = 0
##### if verbose_param: _print_parameters(query_fasta_path, maps_names, aligner_list, threshold_id, threshold_cov, n_threads, sort_param, multiple_param, best_score, show_anchored, show_genes, show_markers, extend_window, show_unmapped, collapsed_view) ############### MAIN if verbose_param: sys.stderr.write("\n") ############# ALIGNMENTS - REFERENCES # Databases databases_conf_file = __app_path + DATABASES_CONF databases_config = DatabasesConfig(databases_conf_file, verbose_param) #facade = AlignmentFacade(split_blast_path, blastn_app_path, gmap_app_path, hsblastn_app_path, # blastn_dbs_path, gmap_dbs_path, hsblastn_dbs_path, gmapl_app_path, # tmp_files_path, databases_config, verbose = verbose_param) alignment_facade = AlignmentFacade(paths_config, verbose=verbose_param) ############ Pre-loading of some objects ############ # DatasetsFacade # Datasets config datasets_conf_file = __app_path + DATASETS_CONF datasets_config = DatasetsConfig(datasets_conf_file) datasets_ids = datasets_config.get_datasets_list( ) #datasets_config.get_datasets().keys()
# Num threads if options.n_threads: n_threads = int(options.n_threads) else: n_threads = DEFAULT_N_THREADS # Hierarchical if options.search_type: search_type = options.search_type else: search_type = DEFAULT_HIERARCHICAL # ref_type if options.ref_type: ref_type_param = options.ref_type else: ref_type_param = DEFAULT_REF_TYPE # Databases databases_conf_file = __app_path+DATABASES_CONF databases_config = DatabasesConfig(databases_conf_file, verbose_param) if options.databases_param: # or "all databases in conf" databases_names = options.databases_param databases_ids = databases_config.get_databases_ids(databases_names.strip().split(",")) elif options.databases_ids_param: databases_ids = options.databases_ids_param.strip().split(",") databases_names = ",".join(databases_config.get_databases_names(databases_ids)) else: databases_ids = databases_config.get_databases().keys() databases_names = ",".join(databases_config.get_databases_names(databases_ids)) if len(databases_ids)<=0 or len(databases_names)<=0: raise Exception("No valid databases were found. Please, check your --databases parameter or your conf/databases.conf file.")
sys.stderr.write("\n") sys.stderr.write("############# PATHS\n") _print_paths(blastn_app_path, gmap_app_path, gmapl_app_path, hsblastn_app_path, blastn_dbs_path, gmap_dbs_path, hsblastn_dbs_path, split_blast_path, genmap_path, tmp_files_path) sys.stderr.write("\n") ############################ Databases configuration ################################# ###################################################################################### ############### Configured databases ############### sys.stderr.write("############# DATABASES\n\n") databases_conf_file = __app_path+DATABASES_CONF databases_config = DatabasesConfig(databases_conf_file, verbose = False) for database_id in databases_config.get_databases(): database_name = databases_config.get_database_name(database_id) database_type = databases_config.get_database_type(database_id) sys.stderr.write("DB: "+database_name+" --> ID: "+database_id+", type: "+database_type+"\n") sys.stderr.write("\n") ############## External databases ############## # In blastn DBs path databases_ids = databases_config.get_databases_ids() # set(databases_ids) other_dbs = set() num_found = 0 first = True