mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-25 19:46:55 +08:00
pass shuffle flag in the constructor
This commit is contained in:
@@ -40,6 +40,7 @@ namespace Learner{
|
||||
// Because it always the same integers on MinGW.
|
||||
SfenReader(
|
||||
const std::vector<std::string>& filenames_,
|
||||
bool do_shuffle,
|
||||
SfenReaderMode mode_,
|
||||
int thread_num,
|
||||
const std::string& seed
|
||||
@@ -51,7 +52,7 @@ namespace Learner{
|
||||
packed_sfens.resize(thread_num);
|
||||
total_read = 0;
|
||||
end_of_files = false;
|
||||
shuffle = true;
|
||||
shuffle = do_shuffle;
|
||||
stop_flag = false;
|
||||
|
||||
file_worker_thread = std::thread([&] {
|
||||
@@ -312,11 +313,6 @@ namespace Learner{
|
||||
}
|
||||
}
|
||||
|
||||
void set_do_shuffle(bool v)
|
||||
{
|
||||
shuffle = v;
|
||||
}
|
||||
|
||||
protected:
|
||||
|
||||
// worker thread reading file in background
|
||||
|
||||
Reference in New Issue
Block a user