49efa4a7260be8ed44986ad93fd3594391865c09,anvio/genomedescriptions.py,GenomeDescriptions,get_genome_hash_for_internal_genome,#GenomeDescriptions#Any#,327
Before Change
utils.is_contigs_db(entry["contigs_db_path"])
split_names_of_interest = self.get_split_names_of_interest_for_internal_genome(entry)
contigs_db = dbops.ContigsDatabase(entry["contigs_db_path"])
genome_hash = hashlib.sha224("_".join(["".join(split_names_of_interest), contigs_db.meta["contigs_db_hash"]]).encode("utf-8")).hexdigest()[0:12]
contigs_db.disconnect()
return genome_hash
After Change
contigs_db_hash = db.DB(entry["contigs_db_path"], None, ignore_version=True).get_meta_value("contigs_db_hash")
genome_hash = hashlib.sha224("_".join(["".join(split_names_of_interest), contigs_db_hash]).encode("utf-8")).hexdigest()[0:12]
if genome_hash in self.genome_hash_to_genome_name:
self.progress.reset()
raise ConfigError("According to hash values anvi"o has been generating for your internal genomes, not all genomes you have seem to be uniuqe. "
"It is most likely you unintentionally listed the same information for different genome names. If you would like "
"to double check, genome %s and genome %s seem to have the same hash. "
"If you are certain these genomes represent two different genomes, please re-run the program, and if they appear "
"again please let the developers know about the problem." % (self.genome_hash_to_genome_name[genome_hash], entry["name"]))
return genome_hash
def init_external_genomes(self):
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances
Project Name: merenlab/anvio
Commit Name: 49efa4a7260be8ed44986ad93fd3594391865c09
Time: 2020-03-22
Author: a.murat.eren@gmail.com
File Name: anvio/genomedescriptions.py
Class Name: GenomeDescriptions
Method Name: get_genome_hash_for_internal_genome
Project Name: merenlab/anvio
Commit Name: 49efa4a7260be8ed44986ad93fd3594391865c09
Time: 2020-03-22
Author: a.murat.eren@gmail.com
File Name: anvio/genomedescriptions.py
Class Name: GenomeDescriptions
Method Name: get_genome_hash_for_external_genome
Project Name: azavea/raster-vision
Commit Name: 2b6f090645d9beab38c19230d940b34031e95b34
Time: 2018-12-07
Author: skassel@azavea.com
File Name: rastervision/command/chip_command_config.py
Class Name: ChipCommandConfigBuilder
Method Name: validate