Python script for TTM
Moderators: hgm, Rebel, chrisw
-
- Posts: 334
- Joined: Sat Feb 25, 2012 10:42 pm
- Location: Stockholm
Re: Python script for TTM
I am glad that you for once listned to me even though you quoted yourself
-
- Posts: 216
- Joined: Sun Apr 13, 2014 5:19 pm
Re: Python script for TTM
Fitting such variables (categorical) that obey a multinomial distribution with Monte Carlo methods (actually MCMC - Markov Chain Monte Carlo) is a widely used approach when we have more than one random effects. In the case of chess game results, however, we can take pairs of games (white and black from the same opening) and have 5 categories which fit the pentanomial distribution. Such variables are fit through a logit model (logistic regression). We have only one random effect (openings) and the resulting linear mixed effects model is better fit with the Laplace approximation (rather than MCMC), or even more accurately - with the adaptive Gauss-Hermite quadrature method.
-
- Posts: 216
- Joined: Sun Apr 13, 2014 5:19 pm
Re: Python script for TTM
On the other hand one can use cumulative logit model and obtain a binomial distribution which can greatly simplify the logistic regression (one logistic curve vs. j-1 logistic curves). The 5 categories (-2,-1,0,1,2) can be made only 2 by substituting category =< 0 with 0 and category > 0 with 1. Then the logit will become a simple LLR which we try to maximize.
-
- Posts: 216
- Joined: Sun Apr 13, 2014 5:19 pm
Re: Python script for TTM
Retract the above post. Binomial with 0,1 would skew the distribution towards 0. If we want to diminish the categories, we can try with -1,0,1.
-
- Posts: 349
- Joined: Sat Aug 06, 2016 8:31 pm
- Location: United States
Re: Python script for TTM
Old post, I know... Hope it's OK that I resurrect it.
This would be great.lucasart wrote:I'm thinking of writing a Python script for TTM (Texel Tuning Method), that would be completely external to the engine, based on UCI interaction only. This would finally make TTM easily available to every UCI engine, without any need to write all the boiler plate code inside the engine.
Perhaps if you understand the math.lucasart wrote:PS: TTM is well explained in the Chess Programming Wiki.
Did this come to pass?Ferdy wrote: I have such script with concurrency support too and plan to put it in github, but I need to clean/refactor it first and have no time for this at the moment. Perhaps last week of November.
-
- Posts: 3232
- Joined: Mon May 31, 2010 1:29 pm
- Full name: lucasart
Re: Python script for TTM
What are you talking about? The observable variable is numeric, not categorial. The values are 0, 0.5, 1. We certainly do not want to treat it as categorial!lantonov wrote:Fitting such variables (categorical) that obey a multinomial distribution with Monte Carlo methods (actually MCMC - Markov Chain Monte Carlo) is a widely used approach when we have more than one random effects. In the case of chess game results, however, we can take pairs of games (white and black from the same opening) and have 5 categories which fit the pentanomial distribution. Such variables are fit through a logit model (logistic regression). We have only one random effect (openings) and the resulting linear mixed effects model is better fit with the Laplace approximation (rather than MCMC), or even more accurately - with the adaptive Gauss-Hermite quadrature method.
As for the rest, it sounds like master-class posing to me. Piling up buzz words to impress everyone. Care to write some code, and produce some results? Or are you going to give us some books to read?
Theory and practice sometimes clash. And when that happens, theory loses. Every single time.
-
- Posts: 349
- Joined: Sat Aug 06, 2016 8:31 pm
- Location: United States
Re: Python script for TTM
Anyone know whether Ferdinand's Python script was ever released or maybe another has since been created for the purpose of Texel tuning any engine? Thanks.
-
- Posts: 4833
- Joined: Sun Aug 10, 2008 3:15 pm
- Location: Philippines
Re: Python script for TTM
This is not released yet.zenpawn wrote:Anyone know whether Ferdinand's Python script was ever released or maybe another has since been created for the purpose of Texel tuning any engine? Thanks.