Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

incorrect distribution for one parameter #5

Open
tirana opened this issue Aug 22, 2019 · 2 comments
Open

incorrect distribution for one parameter #5

tirana opened this issue Aug 22, 2019 · 2 comments

Comments

@tirana
Copy link

tirana commented Aug 22, 2019

result = AllPairs(OrderedDict( {"a1": ["0", "1"], "a2": ["0", "1"], "a3": ["0", "1"], "a4": ["0", "1"], "a5": ["0", "1"], "a6": ["0", "1"]}))

generates:
[
Pairs(a1='0', a3='0', a2='0', a5='0', a4='0', a6='0'),
Pairs(a1='1', a3='1', a2='1', a5='1', a4='1', a6='0'),
Pairs(a1='1', a3='0', a2='1', a5='0', a4='1', a6='1'),
Pairs(a1='0', a3='1', a2='0', a5='1', a4='0', a6='1'),
Pairs(a1='0', a3='1', a2='1', a5='0', a4='0', a6='1'),
Pairs(a1='1', a3='0', a2='0', a5='1', a4='0', a6='1'),
Pairs(a1='0', a3='0', a2='0', a5='1', a4='1', a6='1')]

as you may see the a6 has 5 "1" while the other 3 or 4.

similar picture for 8 params:
[Pairs(a1='0', a3='0', a2='0', a5='0', a4='0', a7='0', a6='0', a8='0'),
Pairs(a1='1', a3='1', a2='1', a5='1', a4='1', a7='1', a6='1', a8='0'),
Pairs(a1='1', a3='0', a2='1', a5='0', a4='1', a7='0', a6='1', a8='1'),
Pairs(a1='0', a3='1', a2='0', a5='1', a4='0', a7='1', a6='0', a8='1'),
Pairs(a1='0', a3='1', a2='1', a5='0', a4='0', a7='1', a6='1', a8='1'),
Pairs(a1='1', a3='0', a2='0', a5='1', a4='1', a7='1', a6='0', a8='1'),
Pairs(a1='1', a3='1', a2='0', a5='1', a4='0', a7='0', a6='1', a8='1'),
Pairs(a1='0', a3='1', a2='1', a5='1', a4='1', a7='1', a6='0', a8='1')]

@thombashi
Copy link
Owner

thombashi commented Jul 24, 2020

Thank you for your report.

This issue probably the same cause with #2

@pavelicii
Copy link

Fixed in this PR.

result = AllPairs(OrderedDict({
    "a1": ["0", "1"], 
    "a2": ["0", "1"], 
    "a3": ["0", "1"], 
    "a4": ["0", "1"], 
    "a5": ["0", "1"], 
    "a6": ["0", "1"],
    "a7": ["0", "1"],
    "a8": ["0", "1"],
}))

generates:

PAIRWISE:
 0: Pairs(a1='0', a2='0', a3='0', a4='0', a5='0', a6='0', a7='0', a8='0')
 1: Pairs(a1='1', a2='1', a3='1', a4='1', a5='1', a6='1', a7='1', a8='0')
 2: Pairs(a1='1', a2='0', a3='1', a4='0', a5='1', a6='0', a7='1', a8='1')
 3: Pairs(a1='0', a2='1', a3='0', a4='1', a5='0', a6='1', a7='0', a8='1')
 4: Pairs(a1='0', a2='1', a3='1', a4='0', a5='0', a6='1', a7='1', a8='1')
 5: Pairs(a1='1', a2='0', a3='0', a4='1', a5='1', a6='0', a7='0', a8='0')
 6: Pairs(a1='1', a2='0', a3='0', a4='1', a5='0', a6='1', a7='1', a8='0')
 7: Pairs(a1='0', a2='1', a3='1', a4='0', a5='1', a6='0', a7='0', a8='1')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants