From 7c5d1d522d895b98011e13f4255f802072dfcafe Mon Sep 17 00:00:00 2001 From: Simon Rey Date: Wed, 11 Oct 2023 10:56:47 +0200 Subject: [PATCH] Few fix and new version --- pabutools/rules/greedywelfare.py | 5 +++-- pyproject.toml | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/pabutools/rules/greedywelfare.py b/pabutools/rules/greedywelfare.py index a21cbb10..4249ecee 100644 --- a/pabutools/rules/greedywelfare.py +++ b/pabutools/rules/greedywelfare.py @@ -188,7 +188,7 @@ def greedy_utilitarian_welfare( profile: AbstractProfile, sat_class: type[SatisfactionMeasure] = None, sat_profile: GroupSatisfactionMeasure = None, - is_sat_additive: bool = False, + is_sat_additive: bool = None, tie_breaking: TieBreakingRule = None, resoluteness: bool = True, initial_budget_allocation: Iterable[Project] = None, @@ -242,7 +242,8 @@ def greedy_utilitarian_welfare( else: if sat_profile is None: sat_profile = profile.as_sat_profile(sat_class) - is_sat_additive = issubclass(sat_class, AdditiveSatisfaction) + if is_sat_additive is None: + is_sat_additive = issubclass(sat_class, AdditiveSatisfaction) if is_sat_additive: return greedy_utilitarian_scheme_additive( diff --git a/pyproject.toml b/pyproject.toml index b498f29c..b90d06fc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "flit_core.buildapi" [project] name = "pabutools" -version = "1.0.7" +version = "1.0.8" description = "Implementation of all the tools necessary to explore and analyse participatory budgeting elections" authors = [ { name = "Simon Rey", email = "reysimon@orange.fr" },