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

Support for more than two teams in Weng-Lin #5

Closed
asyncth opened this issue Dec 18, 2022 · 6 comments · Fixed by #6
Closed

Support for more than two teams in Weng-Lin #5

asyncth opened this issue Dec 18, 2022 · 6 comments · Fixed by #6

Comments

@asyncth
Copy link
Contributor

asyncth commented Dec 18, 2022

Probably shouldn't be that difficult to do, my primary reason to want this is to be able to calculate ratings for free-for-all matches. I probably can implement this myself, not sure what the API should look like though.

@atomflunder
Copy link
Owner

atomflunder commented Dec 18, 2022

Hi, thanks again for the request!

I have been looking into multi-team rating for a bit for the TrueSkill algorithm, but since that is quite complex I have only a non-functioning prototype that I have always put off fixing. I think it should be easier for the Weng-Lin algorithm. If you want to go ahead, it would be much appreciated of course!

As for the API, it will not be compatible with the Outcomes enum. I would be fine with either a new enum or just type called something like MultiTeamOutcome or FFAOutcome or whatever sounds the best, and having a rank as usize inside it indicating team placements. Or just passing in the rating groups together with a usize indicating the rank directly into the rating function (Like the argument would be rating_groups: &[(&[WengLinRating], usize)]). But I am also open for something else if you have a better suggestion.

@asyncth
Copy link
Contributor Author

asyncth commented Dec 18, 2022

Back to this profile.

Is MultiTeamOutcome supposed to be passed into a function in a tuple, just like usize example?

@atomflunder
Copy link
Owner

Is MultiTeamOutcome supposed to be passed into a function in a tuple, just like usize example?

I could see having either either rating_groups: &[(&[WengLinRating], MultiTeamOutcome)], or rating_groups: &[&[WengLinRating]], outcomes: &[MultiTeamOutcome] working fine, what do you think?

@asyncth
Copy link
Contributor Author

asyncth commented Dec 18, 2022

I like former one more I guess.

@asyncth
Copy link
Contributor Author

asyncth commented Dec 18, 2022

What should be the name of this new function? Or should the original team function be modified instead?

@atomflunder
Copy link
Owner

What should be the name of this new function? Or should the original team function be modified instead?

I like having a Team vs Team function as a shortcut, with more efficient calculations, so I personally would say we re-name the original function weng_ling_two_teams (or similar) and name the new function weng_lin_multi_team. I think the naming might be confusing to users otherwise. But, as always, I am open to better suggestions.

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

Successfully merging a pull request may close this issue.

2 participants