#include <piecePair.h>
Classes | |
struct | IndexTable |
Public Types | |
enum | { plain_table_size = 1338, x_table_size = 4901, y_table_size = 7057, DIM = plain_table_size + x_table_size + y_table_size } |
typedef CArray< int, 3 > | index_t |
Public Member Functions | |
template<int Direction, int Offset> | |
int | sum12One (const Piece *base_ptr, const int *xbase, const int *ybase) |
template<int Direction, int Offset> | |
int | adjust12One (const Piece *base_ptr, const int *xbase1, const int *ybase1, const int *xbase2, const int *ybase2) |
Static Public Member Functions | |
static int | eval (const NumEffectState &, const Weights &) |
template<int Direction, int Offset> | |
static int | sum12One (const Piece *basePtr, const int *xbase, const int *ybase) |
static int | sum12 (NumEffectState const &state, Square base, PtypeO ptypeO) |
template<int Direction, int Offset> | |
static int | adjust12One (const Piece *basePtr, const int *xbase1, const int *ybase1, const int *xbase2, const int *ybase2) |
static int | adjust12 (NumEffectState const &state, Square base, PtypeO pos, PtypeO neg) |
static int | evalWithUpdate (const NumEffectState &state, Move moved, int last_value, const Weights &values) |
static int | evalWithUpdateCompiled (const NumEffectState &state, Move moved, int last_value) |
static int | pieceValue (const NumEffectState &state, Piece p, const Weights &values) |
static int | pieceValueDouble (const NumEffectState &state, Piece p, const Weights &) |
static int | weight (Player attack, int index, const Weights &values) |
static index_t | index (int offset_id, Piece p, Piece q) |
static index_t | index (int offset_id, Square p0, PtypeO o0, Square p1, PtypeO o1) |
static int | value (int offset_id, Piece p, Piece q, const Weights &values) |
static int | value (int offset_id, Piece p, Square p1, PtypeO o1, const Weights &values) |
static int | value (int offset_id, Square p0, PtypeO o0, Square p1, PtypeO o1, const Weights &values) |
static void | init () |
static void | sanitize (Weights &values) |
static void | compile (const Weights &values) |
values を展開してクラス全体で使う More... | |
static int | valueCompiled (int offset_id, Piece p, Square p1, PtypeO o1) |
static int | valueCompiled (int offset_id, Square p0, PtypeO o0, Square p1, PtypeO o1) |
Static Public Attributes | |
static IndexTable | plain_table |
static CArray< IndexTable, 10 > | x_table |
static CArray< IndexTable, 10 > | y_table |
static const CArray< const Offset, 12 > | offsets |
Definition at line 18 of file piecePair.h.
typedef CArray<int,3> osl::eval::ml::PiecePair::index_t |
Definition at line 45 of file piecePair.h.
anonymous enum |
Enumerator | |
---|---|
plain_table_size | |
x_table_size | |
y_table_size | |
DIM |
Definition at line 21 of file piecePair.h.
|
inlinestatic |
Definition at line 573 of file piecePair.cc.
References osl::ptypeOIndex(), osl::Square::x(), osl::eval::ml::ppair::x_values, osl::Square::y(), and osl::eval::ml::ppair::y_values.
|
static |
|
inline |
Definition at line 561 of file piecePair.cc.
References osl::Piece::ptypeO(), osl::eval::ml::ppair::x_values, and osl::eval::ml::ppair::y_values.
|
static |
values を展開してクラス全体で使う
Definition at line 366 of file piecePair.cc.
References osl::eval::ml::ppair::plain_table, osl::PTYPEO_SIZE, osl::eval::ml::Weights::value(), osl::eval::ml::ppair::x_table, osl::eval::ml::ppair::x_values, osl::eval::ml::ppair::y_table, and osl::eval::ml::ppair::y_values.
Referenced by osl::eval::ml::OpenMidEndingEval::doResetWeights().
|
static |
Definition at line 451 of file piecePair.cc.
References osl::Piece::SIZE.
Referenced by osl::eval::ml::OpenMidEndingEval::OpenMidEndingEval().
|
static |
Definition at line 462 of file piecePair.cc.
References osl::Move::capturePtypeO(), osl::Move::from(), osl::Offset::index(), osl::Move::isCapture(), osl::Move::isPass(), osl::Piece::isPiece(), osl::Square::isPieceStand(), osl::eval::ml::ppair::offset_index, osl::Move::oldPtypeO(), osl::Move::ptypeO(), osl::Piece::square(), target, and osl::Move::to().
|
static |
Definition at line 596 of file piecePair.cc.
References osl::Move::capturePtypeO(), osl::Move::from(), osl::Move::isCapture(), osl::Square::isPieceStand(), osl::eval::ml::ppair::offset_index, osl::Move::oldPtypeO(), osl::Move::ptypeO(), osl::ptypeOIndex(), osl::Move::to(), osl::Square::x(), osl::eval::ml::ppair::x_values, osl::Square::y(), and osl::eval::ml::ppair::y_values.
Referenced by osl::eval::ml::OpenMidEndingEval::updateSub().
|
static |
Definition at line 441 of file piecePair.cc.
References osl::Piece::isOnBoard(), osl::Piece::isPiece(), osl::Piece::ptypeO(), and osl::Piece::square().
Referenced by value().
|
static |
Definition at line 421 of file piecePair.cc.
References osl::Square::isPieceStand(), osl::eval::ml::ppair::plain_table, osl::ptypeOIndex(), osl::Square::x(), osl::eval::ml::ppair::x_table, osl::Square::y(), and osl::eval::ml::ppair::y_table.
|
static |
Definition at line 353 of file piecePair.cc.
References osl::eval::ml::ppair::makeOffsetIndex(), osl::eval::ml::ppair::makeTable(), osl::eval::ml::ppair::makeTableX(), and osl::eval::ml::ppair::makeTableY().
Referenced by osl::eval::ml::OpenMidEndingEval::doResetWeights().
|
static |
Definition at line 670 of file piecePair.cc.
|
static |
Definition at line 651 of file piecePair.cc.
References osl::Piece::isOnBoard(), osl::Piece::isPiece(), osl::Square::isPieceStand(), osl::Piece::square(), and target.
|
static |
Definition at line 397 of file piecePair.cc.
References osl::BLACK, osl::Square::isOnBoard(), osl::isPiece(), osl::newPtypeO(), osl::PTYPE_MAX, osl::PTYPE_PIECE_MIN, osl::eval::ml::Weights::setValue(), and osl::WHITE.
Referenced by osl::eval::ml::OpenMidEndingEval::doResetWeights().
|
inlinestatic |
Definition at line 539 of file piecePair.cc.
References osl::ptypeOIndex(), osl::Square::x(), osl::eval::ml::ppair::x_values, osl::Square::y(), and osl::eval::ml::ppair::y_values.
|
static |
|
inline |
Definition at line 530 of file piecePair.cc.
References osl::Piece::ptypeO(), osl::eval::ml::ppair::x_values, and osl::eval::ml::ppair::y_values.
|
inlinestatic |
Definition at line 49 of file piecePair.h.
References osl::Piece::isOnBoard(), osl::Piece::ptypeO(), and osl::Piece::square().
Referenced by value().
|
inlinestatic |
Definition at line 54 of file piecePair.h.
References osl::Piece::ptypeO(), osl::Piece::square(), and value().
|
inlinestatic |
Definition at line 58 of file piecePair.h.
References index(), and osl::eval::ml::Weights::value().
|
inlinestatic |
Definition at line 73 of file piecePair.h.
References osl::Piece::ptypeO(), and osl::Piece::square().
|
static |
Definition at line 518 of file piecePair.cc.
References osl::Square::isPieceStand(), osl::ptypeOIndex(), osl::Square::x(), osl::eval::ml::ppair::x_values, osl::Square::y(), and osl::eval::ml::ppair::y_values.
|
inlinestatic |
Definition at line 41 of file piecePair.h.
References osl::eval::delta(), and osl::eval::ml::Weights::value().
|
static |
Definition at line 96 of file piecePair.h.
Referenced by osl::eval::ml::ppair::makeOffsetIndex(), osl::eval::ml::ppair::makeTableX(), and osl::eval::ml::ppair::makeTableY().
|
static |
Definition at line 94 of file piecePair.h.
|
static |
Definition at line 95 of file piecePair.h.
|
static |
Definition at line 95 of file piecePair.h.