def dict_file(self, options): """Generate GTDB dictionary file.""" check_file_exists(options.taxonomy_file) make_sure_path_exists(options.output_dir) p = WebsiteData(options.release_number, options.output_dir) p.dict_file(options.taxonomy_file) self.logger.info('Done.')
def gene_files(self, options): """Generate untrimmed gene files for bac120/ar122""" make_sure_path_exists(options.output_dir) check_file_exists(options.user_gid_table) w = WebsiteData(options.release_number, options.output_dir) w.gene_files(options.user_gid_table, options.taxonomy_file, options.cpus) self.logger.info('Done.')
def nucleotide_files(self, options): """Generate the archive containing all protein (AA) for representative genomes.""" make_sure_path_exists(options.output_dir) check_file_exists(options.user_gid_table) check_file_exists(options.genome_dirs) w = WebsiteData(options.release_number, options.output_dir) w.nucleotide_files(options.user_gid_table, options.taxonomy_file, options.genome_dirs, options.uba_path) self.logger.info('Done.')
def hq_genome_file(self, options): """Generate file indicating HQ genomes.""" check_file_exists(options.metadata_file) if options.user_gid_table.lower() != 'none': check_file_exists(options.user_gid_table) make_sure_path_exists(options.output_dir) p = WebsiteData(options.release_number, options.output_dir) p.hq_genome_file(options.metadata_file, options.user_gid_table) self.logger.info('Done.')
def sp_cluster_file(self, options): """Generate file indicating GTDB species clusters.""" check_file_exists(options.metadata_file) check_file_exists(options.gtdb_sp_clusters_file) check_file_exists(options.user_gid_table) make_sure_path_exists(options.output_dir) p = WebsiteData(options.release_number, options.output_dir) p.sp_cluster_file(options.metadata_file, options.gtdb_sp_clusters_file, options.user_gid_table) self.logger.info('Done.')
def taxonomy_files(self, options): """Generate taxonomy files for GTDB website.""" check_file_exists(options.metadata_file) check_file_exists(options.gtdb_sp_clusters_file) check_file_exists(options.user_gid_table) make_sure_path_exists(options.output_dir) p = WebsiteData(options.release_number, options.output_dir) p.taxonomy_files(options.metadata_file, options.gtdb_sp_clusters_file, options.user_gid_table) self.logger.info('Done.')
def tax_comp_files(self, options): """Generate comparison files between 2 taxonomy ordered by degree of polyphyly.""" check_file_exists(options.reference_taxonomy_file) check_file_exists(options.new_taxonomy_file) make_sure_path_exists(options.output_dir) p = WebsiteData('', options.output_dir) p.tax_comp_files(options.reference_taxonomy_file, options.new_taxonomy_file, options.user_gid_table, options.changes_only, options.filter_placeholder_name, options.top_change) self.logger.info('Done.')
def marker_files(self, options): """Generate marker gene file.""" check_dir_exists(options.bac120_gene_dir) check_dir_exists(options.ar122_gene_dir) check_file_exists(options.user_gid_table) make_sure_path_exists(options.output_dir) p = WebsiteData(options.release_number, options.output_dir) p.marker_files(options.bac120_gene_dir, options.ar122_gene_dir, options.user_gid_table) self.logger.info('Done.')
def tree_files(self, options): """Generate tree files spanning representative genomes.""" check_file_exists(options.metadata_file) check_file_exists(options.bac_tree) check_file_exists(options.ar_tree) check_file_exists(options.user_gid_table) make_sure_path_exists(options.output_dir) p = WebsiteData(options.release_number, options.output_dir) p.tree_files(options.metadata_file, options.bac_tree, options.ar_tree, options.user_gid_table) self.logger.info('Done.')
def msa_files(self, options): """Generate concatenated MSA files.""" check_file_exists(options.bac120_msa_file) check_file_exists(options.ar122_msa_file) check_file_exists(options.metadata_file) check_file_exists(options.user_gid_table) make_sure_path_exists(options.output_dir) p = WebsiteData(options.release_number, options.output_dir) p.msa_files(options.bac120_msa_file, options.ar122_msa_file, options.metadata_file, options.user_gid_table) self.logger.info('Done.')
def ssu_files(self, options): """Generate 16S rRNA FASTA files for GTDB website.""" check_file_exists(options.metadata_file) check_file_exists(options.gtdb_sp_clusters_file) check_file_exists(options.user_gid_table) check_file_exists(options.genome_path_file) make_sure_path_exists(options.output_dir) p = WebsiteData(options.release_number, options.output_dir) p.ssu_files(options.metadata_file, options.gtdb_sp_clusters_file, options.user_gid_table, options.genome_path_file, options.min_16S_ar_len, options.min_16S_bac_len, options.min_contig_len) self.logger.info('Done.')
def validate(self, options): """Perform validation checks on GTDB website files.""" check_file_exists(options.taxonomy_file) check_file_exists(options.tree_file) check_file_exists(options.metadata_file) check_file_exists(options.msa_file) check_file_exists(options.ssu_file) check_file_exists(options.sp_clusters_file) check_file_exists(options.hq_genome_file) p = WebsiteData(None, None) p.validate(options.taxonomy_file, options.tree_file, options.metadata_file, options.msa_file, options.ssu_file, options.sp_clusters_file, options.hq_genome_file) self.logger.info('Done.')
def arb_files(self, options): """Generate ARB metadata file.""" self.logger.warning('IN PROGRESS') return check_file_exists(options.metadata_file) check_file_exists(options.metadata_fields) check_file_exists(options.user_gid_table) check_file_exists(options.bac120_msa_file) check_file_exists(options.ar122_msa_file) make_sure_path_exists(options.output_dir) p = WebsiteData(options.release_number, options.output_dir) p.arb_files(options.metadata_file, options.metadata_fields, options.user_gid_table, options.bac120_msa_file, options.ar122_msa_file) self.logger.info('Done.')
def json_tree_parser(self, options): """generate Json file used to create the tree in http://gtdb.ecogenomic.org/tree""" p = WebsiteData(options.release_number, options.output_dir) p.json_tree_parser(options.taxonomy_file, options.metadata_file) self.logger.info('Done.')