home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 31 / CDASC_31_1996_juillet_aout.iso / vrac / ca2pgn2.zip / CA2PGN.DOC next >
Text File  |  1996-05-27  |  4KB  |  76 lines

  1. CA2PGN Version 0.2 (May 1996)
  2.  
  3.   This is a zero version of the CA to PGN converter. The program converts
  4. the Big Seven Tags only (Event, Site, Round, White, Black, Year, Result and 
  5. game score of course). I have chosen the following correspondence between CA and 
  6. PGN fields:
  7.  
  8.  CA         PGN
  9. Place    =>    Site
  10. Class    =>    Event
  11. White    =>    White (surprise, surprise)
  12. Black    =>    Black
  13. Year    =>    Year
  14. Score    =>    Result
  15. Game#    =>    Round
  16.  
  17. This choice contradicts slightly to that of the CA team, since PGN2CA converts
  18. Event => Place and ignores the Site field at all.
  19.  
  20. Syntax:
  21.  
  22. ca2pgn [-r range] [-i] [-m max_er] [-e er_base] filename.bfi
  23.  
  24. where 
  25.   "-r range" specifies a range of games to be converted. By default all the
  26.       database will be converted.
  27.   "-i" tells the program to ignore the conversion errors and continue 
  28.       the conversion. This option does not apply to file read/write errors.
  29.       Those errors will stop the program in any circumstances.
  30.   "-m max_er" specifies a maximal number of errors in a game before the program
  31.       gives up its conversion. Default value is 10. Some of the errors are
  32.       considered fatal, and conversion of the game stops before the maximum 
  33.       number has been reached. 
  34.   "--E er_base" specifies a database where all erroneous games will be extracted to.
  35.       The .bfi extension is mandatory in the base name.
  36.  
  37.   The program will create a PGN file filename.pgn, it means that the PGN 
  38. file will be created in the same directory where CA files are placed. If there 
  39. was a PGN file with the same name, it will be overwritten.
  40.  
  41.   I have assumed that all the games in a database are valid, and programs does
  42. not check the games for validity. Unfortunately, my assumption is not valid
  43. itself, and you can run into a case when a back conversion (PGN => CA) fails.
  44. It happens for example with the base all0394a from Internet Chess Library.
  45.  
  46.   I have tested the program on circa 150 000 CA games I got a hold on. I can 
  47. assure that after a back and forth conversion (CA => PGN => CA) the game scores
  48. were absolutely identical (whenever this back and forth conversion was possible). 
  49. But it is the only assurance I can give. As one can guess I have received no 
  50. support from the CA team (I did not ask for it either). It means that my 
  51. knowledge of the CA file formats is limited. For example, I do not know what 
  52. would happen, if LIB file is too big. I have assumed that any component of the 
  53. lib file (PlayerName, Place, Class, OpenningName, Annotator) takes less than 
  54. 1 M (1,047,553 to be precise). It is quite possible that this number is due
  55. to the bug in the PGN to CA converter, rather than an internal CA limit. Anyway,
  56. if somebody has such a big database, I would be very grateful if you 
  57. test the program with the database (just run it for a small range of games and
  58. program will tell you right away if your database is actually big :-) ).
  59.  
  60.   The converter does not keep a log, but you can easily redirect all the
  61. messages to a file. For example:
  62.  
  63. ca2pgn -i -e err_base.bfi my_base.bfi > my_base.log
  64.  
  65.  
  66.   Any bug reports are welcome. Please, send your comments and bug reports to
  67. nikulin@ee.umanitoba.ca. To make the things easier to me, please run the program
  68. with "-i -e err_base" options and include err_base (14 files :-) ) in your bug 
  69. report.
  70.  
  71. I will release the source code as soon as I comb it and make it UNIX compatible.
  72.  
  73. Hopefully you will find the program useful.
  74.  
  75. Alexander Nikulin.
  76.