Popular opening books

Discussion of anything and everything relating to chess playing software and machines.

Moderators: hgm, Rebel, chrisw

User avatar
Guenther
Posts: 4606
Joined: Wed Oct 01, 2008 6:33 am
Location: Regensburg, Germany
Full name: Guenther Simon

Re: Popular opening books

Post by Guenther »

Graham Banks wrote: Tue Aug 28, 2018 10:20 am
Guenther wrote: Tue Aug 28, 2018 10:17 am
Graham Banks wrote: Tue Aug 28, 2018 9:17 am I can't successfully convert Dann's epd into a pgn file suitable to be read and used.

Comes out like this:

[Event "Computer Chess Test Suite"]
[Site "EPD2diag V1.5"]
[Date "2018.08.28"]
[Round "?"]
[White "?"]
[Black "Qe3"]
[Result "*"]
[SetUp "1"]
[FEN "1k1r2nr/1pp1bpp1/p1p2q2/4p2p/4P1b1/3P1N1P/PPPNQPP1/R1B1R1K1 w - - acd 36; 0 1"]

1.*
There will be no other way. All tools which convert epd to pgn create the pgn headers and a fen tag.
It is (nearly) impossible to construct a pgn which contains all possible moves until the final epd position
due to bazillions of transpositions.

Normally all programs, which read pgn should read the one you showed above.
Are you sure ChessGUI cannot read above valid pgn example?
Doesn't seem to.
Looking again at the FEN tag I believe the 'acd $value' should be removed.
Could you try a small sample w/o it?

e.g.
[FEN "1k1r2nr/1pp1bpp1/p1p2q2/4p2p/4P1b1/3P1N1P/PPPNQPP1/R1B1R1K1 w - - 0 1"]
https://rwbc-chess.de

trollwatch:
Chessqueen + chessica + AlexChess + Eduard + Sylwy
User avatar
Graham Banks
Posts: 41424
Joined: Sun Feb 26, 2006 10:52 am
Location: Auckland, NZ

Re: Popular opening books

Post by Graham Banks »

Guenther wrote: Tue Aug 28, 2018 10:44 amLooking again at the FEN tag I believe the 'acd $value' should be removed.
Could you try a small sample w/o it?

e.g.
[FEN "1k1r2nr/1pp1bpp1/p1p2q2/4p2p/4P1b1/3P1N1P/PPPNQPP1/R1B1R1K1 w - - 0 1"]
Still no joy, but I appreciate your trying to help.
gbanksnz at gmail.com
User avatar
Guenther
Posts: 4606
Joined: Wed Oct 01, 2008 6:33 am
Location: Regensburg, Germany
Full name: Guenther Simon

Re: Popular opening books

Post by Guenther »

Graham Banks wrote: Tue Aug 28, 2018 11:00 am
Guenther wrote: Tue Aug 28, 2018 10:44 amLooking again at the FEN tag I believe the 'acd $value' should be removed.
Could you try a small sample w/o it?

e.g.
[FEN "1k1r2nr/1pp1bpp1/p1p2q2/4p2p/4P1b1/3P1N1P/PPPNQPP1/R1B1R1K1 w - - 0 1"]
Still no joy, but I appreciate your trying to help.
Hmmm can you try this one below?
This is done with a little macro and yace epdtest utility which also creates valid pgn.
I noticed though that it does not produce the 'Setup' tag and still I could load it in all GUIs
I tested e.g. LucasChess, WB, etc.
(note that it is created from the popbooksmi-epd mentioned above)

http://rwbc-chess.de/Downloads/popbkm.zip

You can see that even the pgn generator from talkchess can read it :)
(I added the first three games from the pgn)
This means if ChessGUI cannot read it this time I am running out of ideas.

[pgn] [Event "1:popbkm.epd"] [Site "?"] [Date "????.??.??"] [Round "?"] [White "?"] [Black "?"] [Result "*"] [FEN "r4rk1/1ppnqppp/p2bpn2/3pN1B1/3P4/2NQP3/PPP2PPP/2KR3R w - - 0 1"] 1. * [Event "2:popbkm.epd"] [Site "?"] [Date "????.??.??"] [Round "?"] [White "?"] [Black "?"] [Result "*"] [FEN "r2q1rk1/ppp1bp1p/3p1np1/n3p3/2B1P3/2NPBP2/PPPQ1P1P/2KR2R1 w - - 0 1"] 1. * [Event "3:popbkm.epd"] [Site "?"] [Date "????.??.??"] [Round "?"] [White "?"] [Black "?"] [Result "*"] [FEN "2kr1bnr/pppq2pp/2n5/3pp3/6b1/2P2NP1/PP2PPBP/RNBQR1K1 w - - 0 1"] 1. *[/pgn]
https://rwbc-chess.de

trollwatch:
Chessqueen + chessica + AlexChess + Eduard + Sylwy
Ferdy
Posts: 4833
Joined: Sun Aug 10, 2008 3:15 pm
Location: Philippines

Re: Popular opening books

Post by Ferdy »

Graham Banks wrote: Tue Aug 28, 2018 8:18 am How can I convert from epd into pgn?
Try Norman Pollocks epdtool called epdconvert.

Code: Select all

epdconvert.exe your_file.epd
First be aware of using this tool, if your epd has a bm at the front,
8/8/B7/2k2B2/3n4/B2K4/8/7b b - - bm Kb6;

It will put that bm in the first move in pgn.

Code: Select all

[Event "?"]
[Site "?"]
[Date "????.??.??"]
[Round "3"]
[White "?"]
[Black "?"]
[Result "*"]
[SetUp "1"]
[FEN "8/8/B7/2k2B2/3n4/B2K4/8/7b b - - 0 1"]

1. ... Kb6! *
So it depends on what you want to use with the pgn output.

Second this tool does not convert the hmvc - half move clock into the FEN. Example given epd,
8/5B2/8/6K1/3k3B/3b4/7q/4B3 w - - bm Bhf2+; hmvc 95; fmvn 120;

Code: Select all

[Event "?"]
[Site "?"]
[Date "????.??.??"]
[Round "4"]
[White "?"]
[Black "?"]
[Result "*"]
[SetUp "1"]
[FEN "8/5B2/8/6K1/3k3B/3b4/7q/4B3 w - - 0 1"]

1. Bhf2+! *
It should have been

Code: Select all

[FEN "8/5B2/8/6K1/3k3B/3b4/7q/4B3 w - - 95 120"]
This is important for positions with 50 move draw rule concerns.

If this does not work for you, I will create a tool to convert it.
User avatar
Graham Banks
Posts: 41424
Joined: Sun Feb 26, 2006 10:52 am
Location: Auckland, NZ

Re: Popular opening books

Post by Graham Banks »

Ferdy wrote: Tue Aug 28, 2018 11:20 am
Graham Banks wrote: Tue Aug 28, 2018 8:18 am How can I convert from epd into pgn?
Try Norman Pollocks epdtool called epdconvert.

Code: Select all

epdconvert.exe your_file.epd
First be aware of using this tool, if your epd has a bm at the front,
8/8/B7/2k2B2/3n4/B2K4/8/7b b - - bm Kb6;

It will put that bm in the first move in pgn.

Code: Select all

[Event "?"]
[Site "?"]
[Date "????.??.??"]
[Round "3"]
[White "?"]
[Black "?"]
[Result "*"]
[SetUp "1"]
[FEN "8/8/B7/2k2B2/3n4/B2K4/8/7b b - - 0 1"]

1. ... Kb6! *
So it depends on what you want to use with the pgn output.

Second this tool does not convert the hmvc - half move clock into the FEN. Example given epd,
8/5B2/8/6K1/3k3B/3b4/7q/4B3 w - - bm Bhf2+; hmvc 95; fmvn 120;

Code: Select all

[Event "?"]
[Site "?"]
[Date "????.??.??"]
[Round "4"]
[White "?"]
[Black "?"]
[Result "*"]
[SetUp "1"]
[FEN "8/5B2/8/6K1/3k3B/3b4/7q/4B3 w - - 0 1"]

1. Bhf2+! *
It should have been

Code: Select all

[FEN "8/5B2/8/6K1/3k3B/3b4/7q/4B3 w - - 95 120"]
This is important for positions with 50 move draw rule concerns.

If this does not work for you, I will create a tool to convert it.
Thanks Ferdy. I'll try this tool first.
gbanksnz at gmail.com
User avatar
Graham Banks
Posts: 41424
Joined: Sun Feb 26, 2006 10:52 am
Location: Auckland, NZ

Re: Popular opening books

Post by Graham Banks »

No luck using the epdConvert tool.
Perhaps Dann could just provide a PGN in addition to the epd.
gbanksnz at gmail.com
User avatar
Guenther
Posts: 4606
Joined: Wed Oct 01, 2008 6:33 am
Location: Regensburg, Germany
Full name: Guenther Simon

Re: Popular opening books

Post by Guenther »

Graham Banks wrote: Tue Aug 28, 2018 11:44 am No luck using the epdConvert tool.
Perhaps Dann could just provide a PGN in addition to the epd.
Have you already tried my last attempt which converted the whole
popbooks-mi.epd into pgn?
https://rwbc-chess.de

trollwatch:
Chessqueen + chessica + AlexChess + Eduard + Sylwy
User avatar
Graham Banks
Posts: 41424
Joined: Sun Feb 26, 2006 10:52 am
Location: Auckland, NZ

Re: Popular opening books

Post by Graham Banks »

Guenther wrote: Tue Aug 28, 2018 11:47 am
Graham Banks wrote: Tue Aug 28, 2018 11:44 am No luck using the epdConvert tool.
Perhaps Dann could just provide a PGN in addition to the epd.
Have you already tried my last attempt which converted the whole
popbooks-mi.epd into pgn?
Hi Guenther.
I will try in the morning (my time).
gbanksnz at gmail.com
Ferdy
Posts: 4833
Joined: Sun Aug 10, 2008 3:15 pm
Location: Philippines

Re: Popular opening books

Post by Ferdy »

Graham Banks wrote: Tue Aug 28, 2018 11:44 am No luck using the epdConvert tool.
Perhaps Dann could just provide a PGN in addition to the epd.
It seems Chessgui has the tool.

Image

Try to find a big pgn file as your Pgn Input File. Every pos in epd file will be searched in the input pgn file. If it is there it will save the moves in sequence in pgn format. If not found it will still save in pgn format but using the FEN Tag as was used in epdconvert.
[Event "?"]
[Site "?"]
[Date "????.??.??"]
[Round "2834"]
[White "?"]
[Black "?"]
[Result "*"]
[SetUp "1"]
[FEN "r2qkbnr/1pp2pp1/p1p5/4p2p/4P1b1/5N1P/PPPP1PP1/RNBQ1RK1 w kq - 0 1"]

*

[Event "Third World War"]
[Site "ChessGUI"]
[Date "????.??.??"]
[Round "?"]
[White "?"]
[Black "?"]
[Result "*"]
[WhiteElo "2740"]
[BlackElo "2775"]
[Variant "normal"]

1.e4 c6 2.d4 d5 3.Nd2 dxe4 4.Nxe4 Nd7 *
User avatar
Graham Banks
Posts: 41424
Joined: Sun Feb 26, 2006 10:52 am
Location: Auckland, NZ

Re: Popular opening books

Post by Graham Banks »

Ferdy wrote: Tue Aug 28, 2018 12:43 pm
Graham Banks wrote: Tue Aug 28, 2018 11:44 am No luck using the epdConvert tool.
Perhaps Dann could just provide a PGN in addition to the epd.
It seems Chessgui has the tool.

Image

Try to find a big pgn file as your Pgn Input File. Every pos in epd file will be searched in the input pgn file. If it is there it will save the moves in sequence in pgn format. If not found it will still save in pgn format but using the FEN Tag as was used in epdconvert.
[Event "?"]
[Site "?"]
[Date "????.??.??"]
[Round "2834"]
[White "?"]
[Black "?"]
[Result "*"]
[SetUp "1"]
[FEN "r2qkbnr/1pp2pp1/p1p5/4p2p/4P1b1/5N1P/PPPP1PP1/RNBQ1RK1 w kq - 0 1"]

*

[Event "Third World War"]
[Site "ChessGUI"]
[Date "????.??.??"]
[Round "?"]
[White "?"]
[Black "?"]
[Result "*"]
[WhiteElo "2740"]
[BlackElo "2775"]
[Variant "normal"]

1.e4 c6 2.d4 d5 3.Nd2 dxe4 4.Nxe4 Nd7 *
Thanks Ferdy. I was unsure how to use the PGN input for this.
I am giving it a go now and it seems to be working okay. :)
gbanksnz at gmail.com