mirror of
https://github.com/sockspls/badfish
synced 2025-05-01 01:03:09 +00:00
Display fail high/fail low in search log file.
This commit is contained in:
parent
fd2b3df770
commit
18cd83a380
3 changed files with 8 additions and 4 deletions
|
@ -325,14 +325,15 @@ const string line_to_san(const Position& pos, Move line[], int startColumn, bool
|
||||||
/// when the UCI parameter "Use Search Log" is "true").
|
/// when the UCI parameter "Use Search Log" is "true").
|
||||||
|
|
||||||
const string pretty_pv(const Position& pos, int time, int depth,
|
const string pretty_pv(const Position& pos, int time, int depth,
|
||||||
uint64_t nodes, Value score, Move pv[]) {
|
uint64_t nodes, Value score, ValueType type, Move pv[]) {
|
||||||
std::stringstream s;
|
std::stringstream s;
|
||||||
|
|
||||||
// Depth
|
// Depth
|
||||||
s << std::setw(2) << depth << " ";
|
s << std::setw(2) << depth << " ";
|
||||||
|
|
||||||
// Score
|
// Score
|
||||||
s << std::setw(8) << score_string(score);
|
s << ((type == VALUE_TYPE_LOWER)? ">" : ((type == VALUE_TYPE_UPPER)? "<" : " "));
|
||||||
|
s << std::setw(7) << score_string(score);
|
||||||
|
|
||||||
// Time
|
// Time
|
||||||
s << std::setw(8) << time_string(time) << " ";
|
s << std::setw(8) << time_string(time) << " ";
|
||||||
|
|
|
@ -39,6 +39,6 @@
|
||||||
extern const std::string move_to_san(const Position& pos, Move m);
|
extern const std::string move_to_san(const Position& pos, Move m);
|
||||||
extern Move move_from_san(const Position& pos, const std::string& str);
|
extern Move move_from_san(const Position& pos, const std::string& str);
|
||||||
extern const std::string line_to_san(const Position& pos, Move line[], int startColumn, bool breakLines);
|
extern const std::string line_to_san(const Position& pos, Move line[], int startColumn, bool breakLines);
|
||||||
extern const std::string pretty_pv(const Position& pos, int time, int depth, uint64_t nodes, Value score, Move pv[]);
|
extern const std::string pretty_pv(const Position& pos, int time, int depth, uint64_t nodes, Value score, ValueType type, Move pv[]);
|
||||||
|
|
||||||
#endif // !defined(SAN_H_INCLUDED)
|
#endif // !defined(SAN_H_INCLUDED)
|
||||||
|
|
|
@ -971,7 +971,10 @@ namespace {
|
||||||
std::cout << std::endl;
|
std::cout << std::endl;
|
||||||
|
|
||||||
if (UseLogFile)
|
if (UseLogFile)
|
||||||
LogFile << pretty_pv(pos, current_search_time(), Iteration, nodes_searched(), value, ss[0].pv)
|
LogFile << pretty_pv(pos, current_search_time(), Iteration, nodes_searched(), value,
|
||||||
|
((value >= beta)? VALUE_TYPE_LOWER
|
||||||
|
: ((value <= alpha)? VALUE_TYPE_UPPER : VALUE_TYPE_EXACT)),
|
||||||
|
ss[0].pv)
|
||||||
<< std::endl;
|
<< std::endl;
|
||||||
|
|
||||||
if (value > alpha)
|
if (value > alpha)
|
||||||
|
|
Loading…
Add table
Reference in a new issue