Repository navigation
Ex-Fuzzy 3.4.0
Ex-Fuzzy 3.4.0 adds mixture-of-rules inference to the genetic classifier, and fitting on training sets too large for memory.
pip install --upgrade ex-fuzzy
Before upgrading: the temporal module is removed, evalRuleBase no longer takes time_moments, and samples that fire no rule now take the most frequent training class, so seeded fits on data with uncovered samples change. See Removed and Changed below.
Added
- Mixture of rules:
BaseFuzzyRulesClassifier(inference='mixture')lets every rule that holds add its weights to every class (a multinomial logistic regression on the firing strengths, free or non-negative), instead of the single winning rule deciding.fit_mixture,mixture_scores,mixture_contributionsandprint_mixturework on fitted models. Withmixture_search=Truethe genetic search scores candidates as mixtures and prunes rules by their role in the mixture (mixture_pruning,mixture_prune_threshold), so a rule that only suppresses a class is kept. - Training sets too large for memory:
batch_size=nscores candidatesnsamples at a time with identical results. - Growing training subset:
initial_data_fraction=xstarts the search on part of the data and grows it. - Pattern stability:
pattern_stabilizer.rule_set_stabilityand related functions (selection frequencies, Jaccard between rule sets, consensus rules). - Partitions from breakpoints:
utils.construct_breakpoint_partition. - Regression:
unique_antecedents=Truedrops rules that repeat the same antecedents. - Pruning tolerance is recorded in
MasterRuleBase.pruning_tolerance.
Changed
- Smaller fitted models:
optimization_result_no longer keeps the training samples. - Samples that fire no rule (with
allow_unknown=False) are predicted as the most frequent training class, and no rule wins them.
Removed
- Temporal fuzzy sets: the
temporalmodule and its helpers inutils;evalRuleBaselosestime_moments.
Fixed
explainable_predictand two term-gene issues of the genetic classifier with partitions of different sizes.
The full list is in the changelog.