RogerMarsh / chesscalc

Calculate player performances from chess game results.
Other
0 stars 0 forks source link

Convert chesscalc to calculate player performances from game collections in PGN files. #1

Open RogerMarsh opened 7 months ago

RogerMarsh commented 7 months ago

Chesscalc will be converted to import game results from PGN files and calculate performances for populations of players selected by player or event and filtered by date played, time controls, and mode (over the board or online for example).

The existing calculation algorithm will be retained but the predictive stuff will be dropped.

The existing modules which support my chessresults project will be retained but not used in chesscalc.

RogerMarsh commented 5 months ago

Importing PGN within a transaction, where the database engine implements transactions, seems fast enough because there is no need to index games by position and piece location which is expensive.

RogerMarsh commented 4 months ago

Some optional PGN tags, defined in the PGN specification, can contribute to deciding how a game affects a player's rating. TimeControl, Mode, Termination, BlackType, and WhiteType, are usually missing from PGN files. Without them it is difficult to decide whether a game is 'over the board' or online; whether the time control is standard, rapid, or blitz; whether the players are human or computer; and whether the result was achieved in a way that does not count to rating, typically a default or a bye.

Chesscalc will hold what the PGN had to say on these, and separately an editable version of each which are used to decide.

Hopefully editing for each event (player for human or computer) or each game will be sufficient.

RogerMarsh commented 4 months ago

It seems too difficult to implement editing PGN tags within chesscalc compared with deleting the game headers imported from a PGN file, editing the PGN file, and re-importing the game headers.

It is certainly safe to delete the game headers if none of the 'Identify' actions have been done; or any that were done are reversed.

RogerMarsh commented 4 months ago

It is usually clear from eyeballing player and event names in the PGN tags whether a player is human or a computer. The BlackType and WhiteType tags formalize this, but are noticeably absent from the PGN files looked at even when a player is obviously a computer from the names.

The BlackType and WhiteType tag values must be added to those which contribute to the player identity.