Commit Graph
100 Commits
Author SHA1 Message Date
Tomasz Sobczykandnodchip e8907bcfc4 Replace omp in trainer_feature_transformer 2020-10-31 11:54:03 +09:00
Tomasz Sobczykandnodchip db1b33d4ac Optimize trainer clipped relu propagate 2020-10-31 11:52:51 +09:00
Tomasz Sobczykandnodchip b5714c4084 Parallelize input slice trainer backprop. 2020-10-31 11:52:26 +09:00
Tomasz Sobczykandnodchip 941897ff2c Optimize trainer clipped relu backpropagate. 2020-10-31 11:50:12 +09:00
Tomasz Sobczykandnodchip c96743c5bd Optimize feature transformer backpropagation stats. 2020-10-31 11:49:29 +09:00
Tomasz Sobczykandnodchip 2c10b1babc Optimize feature transformer clipped relu. 2020-10-31 11:48:02 +09:00
Tomasz Sobczykandnodchip 7bedf6c5ab Specify the whole evalsave message because otherwise the first evalsave/0 triggers it. 2020-10-31 08:36:58 +09:00
Tomasz Sobczykandnodchip 8c81bbd3db Fix the counter in for_each_index_with_workers going out of scope before workers finish. 2020-10-31 08:36:58 +09:00
Tomasz Sobczykandnodchip a56d8124d8 Replace non-blas parts of trainers with our own blas-like routines. 2020-10-31 08:36:58 +09:00
Tomasz Sobczykandnodchip c56a4a36eb Add our own blas-like routines that use stockfish's thread pool for parallelization. 2020-10-29 23:57:51 +09:00
Tomasz Sobczykandnodchip ee0917a345 Pass ThreadPool to update_parameters, propagate, and backpropagate. 2020-10-29 09:21:19 +09:00
Tomasz Sobczykandnodchip f1e96cab55 Align trainer arrays to cache line. 2020-10-29 09:12:50 +09:00
Tomasz Sobczykandnodchip 8fac468259 Add a cache line aligned allocator. 2020-10-29 09:12:50 +09:00
Tomasz Sobczykandnodchip ec9e49e875 Add a HalfKA architecture (a product of K - king, and A - any piece) along with all required infrastructure. HalfKA doesn't discriminate kings compared to HalfKP. Keep old architecture as the default one. 2020-10-29 09:10:01 +09:00
Tomasz Sobczykandnodchip 317fda2516 Cleanup eval saving and lr scheduling. 2020-10-28 23:08:05 +09:00
Tomasz Sobczykandnodchip 680654b254 Add dots to output every epoch for progress visualization. 2020-10-28 09:36:43 +09:00
Tomasz Sobczykandnodchip f81fa3d712 Replace global_learning_rate with learning_rate local to the learner and passed to update_parameters as a parameter. 2020-10-28 09:36:07 +09:00
Tomasz Sobczykandnodchip cde6ec2bf2 Make all grad related functions in learn static. Pass calc_grad as a parameter. 2020-10-27 14:47:50 +09:00
Tomasz Sobczykandnodchip e4868cb59e Move setting learn search limits to learner. 2020-10-27 14:47:07 +09:00
Tomasz Sobczykandnodchip c229929d26 Remove the position parameter from learn. 2020-10-27 00:35:43 +09:00
Tomasz Sobczykandnodchip a8066cd4a9 Rename elmo lambdas 2020-10-27 00:33:58 +09:00
Tomasz Sobczykandnodchip f7de49eb66 Create a collective parameter struct for learner. 2020-10-27 00:33:58 +09:00
Tomasz Sobczykandnodchip ba390a7f9a Print the used factorizer when intializing training. 2020-10-27 00:32:39 +09:00
Tomasz Sobczykandnodchip e01397c674 Remove multi_think 2020-10-26 19:40:40 +09:00
Tomasz Sobczykandnodchip e515f1f61f Move SfenWriter to a separate file 2020-10-26 19:39:58 +09:00
Tomasz Sobczykandnodchip 65e443954a Update expected gensfen finished responses. 2020-10-26 09:37:59 +09:00
Tomasz Sobczykandnodchip 03abfae41f Reorder members, renaming. 2020-10-26 09:37:59 +09:00
Tomasz Sobczykandnodchip 6d4d20c4be Cleaner printing and some renaming. 2020-10-26 09:37:59 +09:00
Tomasz Sobczykandnodchip d77b3d176e Always flush sfen writer at the end of gensfen and when it is destroyed. 2020-10-26 09:37:59 +09:00
Tomasz Sobczykandnodchip 21fac7c53c A collective struct for gensfen parameters. 2020-10-26 09:37:59 +09:00
Tomasz Sobczykandnodchip cb61dc9c9b Make sfen writer a part of gensfen. 2020-10-26 09:37:59 +09:00
Tomasz Sobczykandnodchip 3f289546da Make some gensfen members private. 2020-10-26 09:37:59 +09:00
Tomasz Sobczykandnodchip 821b655bc6 Move gensfen progress reporting from sfen writer to gensfen 2020-10-26 09:37:59 +09:00
Tomasz Sobczykandnodchip af238fe132 Rewrite gensfen to use stockfish's thread pool. 2020-10-26 09:37:59 +09:00
Tomasz Sobczykandnodchip 0e528995c2 Print avg bias/weight for affine trasform and feature transformer during training. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip fe766f4f42 Additional output from layers during training. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip 2c477d76ec Cleaner and more outputs during training initialization. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip b882423005 Bring back info for finished evalsave. Update tests with the new message. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip 4b72658409 Synchronize printed info regions in the learner and sfen reader. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip d824bd8ec5 Add an overload for io manip in the logger. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip 54dd6a2407 Add logger with synchronized regions. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip cf3edfed82 Improve info messages. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip c49ae541c4 Add layer info for check_health. Print subsequent infos from the same scope with "-->" instead of "INFO:" for clarity. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip 8ddef320e6 Print an additional new line before calc_loss progress instead of after check_health in the feature transformer layer. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip d70408f204 Add docs entry for the verbose flag. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip a351c1d65e Add verbose flag to learn. Only print update parameters info when vebose=true 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip ec436d3dfd Print some weight update stats 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip be3937c37b Print layers and their indices during training initialization. 2020-10-25 22:18:28 +09:00
Tomasz Sobczykandnodchip 3bf397a569 Update instrumented_learn for the current codebase. 2020-10-25 19:22:56 +09:00
Tomasz Sobczykandnodchip 47a82bfc91 Document new options. 2020-10-25 19:22:56 +09:00
Tomasz Sobczykandnodchip 371acaa0b5 Allow changing sfen reader buffer sizes for the learn command. 2020-10-25 19:22:56 +09:00
Tomasz Sobczykandnodchip d31169bab5 Update CI to use epochs instead of loops. 2020-10-25 19:22:56 +09:00
Tomasz Sobczykandnodchip 8fb208598b pass shuffle flag in the constructor 2020-10-25 19:22:56 +09:00
Tomasz Sobczykandnodchip 31f94a18b3 Update readme and docs after change from loop to epochs. 2020-10-25 19:22:56 +09:00
Tomasz Sobczykandnodchip fc3788f630 Use cyclic sfen reader for learning, change loop option to epochs. 2020-10-25 19:22:56 +09:00
Tomasz Sobczykandnodchip ad3d1b42e4 Make sfen reader only stop when it's destroyed. Now it is fully RAII. 2020-10-25 19:22:56 +09:00
Tomasz Sobczykandnodchip c58aa9696a Start sfen reader worker thread in the constructor. 2020-10-25 19:22:56 +09:00
Tomasz Sobczykandnodchip 0636e1256d Add cyclic mode to the sfen reader. Make sfen reader take all files at construction 2020-10-25 19:22:56 +09:00
Tomasz Sobczykandnodchip e4a38c18dd Don't test syzygi 2020-10-24 08:52:42 +09:00
Tomasz Sobczykandnodchip e4e9f7e39b Reduce bench depth for testing with valgrind to prevent timeouts in CI. 2020-10-24 08:52:42 +09:00
Tomasz Sobczykandnodchip c7ac3688a7 Move the old convert stuff from learn to their own commands. 2020-10-24 08:52:42 +09:00
Tomasz Sobczykandnodchip f7530de20d Fix assertion in trainer 2020-10-23 09:35:41 +09:00
Tomasz Sobczykandnodchip 9564a52523 Remove whole file shuffling as it does not change learning behaviour, only works for bin, and is considered harmful for binpack. 2020-10-23 09:33:20 +09:00
Tomasz Sobczykandnodchip 7b4a769cca Fix base_dir not being applied to singular filenames. 2020-10-22 20:01:55 +09:00
Tomasz Sobczykandnodchip af138d1937 Fix crashes when trying to open a file of unknown type. Increase robustness of error handling. 2020-10-22 20:01:55 +09:00
Tomasz Sobczykandnodchip 886467e09f Fix crash when trying to read a non existing .binpack file. 2020-10-22 20:01:55 +09:00
Tomasz Sobczykandnodchip 11b28ad3b5 Don't treat unknown options in learn as file names. Add targetfile to specify individual files. 2020-10-22 20:01:55 +09:00
Tomasz Sobczykandnodchip 8f3e64a6d5 move sfen reader to separate file 2020-10-22 10:42:28 +09:00
Tomasz Sobczykandnodchip ff06d1e0ad Rewrite learner to be based on stockfish's thread pool. Reduce coupling along the way 2020-10-21 18:17:34 +09:00
Tomasz Sobczykandnodchip f2ad307de3 Clarify the behaviour of execute_with_worker[s] 2020-10-20 19:19:32 +09:00
Tomasz Sobczykandnodchip 74af287637 Fix execute_with_workers test call in uci 2020-10-20 19:19:32 +09:00
Tomasz Sobczykandnodchip 71862e2ebb remove incorrect move in execute_with_workers 2020-10-20 19:19:32 +09:00
Tomasz Sobczykandnodchip fd229c0768 Fix races and UBs 2020-10-20 19:19:32 +09:00
Tomasz Sobczykandnodchip 97fb9a89e4 allow waiting for task completion. 2020-10-20 19:19:32 +09:00
Tomasz Sobczykandnodchip 5188c26b20 Allow execution of tasks on the global thread pool. 2020-10-20 19:19:32 +09:00
Tomasz Sobczykandnodchip 146a6b056e PascalCase -> snake_case for consistency with the rest of the codebase. 2020-10-19 18:37:23 +09:00
Tomasz Sobczykandnodchip 2398d34e87 Move string split to misc 2020-10-19 08:29:51 +09:00
Tomasz Sobczykandnodchip 69ea3d30b2 Move the extra new line to after check health. 2020-10-19 08:29:51 +09:00
Tomasz Sobczykandnodchip 9023edc3c8 Add missing includes. 2020-10-19 08:29:51 +09:00
Tomasz Sobczykandnodchip 77624addf2 Cleanup last ".." in include paths. 2020-10-19 08:29:51 +09:00
Tomasz Sobczykandnodchip 497f689aa3 Cleanup nnue 2020-10-19 08:29:51 +09:00
Tomasz Sobczykandnodchip c286f9cd7d Cleanup trainer. 2020-10-19 08:29:51 +09:00
Tomasz Sobczykandnodchip ea8eb415de Cleanup trainer features. 2020-10-18 22:24:24 +09:00
Tomasz Sobczykandnodchip 3041adb080 Cleanup layers. 2020-10-18 19:32:15 +09:00
Tomasz Sobczykandnodchip 0d4c3014ca Cleanup features. 2020-10-17 23:19:16 +09:00
Tomasz Sobczykandnodchip ca760c3a5b Cleanup architecture files. 2020-10-17 20:01:09 +09:00
Tomasz Sobczykandnodchip c93f8732bf Force Use NNUE to pure when learning. 2020-10-17 08:44:38 +09:00
Tomasz Sobczykandnodchip 3cf193a90e Properly handle cases in verify and init when SkipLoadingEval is set. 2020-10-17 08:44:38 +09:00
Tomasz Sobczykandnodchip 5db46d0c82 Verify whether there is a network being used during training. 2020-10-17 08:44:38 +09:00
Tomasz Sobczykandnodchip e503cc4ea8 Add one more empty line between progress reports. 2020-10-17 00:13:50 +09:00
Tomasz Sobczykandnodchip 5856237e3f Rename hirate to startpos 2020-10-16 09:07:02 +09:00
Tomasz Sobczykandnodchip 904adb9a32 Indentation consistency in learn folder 2020-10-15 22:11:31 +09:00
Tomasz Sobczykandnodchip 880d23af1c Move sfen input/output streams to sfen_stream.h 2020-10-15 20:37:03 +09:00
Tomasz Sobczykandnodchip 14f83ad7b9 Move public search/qsearch interface from namespace Learner to namespace Search 2020-10-15 20:37:03 +09:00
Tomasz Sobczykandnodchip 0494adeb2c Move nnue evaluation stuff from evaluate.h to nnue/evaluate_nnue.h 2020-10-15 20:37:03 +09:00
Tomasz Sobczykandnodchip 4a340ad3b2 Add docs for auto_lr_drop 2020-10-12 23:56:26 +09:00
Tomasz Sobczykandnodchip 4a2bf16b30 Add option "auto_lr_drop" that specifies the amount of positions from previous lr drop after which to reduce lr by newbob_decay. 2020-10-12 23:56:26 +09:00
Tomasz Sobczykandnodchip 7d62b3f799 Store additional bits for fullmove clock and 50 more rule halfmove clock at the end of the bit stream. This change keeps backwards compatibility. 2020-10-11 20:59:27 +09:00
Tomasz Sobczykandnodchip de20887e11 Update readme. Link to docs. 2020-10-10 14:37:51 +09:00
Tomasz Sobczykandnodchip 2af4bf7eac Move the docs folder one above, it was in src by mistake. 2020-10-10 14:37:51 +09:00