Fix error/bug in unweighted inclusive Gregory implementation
This commit is contained in:
parent
d1528ee987
commit
81dbadb8ae
@ -463,10 +463,11 @@ class BaseUIGSTVCounter(BaseSTVCounter):
|
||||
Basic unweighted inclusive Gregory STV counter
|
||||
"""
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
BaseSTVCounter.__init__(self, *args, **kwargs)
|
||||
def __init__(self, *args):
|
||||
BaseSTVCounter.__init__(self, *args)
|
||||
# Need to use Rational for ballot value internally, as Num may be set to integers only
|
||||
self.cls_ballot_value = Rational
|
||||
#self.cls_ballot_value = Rational
|
||||
self.cls_ballot_value = lambda x: x.to_rational()
|
||||
|
||||
def do_surplus(self, candidate_surplus, count_card, surplus):
|
||||
# FIXME: Is it okay to use native int's here?
|
||||
|
Reference in New Issue
Block a user