Author: Tim Foden
Date: 05:44:47 02/12/02
Go up one level in this thread
On February 12, 2002 at 08:10:11, Peter Berger wrote: >On February 12, 2002 at 07:22:57, Tim Foden wrote: > >>On February 11, 2002 at 18:04:14, Peter Berger wrote: >> >>>Forgot the wishlist : none of them adds move numbers - is there another one that >>>does ? >> >>Where would you want the move numbers to be added? Is there an EPD opcode for >>them? > >I like the way it is done in FEN . > >Stolen from specification : > >Here's the FEN for the starting position: >rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1 > >And after the move 1. e4: >rnbqkbnr/pppppppp/8/8/4P3/8/PPPP1PPP/RNBQKBNR b KQkq e3 0 1 > >And then after 1. ... c5: >rnbqkbnr/pp1ppppp/8/2p5/4P3/8/PPPP1PPP/RNBQKBNR w KQkq c6 0 2 > >And then after 2. Nf3: >rnbqkbnr/pp1ppppp/8/2p5/4P3/5N2/PPPP1PPP/RNBQKB1R b KQkq - 1 2 > >For two kings on their home squares and a white pawn on e2 (White to move) with >thirty eight full moves played with five halfmoves since the last pawn move or >capture: >4k3/8/8/8/8/8/4P3/4K3 w - - 5 39 > >fmvn and hmvc are redundant information IMHO - so probably I am looking for an >PGN->FEN tranlator :-). But fmvn and hmvc are fine with me, too. I need it only >to find the moves to be analyzed. > >>... I guess I could look in the docs... fmvn -- full move number, and hmvc -- >>half move clock. >> >>So I guess that from input like this... >> >>[pgn headers] >> >>1. e4 d5 * >> >>... you are looking for output like this? >> >>rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - bm e4; fmvn 1; hmvc 0; >>rnbqkbnr/pppppppp/8/8/4P3/8/PPPP1PPP/RNBQKBNR b KQkq - bm d5; fmvn 1; hmvc 0; >>rnbqkbnr/ppp1pppp/8/3p4/4P3/8/PPPP1PPP/RNBQKBNR w KQkq - fmvn 2; hmvc 0; >> > >This would be nice - I prefer pm for the played(predicted) move as Koundinya >uses, because I want to use it on real games and add different moves that might >be better. > > >>(my position code only set EP if it is actually posible to capture EP). >> >>I could probably cobble a PGN to EPD in about half an hour, as I have code for >>reading PGN and code for spitting out FEN as part of my chess library. >> >>Cheers, Tim. > >This would be appreciated very much. > >Oh, btw: wishlists can easily be extended. If the tool could handle variations >in the PGN and add them to the FEN/EPD set, too - this would be even nicer :-). > >Cheers, >pete OK. I have made a simple PGN to FEN converter. It takes PGN file as input, and outputs a list of FEN records to stdout. It only outputs the main line. It has no options as yet. It deals with the en-passant square in the same way as Remi's. Do you want me to e-mail it to you (92K zip file), or would you prefer that I stick it on my web site? Cheers, Tim.
This page took 0.01 seconds to execute
Last modified: Thu, 15 Apr 21 08:11:13 -0700
Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.