def do_analysis(self): log.info("Performing complete analysis") partnum = len(self.cfg.partitions) scheme_count = submodels.count_all_schemes(partnum) subset_count = submodels.count_all_subsets(partnum) self.cfg.progress.begin(scheme_count, subset_count) # Iterate over submodels, which we can turn into schemes afterwards in the loop model_iterator = submodels.submodel_iterator([], 1, partnum) scheme_name = 1 for m in model_iterator: s = scheme.model_to_scheme(m, scheme_name, self.cfg) scheme_name = scheme_name + 1 res = self.analyse_scheme(s) # Write out the scheme self.cfg.reporter.write_scheme_summary(s, res) self.cfg.reporter.write_best_scheme(self.results)
def do_analysis(self): models = self.cfg.models partnum = len(self.cfg.partitions) self.total_scheme_num = submodels.count_all_schemes(partnum) log.info("Analysing all possible schemes for %d starting partitions", partnum) log.info("This will result in %s schemes being created", self.total_scheme_num) self.total_subset_num = submodels.count_all_subsets(partnum) log.info("PartitionFinder will have to analyse %d subsets to complete this analysis" % (self.total_subset_num)) if self.total_subset_num > 10000: log.warning("%d is a lot of subsets, this might take a long time to analyse", self.total_subset_num) log.warning("Perhaps consider using a different search scheme instead (see Manual)") # clear any schemes that are currently loaded self.cfg.schemes.clear_schemes() # iterate over submodels, which we can turn into schemes afterwards in the loop model_iterator = submodels.submodel_iterator([], 1, partnum) scheme_name = 1 for m in model_iterator: s = scheme.model_to_scheme(m, scheme_name, self.cfg) scheme_name = scheme_name + 1 self.analyse_scheme(s, models)