pairedit.cc

PiecePairEvalTable に人為的に手を加える. [詳細]

#include "osl/eval/ppair/piecePairRawEval.h"
#include <boost/scoped_ptr.hpp>
#include <iostream>
#include <cstdlib>
#include <cstdio>
#include <unistd.h>
pairedit.ccのインクルード依存関係図

ソースコードを見る。

関数

void usage (const char *prog)
void adjust (PiecePairRawTable &table, Position pos1, PtypeO ptypeo1, Position pos2, PtypeO ptypeo2, int value)
void adjustKingBonus (PiecePairRawTable &table, Position pos1, PtypeO ptypeo1, Position pos2, PtypeO ptypeo2, int bonus)
void adjustDual (PiecePairRawTable &table, Position king, Position attacker, Ptype attackerType, int blackAttackBonus, int whiteAttackBonus)
 king: white, attacker: black
void adjustDual (PiecePairRawTable &table, Position black, Ptype black_ptype, Position white, Ptype white_ptype, int value)
void addValue (Player player, PiecePairRawTable &table, Position pos1, Ptype ptype1, Position pos2, Ptype ptype2, int bonus)
void addPenalty (Player player, PiecePairRawTable &table, Position pos1, Ptype ptype1, Position pos2, Ptype ptype2, int bonus)
void addBonus (Player player, PiecePairRawTable &table, Position pos1, Ptype ptype1, Position pos2, Ptype ptype2, int bonus)
void addPenaltyDual (PiecePairRawTable &table, Position pos1, Ptype ptype1, Position pos2, Ptype ptype2, int black_bonus)
void addSelfPenaltyDual (PiecePairRawTable &table, Position pos, Ptype ptype, int black_bonus)
int main (int argc, char **argv)

変数

bool verbose = false

説明

PiecePairEvalTable に人為的に手を加える.

試しに,玉の周り5x5 端では4x4 にいる敵の駒を+100してみる 歩桂香は玉より下では加点しない,代わりに上を延ばす 下にいる金は半分? 頂点は半分?

参考 http://www32.ocn.ne.jp/~yss/book.html#SEC3 桂、香の駒は玉が実際の位置よりももう1段上にいるとして計算している(桂香では敵玉から3段上が最大となる)

pairedit.cc で定義されています。


関数

void addBonus ( Player  player,
PiecePairRawTable &  table,
Position  pos1,
Ptype  ptype1,
Position  pos2,
Ptype  ptype2,
int  bonus 
)

pairedit.cc117 行で定義されています。

参照先 addValue(), と osl::eval::betterThan().

参照元 main().

void addPenalty ( Player  player,
PiecePairRawTable &  table,
Position  pos1,
Ptype  ptype1,
Position  pos2,
Ptype  ptype2,
int  bonus 
)

pairedit.cc108 行で定義されています。

参照先 addValue(), と osl::eval::betterThan().

参照元 addPenaltyDual(), と main().

void addPenaltyDual ( PiecePairRawTable &  table,
Position  pos1,
Ptype  ptype1,
Position  pos2,
Ptype  ptype2,
int  black_bonus 
)

pairedit.cc126 行で定義されています。

参照先 addPenalty(), osl::BLACK, と osl::WHITE.

参照元 addSelfPenaltyDual().

void addSelfPenaltyDual ( PiecePairRawTable &  table,
Position  pos,
Ptype  ptype,
int  black_bonus 
)

pairedit.cc136 行で定義されています。

参照先 addPenaltyDual().

参照元 main().

void addValue ( Player  player,
PiecePairRawTable &  table,
Position  pos1,
Ptype  ptype1,
Position  pos2,
Ptype  ptype2,
int  bonus 
)

pairedit.cc98 行で定義されています。

参照先 adjust(), と osl::newPtypeO().

参照元 addBonus(), と addPenalty().

void adjust ( PiecePairRawTable &  table,
Position  pos1,
PtypeO  ptypeo1,
Position  pos2,
PtypeO  ptypeo2,
int  value 
)

pairedit.cc37 行で定義されています。

参照先 osl::Position::isOnBoard(), osl::eval::max(), osl::eval::min(), と verbose.

参照元 addValue(), adjustDual(), adjustKingBonus(), と main().

void adjustDual ( PiecePairRawTable &  table,
Position  black,
Ptype  black_ptype,
Position  white,
Ptype  white_ptype,
int  value 
)

pairedit.cc87 行で定義されています。

参照先 adjust(), osl::BLACK, osl::newPtypeO(), osl::Position::rotate180(), と osl::WHITE.

void adjustDual ( PiecePairRawTable &  table,
Position  king,
Position  attacker,
Ptype  attackerType,
int  blackAttackBonus,
int  whiteAttackBonus 
)

king: white, attacker: black

pairedit.cc75 行で定義されています。

参照先 adjustKingBonus(), osl::BLACK, osl::KING, osl::newPtypeO(), osl::Position::rotate180(), と osl::WHITE.

参照元 main().

void adjustKingBonus ( PiecePairRawTable &  table,
Position  pos1,
PtypeO  ptypeo1,
Position  pos2,
PtypeO  ptypeo2,
int  bonus 
)

pairedit.cc61 行で定義されています。

参照先 adjust(), osl::BLACK, osl::getOwner(), osl::getPtype(), と osl::KING.

参照元 adjustDual(), と main().

int main ( int  argc,
char **  argv 
)
void usage ( const char *  prog  ) 

pairedit.cc27 行で定義されています。


変数

bool verbose = false

pairedit.cc35 行で定義されています。

 全て クラス ネームスペース ファイル 関数 変数 型定義 列挙型 列挙型の値 フレンド マクロ定義
Sun May 16 09:55:37 2010に生成されました。  doxygen 1.6.3