News for hackers. Stuff that matters.
Re:Implementing the Elo Rating System (2020) by chairmanwow1 on Friday February 12, 2021 @01:47PM (#26116998)
One of my favorite Elo bugs I came across was a bug in a game called age of empires 2: DE.

Whenever my friend and I played online together, we would sporadically get absolutely creamed. We started looking up the stats of the others players we were matched with and noticed that on those bad games the average Elo of our opponents would jump to >2k Elo vs our barely 1k.

Both of us being software engineers, eventually the conversation turned to “What the hell do you think is going on here? How does a matchmaking bug like this crop up?”

Eventually we came to the conclusion that they must be summing out Elo for the Elo of our matchmaking party rather than averaging it.

Eventually the issue was patched and our worst suspicions were confirmed that indeed multiplayer party Elos were summed instead of averaged.

Re:Implementing the Elo Rating System (2020) by TameAntelope on Friday February 12, 2021 @02:26PM (#26117520)
The sentiment you're expressing is the idea that one 2k player is so much better than two 1k rated players that it doesn't make sense to simply sum up each team's rating and keep it even, which is the false assumption that the AoE 2 devs made. Elo is not linear.

However I don't think they'd have fixed it just by averaging the Elo ratings, they must have implemented something more complex, like a proximity based algorithm, otherwise if the teams were the same size you'd hit a similar problem with an average as with a sum. A 2k player + a 0 rated player would sum to 2k and average to 1k. You and your friend would also sum to 2k and average to 1k, again assuming even team sizes.

That said, still very funny!

Also, fun fact: Elo isn't an acronym/initialism, it's someone's name, Arpad Elo (the inventor).

Also also, I don't think Elo is really a good idea for multiplayer (more than 1v1 that is) games generally. Don't know enough to say that authoritatively, but using it for something like AoE 2 is likely prone to all kinds of strange unexpected outcomes.

Re:Implementing the Elo Rating System (2020) by jerf on Friday February 12, 2021 @03:59PM (#26118475)
"The sentiment you're expressing is the idea that one 2k player is so much better than two 1k rated players that it doesn't make sense to simply sum up each team's rating and keep it even, which is the false assumption that the AoE 2 devs made. Elo is not linear."

It's even better than that. Elo is purely relative. The difference in score between two opponents is what is supposed to predict the likelihood of victory for the two. This means that you can add any constant you like to the entire Elo pool without affecting the Elo rankings at all.

As a matter of aesthetics, when initializing an Elo pool it is nice to try to start with values that will result in nobody having a negative value, because that gives humans the feelbadz, but that's not mathematically necessary; you can run the whole thing deep in the negative billions if that floats your boat.

The Elo math is very much based on two players playing head-to-head. It would be completely broken for almost any other scenario, as multiplayer introduces new degrees of freedom that Elo has nowhere to put. By that I mean that there may be one game for which the team's skill is essentially the max of the members, another for which is it essentially the minimum, and a wide variety of things in between. Elo has nowhere to put that "wide variety", and it was never designed or intended to do so, so that's not a criticism of it. It just isn't what it was for.

Re:Implementing the Elo Rating System (2020) by wongarsu on Friday February 12, 2021 @03:18PM (#26118082)
Overwatch implements an Elo system for 6v6 competitive multiplayer. Over the years they've had to make a lot of tweaks to make it kind of work. For example groups are rated by average Elo, but the system doesn't allow you to cause large Elo differences within a team. Also it differentiates between "premade" groups and groups assembled by matchmaking, since the former are assumed to be more coordinated. It also tries to be really smart about how Elo points get distributed within the team on win/loss (which causes a heap of other problems).

Overall you can make it somewhat work, but Elo really isn't well suited for anything larger than 1v1

Re:Implementing the Elo Rating System (2020) by closed on Saturday February 13, 2021 @06:48PM (#26128189)
It's worth noting that the general models ELO approximates, called item response theory (IRT) models, could handle larger than 1v1.

Its similar to how you model situations where multiple latent skills contribute to performance (multidimensional IRT). In practice, it's a way easier though to use simple stuff like averaging / constraining groups so everyone has roughly the same skill level.

Re:Implementing the Elo Rating System (2020) by xxpor on Saturday February 13, 2021 @10:35AM (#26124166)
I'm not really sure anyone's come up with a better system though for a game like OW.

At least in comp I don't get rolled too often, so it sort of works.

Re:Implementing the Elo Rating System (2020) by lordnacho on Friday February 12, 2021 @02:53PM (#26117828)
Seems to me that you need to use the max of the team rather than the average. The better player can tell the less good player to do, up to a point.
Re:Implementing the Elo Rating System (2020) by jerf on Friday February 12, 2021 @04:11PM (#26118580)
I'd expect "geometric average" to be one of the closest simple statistics for most games, assuming that you have some ranking that can be treated linearly.

It would be generally unclear that rankings can be treated linearly. A subtle aspect of Elo is that as the disparity between two players increases, the Elo metric essentially becomes less and less certain that there is any relationship between the skill of the players at all, which is probably a bit deeper way of understanding "why" . Eventually you'll reach a point where if you round to integers, the winner winning will result in an increase of 0 points. (In fact one thing to watch out for is how you round; it's easy to end up with a wandering Elo basis if you truncate both sides rather than rounding properly, for instance.)

It's fairly trivial to show that if you take a pool of the worst players and the best players, Elo will eventually converge to those two pools having about that amount of distance between them, but by inserting a fresh pool of middling players into the pool, the distance between the best & the worst will increase despite their skill not changing. If skill is linearly distributed... assuming you can even define that... Elo ratings might be somewhat reasonably treated linearly, but skill is very unlikely to be linearly distributed.

Basically, I like Elo when used properly and I have used it to good effect a few times myself, but it is a bit dangerous in that it offers a number... but that number lacks many properties we associate with integers. (For instance, in another posting I point out you can shift the entire Elo pool by any constant you like without changing the system. Integers do not have this property.) They have a definite meaning, but it isn't what your intuition might suggest. You really shouldn't do any arithmetic on them. They only make sense in the context of the Elo computation itself.

Re:Implementing the Elo Rating System (2020) by noxvilleza on Friday February 12, 2021 @06:34PM (#26119858)
Although highly dependent on the game itself, I did some investigation back in 2008 into testing various Elo modifications on a pretty large dataset of individual players when playing in a 5v5 team game, and geometric mean of individual ratings was the best simple predictor for which team would win (the update method was essentially 10 individual matchups of each player vs the aggregate rating of the enemy team).
Re:Implementing the Elo Rating System (2020) by maybeOneDay on Friday February 12, 2021 @03:28PM (#26118181)
This is what rocket league uses. While it can be unpleasant as a high ranked player to jump in a lobby with your much less skilled friend, overall the matchmaking system and equality of matches is in my opinion utterly fantastic
Re:Implementing the Elo Rating System (2020) by jayd16 on Friday February 12, 2021 @02:56PM (#26117857)
Average just causes other issues. Teams should probably have their own rating not derived from the individual elo.

But honestly, elo is a shit system for fun matchmaking anyhow.

Re:Implementing the Elo Rating System (2020) by elcomet on Friday February 12, 2021 @03:12PM (#26118014)
Why do you say it's shit ?
Re:Implementing the Elo Rating System (2020) by jayd16 on Friday February 12, 2021 @03:22PM (#26118122)
Once you reach the top there's much less reason to keep playing. It doesn't have a great way to handle multiplayer situations. It doesn't handle confidence as well as some other systems ie it takes a while to skill test a player.

https://en.wikipedia.org/wiki/Elo_rating_system#Practical_is...

Trueskill and many others are often used instead.

https://en.wikipedia.org/wiki/TrueSkill

The biggest issue is fun is not the same fair and its a lot more complicated to tune for fun.

You could, for example, play 100 matches where you were given the closest opponent but at a disadvantage for every single match. There's a lot of other scenarios around how you want to fold in ping based match making and how that smaller pool effects the fairness of the matchhing.

Re:Implementing the Elo Rating System (2020) by nwallin on Friday February 12, 2021 @06:04PM (#26119598)
Elo is not a matchmaking system, Elo is a rating system.

Elo tells you how skilled a player is, how surprising a result (win, loss, draw if applicable) is, and how a player's rating should change based on a result and how surprising the result was. It does NOT tell you who should be matched up against who.

> The biggest issue is fun is not the same fair and its a lot more complicated to tune for fun.

> You could, for example, play 100 matches where you were given the closest opponent but at a disadvantage for every single match. There's a lot of other scenarios around how you want to fold in ping based match making and how that smaller pool effects the fairness of the matchhing.

Elo tells the system that if you play 100 games at a disadvantage, your rating should not go down as much when you lose, and should jump up more on a win. Elo is the math that tells the system that if your skill does not change, your score does not change, regardless of whether you play 100 games at disadvantage and lose most of them, or play 100 games at an advantage and win most of them.

I agree that Elo handles uncertainty poorly; when you're rating a chess player whose career is tracked over the course of decades, this isn't an issue, but online play with transient accounts, players who blip into a game when it's hot and then never play it again, smurfs and account buyers, people who take a break for a while and come back, patches which might radically change the meta, etc, uncertainty should be accounted for. Note that TrueSkill is, for all intents and purposes, just Elo+Bayesian inference. Like Elo, it is a rating system, not a matchmaking system. TrueSkill does not handle the problem of playing 100 games in a row against players who are better than you. TrueSkill, like Elo, just tells you what a result means, not which players should be pitted against each other.

Re:Implementing the Elo Rating System (2020) by noxvilleza on Friday February 12, 2021 @06:26PM (#26119797)
Elo-like systems (or various other rating systems) are often as part of a matchmaking algorithm - since you can easily calculate expected game win percentages for each party, and this allows you to create more enjoyable matchups. An example of this happens even in online chess: you're much more likely to be paired against a player with a similar rating, because you're much more likely to enjoy a match against someone similarly skilled.
Re:Implementing the Elo Rating System (2020) by jayd16 on Friday February 12, 2021 @06:48PM (#26119985)
Agreed. Elo is fine for ranking. The issue is its used to match make and it isn't great for that.
Re:Implementing the Elo Rating System (2020) by xmprt on Friday February 12, 2021 @03:51PM (#26118405)
What's the open source alternative to TrueSkill? It seems really interesting but it's patented by Microsoft.
Re:Implementing the Elo Rating System (2020) by philihp on Saturday February 13, 2021 @06:39PM (#26128136)
I wrote this library: https://www.npmjs.com/package/openskill

It's open-license, handles complex matchups (e.g. 5 vs. 3 vs. 4), comparable in predictive accuracy, and is up to 20x faster than TrueSkill. The implementation is also much simpler.

Re:Implementing the Elo Rating System (2020) by xmprt on Sunday February 14, 2021 @11:24PM (#26139068)
This is excellent. I love how simple the API is.
Re:Implementing the Elo Rating System (2020) by wizzwizz4 on Friday February 12, 2021 @04:18PM (#26118656)
They can't patent the general idea, so just base something off the information in the Wikipedia article. At time of writing, I don't think doing that would infringe their patent.
Re:Implementing the Elo Rating System (2020) by swirepe on Friday February 12, 2021 @06:05PM (#26119601)
Is your project non-commercial? You can use this[1] official bsd-licensed[2] library for non-commercial projects.

[1] https://trueskill.org/

[2] https://github.com/sublee/trueskill/blob/master/LICENSE

Re:Implementing the Elo Rating System (2020) by asymptotically3 on Friday February 12, 2021 @07:28PM (#26120286)
If it's BSD licensed, how do they limit it to non-commercial use?
Re:Implementing the Elo Rating System (2020) by stephencanon on Friday February 12, 2021 @08:28PM (#26120626)
BSD doesn’t have a patent grant, so it would still be protected by patent, even if there’s no copyright restriction on commercial entities using the code.
Re:Implementing the Elo Rating System (2020) by ummonk on Friday February 12, 2021 @04:34PM (#26118818)
Glicko
Re:Implementing the Elo Rating System (2020) by noxvilleza on Friday February 12, 2021 @06:28PM (#26119808)
Glicko (1 and 2) don't handle complex matchups well (as in, anything that's not 1v1). Trueskill was specifically designed to extend the Bayesian concept of Glicko in a more general way which allowed this type of use-case.
Re:Implementing the Elo Rating System (2020) by maybeOneDay on Friday February 12, 2021 @03:26PM (#26118165)
I accept your premise and the fact that matchmaking is hard but:

> You could, for example, play 100 matches where you were given the closest opponent but at a disadvantage for every single match.

not really, you'd derank aggressively and end up playing people at a lower level and presumably winning comfortably after some time.

Re:Implementing the Elo Rating System (2020) by jayd16 on Friday February 12, 2021 @03:39PM (#26118295)
It all depends on who happens to be playing the game to match with but you're right. Ideally you would quickly hit a good match and win.
Re:Implementing the Elo Rating System (2020) by smogcutter on Friday February 12, 2021 @05:05PM (#26119091)
One issue is that once you find your level, Elo should keep you around a 50/50 win rate. So it doesn’t feel like you’re making progress or improving even if in a real sense you are.

It’s also a bad fit for team games. But ranking individual contribution to a team is hard. Even for something like the NBA where there’s obviously a ton of incentive to do this, statistical methods rely on a large sample size and often need to be taken with a grain of salt.

Re:Implementing the Elo Rating System (2020) by Kranar on Friday February 12, 2021 @05:41PM (#26119394)
Most multiplayer games I know of, such as StarCraft, use a different score for single player and multiplayer games. You might have an amazing single player Elo score but a crappy multiplayer score and vice-versa.
Re:Implementing the Elo Rating System (2020) by tehjoker on Friday February 12, 2021 @03:16PM (#26118059)
That's what they do in Starcraft 2 with MMR.
Re:Implementing the Elo Rating System (2020) by buzzerbetrayed on Friday February 12, 2021 @03:11PM (#26118011)
Why is it shit and what system is better?
Re:Implementing the Elo Rating System (2020) by bitshiftfaced on Friday February 12, 2021 @02:17PM (#26117403)
> Eventually we came to the conclusion that they must be summing out Elo for the Elo of our matchmaking party rather than summing it.

I think I'm missing something. Could you rephrase this?

Re:Implementing the Elo Rating System (2020) by SamBam on Friday February 12, 2021 @02:21PM (#26117452)
*rather than averaging it, I assume.
Re:Implementing the Elo Rating System (2020) by chairmanwow1 on Friday February 12, 2021 @03:13PM (#26118038)
Yes. Thank you. *Averaging. Thought I caught all the mistakes.
Re:Implementing the Elo Rating System (2020) by jsight on Friday February 12, 2021 @02:15PM (#26117376)
How would that make a difference? Or were the party sizes different between you and your opponents?
Re:Implementing the Elo Rating System (2020) by nwallin on Friday February 12, 2021 @06:11PM (#26119660)
Players A and B are friends in real life and play a game together. Player A has a rating of 900 and Player B has a rating of 1100. They queue up as a team for a 2v2 match.

Players C and D and randos on the internet and solo queue for whatever. Player C has a rating of 1900 and Player D has a rating of 2100.

The matchmaking system tries to find a match for Players A and B to play against. Their Team Rating is 900+1100 = 2000, so it looks for another team rated around 2000 to play against. The matchmaking system finds a team rated 1000, and that's no good, and a team rated 3000, and that's no good either. It can't find a team rated 2000, so it goes to the fallback plan. It just tosses the team into the solo queue and lets the solo queue matchmaking system handle it.

The solo queue matchmaking system has a player with a rating of 1900, a player with a rating of 2100, and a ~~team~~ player with a rating of 2000. Perfect! It matches the ~~team~~ player with a 2000 rating against the 1900 and the 2100, which averages out to 2000.

Re:Implementing the Elo Rating System (2020) by chairmanwow1 on Friday February 12, 2021 @04:20PM (#26118674)
So our opponents were queueing as individuals and were highly skilled. So their “party Elo” was genuinely 2k. Parties would be selected to take place in a match (2v2 / 3v3 / 4v4) of similar party Elos.

We would either get paired with another couple 2k players against a full team of 2k (4v4 match) or in the worst case a 2v2 against 2k players.

In the 2v2 case, because of the Elo difference the opposing side was expected to win >99.99% of the time.

Re:Implementing the Elo Rating System (2020) by bitshiftfaced on Friday February 12, 2021 @04:46PM (#26118926)
Since there are an equal number of players on both teams, why would it matter if the system used the average or the sum of the players' Elo? Wouldn't both methods have the same outcome?
Re:Implementing the Elo Rating System (2020) by ivarv on Friday February 12, 2021 @02:24PM (#26117493)
Two players of similar skill would probably get creamed by a team with a large skill disparity.
Re:Implementing the Elo Rating System (2020) by jsight on Friday February 12, 2021 @03:47PM (#26118374)
I guess, but (making up numbers here) two players with 750 skill would be 1500 or an average of 750.

A sum might match them up against two players with 1300 skill & 200 skill due to the 1500 sum. OTOH, the average would match them up against... an average of 750, so the same people?

I'm sure I'm just missing something really fundamental about how this all works.

Re:Implementing the Elo Rating System (2020) by postalrat on Friday February 12, 2021 @05:45PM (#26119427)
They shouldn't be summing or averaging. They should be using the max elo of the players in your party for every member of your party.
Re:Implementing the Elo Rating System (2020) by hwjwill on Friday February 12, 2021 @03:30PM (#26118190)
I also noticed it when I play AoE: 2 DE as I only play multiplayer game. I initially thought it's just because there aren't enough players so they match us with someone else much higher. However I only notice it in Quick Play where ELO is not affected instead of Ranked games.