Well, your game is interesting too, and the Anti-Meran Gambit is a good example of an opening you don't want to go into without book knowledge (and I don't mean a 15-ply search).no, it does not have that opening
--Jon
Moderators: hgm, Rebel, chrisw
Well, your game is interesting too, and the Anti-Meran Gambit is a good example of an opening you don't want to go into without book knowledge (and I don't mean a 15-ply search).no, it does not have that opening
Oh indeed! That's surprising. I've been using that code for ages. Well, that explains a few things.syzygy wrote:So the problem obviously is that you are not hashing in en passant rights.flok wrote:I looked at one and it looks like this:
Code: Select all
mysql> select * from entries where hash=-9221985131600632708; +----------------------------------------------------------------+----------------------+-------+------+ | fen | hash | plies | eval | +----------------------------------------------------------------+----------------------+-------+------+ | rnbqkbnr/1ppppp1p/8/p5p1/1P1P4/6P1/P1P1PP1P/RNBQKBNR b KQkq - | -9221985131600632708 | 15 | 23 | | rnbqkbnr/1ppppp1p/8/p5p1/1P1P4/6P1/P1P1PP1P/RNBQKBNR b KQkq b3 | -9221985131600632708 | 16 | 29 | | rnbqkbnr/1ppppp1p/8/p5p1/1P1P4/6P1/P1P1PP1P/RNBQKBNR b KQkq d3 | -9221985131600632708 | 16 | 23 | +----------------------------------------------------------------+----------------------+-------+------+ 3 rows in set (2.23 sec)
Well for pawn, rook and king I have a bit that says "first move". So my 64x12 table is in my situation 64x32: 3 bit for piece-type, 1 bit for first move and 1 for color.It seems likely that you are also not hashing in castling rights. That will give even more collisions.
Code: Select all
class CpFSS
{
public:
void Reset(void);
void LoadFromFSS(const FSS& fss);
void StoreToFSS(FSS& fss) const;
Color GetGood(void) const {return (Color) good;}
Color GetEvil(void) const {return (Color) evil;}
Cabs GetCabs(void) const {return (Cabs) cabs;}
Sq GetEpSq(void) const {return (Sq) epsq;}
ui GetHmvc(void) const {return (ui) hmvc;}
ui GetFmvn(void) const {return (ui) fmvn;}
void PutGood(const Color color) {good = (si8) color;}
void PutEvil(const Color color) {evil = (si8) color;}
void PutCabs(const Cabs value) {cabs = (Cabs) value;}
void PutEpSq(const Sq sq) {epsq = (Sq) sq;}
void PutHmvc(const ui value) {hmvc = (ui16) value;}
void PutFmvn(const ui value) {fmvn = (ui16) value;}
private:
si8 good; // Active color
si8 evil; // Passive color
ui8 cabs; // Castling availability bits
si8 epsq; // En passant target square (may be nil)
ui16 hmvc; // Half move counter
ui16 fmvn; // Full move number
};
#define CpBoardLen (SqLen / 2)
class CpBoard
{
public:
void Reset(void);
void LoadFromBoard(const Board& board);
void StoreToBoard(Board& board) const;
Man GetMan(const Sq sq) const;
void PutMan(const Sq sq, const Man man);
private:
void ResetSq(const Sq sq) {PutMan(sq, ManVacant);}
ui8 bvec[CpBoardLen];
};
class CpFEN
{
public:
void Reset(void);
private:
CpFSS cpfss;
CpBoard cpboard;
}
Code: Select all
Man CpBoard::GetMan(const Sq sq) const
{
return (Man) ((bvec[sq / 2] >> ((sq % 2) * 4)) & 0x0f);
}
void CpBoard::PutMan(const Sq sq, const Man man)
{
bvec[sq / 2] &= ~(MX(4) << ((sq % 2) * 4));
bvec[sq / 2] |= (((ui8) man) << ((sq % 2) * 4));
}
In normal chess, how do you use the first-move bit for pawn? Maybe saving a bit today is not very important, but you can still use 4 bits for all the information, instead of 5, just adding a piece type "never moved rook" and "never moved king", so to have 8 piece types (3 bit) plus 1 bit for color. One bit less means two pieces in a byte, instead a byte+1/4 of a byte...flok wrote:[...]
Well for pawn, rook and king I have a bit that says "first move". So my 64x12 table is in my situation 64x32: 3 bit for piece-type, 1 bit for first move and 1 for color.
Thanks!
I am going to have to delve into your opening position more deeply.jdart wrote:Well, your game is interesting too, and the Anti-Meran Gambit is a good example of an opening you don't want to go into without book knowledge (and I don't mean a 15-ply search).no, it does not have that opening
--Jon
That appears to be a novelty, and possibly a good one.I have Qc8 as best
I have one game with that move choice, but it departed from the pv pretty quickly:jdart wrote:That appears to be a novelty, and possibly a good one.I have Qc8 as best
In a more recent Karjakin-Carlsen game, Carlsen played .. a5, but that could have been partly to avoid his opponent's preparation.
--Jon
Code: Select all
[Event "RT.2006.0.00001"]
[Site "LSS"]
[Date "2006.04.15"]
[Round "53.264"]
[White "Schuster, Peter"]
[Black "Guzman, Carlos M"]
[Result "1-0"]
[ECO "B78q"]
[Variation "Sicilian: Dragon, Yugoslav, Main Line, 12.h4 h5 13.Bg5 Rc5 14.Kb1"]
[Source "Chess Mail Ltd"]
1.e4 c5 2.Nf3 d6 3.d4 cxd4 4.Nxd4 Nf6 5.Nc3 g6 6.Be3 Bg7 7.f3 O-O 8.Qd2 Nc6
9.Bc4 Bd7 10.h4 Rc8 11.Bb3 h5 12.O-O-O Ne5 13.Bg5 Rc5 14.Kb1 Re8 15.Bh6 Qc8
{
suggested pv was:
Bxg7 Kxg7 [b]Nd5 Nxd5 Bxd5[/b] ...
Game actually continued as:
Bxg7 Kxg7[b] Rhe1 b5 f4[/b] ...
}
16.Bxg7 Kxg7 17.Rhe1 b5 18.f4 Neg4 19.Nf3 Qc7 20.Ng5 b4 21.Ne2 Nf2 22.Bxf7 N6xe4
23.Qxb4 a5 24.Qd4+ e5 25.fxe5 Rexe5 26.Bb3 a4 27.Nxe4 axb3 28.Nxc5 bxc2+
29.Kxc2 Bf5+ 30.Kc1 Nxd1 31.Rxd1 Kh7 32.Nc3 Rxc5 33.g3 d5 34.Qe3 Be4 35.Rd4 Rc6
36.Kd2 Rf6 37.Nxe4 dxe4 38.Rxe4 Qa5+ 39.Qc3 Qd5+ 40.Qd4 Qa5+ 41.Kc2 Qc7+
42.Qc4 Qxg3 43.a4 1-0
The more statistical and analysis information you can pack into your book the better. You should also update it with live information.flok wrote:What I'm wondering: does it make sense for an openingbook to fill it with a quiescence search? Because the number of nodes explodes a bit with that
In that case it seem you're assigning different hash keys to identical positions.flok wrote:Well for pawn, rook and king I have a bit that says "first move". So my 64x12 table is in my situation 64x32: 3 bit for piece-type, 1 bit for first move and 1 for color.It seems likely that you are also not hashing in castling rights. That will give even more collisions.