bsamseth / Goldfish

Goldfish - Stockfish's very distant and not so bright cousin - a UCI chess engine
MIT License
7 stars 2 forks source link

Search Refactor & Verification #27

Closed bsamseth closed 5 years ago

bsamseth commented 5 years ago

The search logic should get a cleanup with the aim of being more clear and easy to follow.

More importantly, proper verification of the search results should be implemented.

This PR will not be merged until #26 is satisfactorily resolved, and #25 is confirmed to finally be fixed.

coveralls commented 5 years ago

Coverage Status

Coverage increased (+5.7%) to 91.71% when pulling a56b2f88a7a62f8c369f9f63c0fa31cc2a0f7691 on search-refactor into 6ed378cafedd2307aa349a50e96d96825ba40d80 on master.

codecov[bot] commented 5 years ago

Codecov Report

Merging #27 into master will increase coverage by 4.97%. The diff coverage is 91.01%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #27      +/-   ##
==========================================
+ Coverage   85.64%   90.62%   +4.97%     
==========================================
  Files          20       31      +11     
  Lines        1066     1450     +384     
==========================================
+ Hits          913     1314     +401     
+ Misses        153      136      -17
Impacted Files Coverage Δ
src/position.cpp 97.94% <100%> (-0.08%) :arrow_down:
include/search.hpp 100% <100%> (ø)
src/semaphore.cpp 100% <100%> (ø)
include/tt.hpp 100% <100%> (+7.69%) :arrow_up:
src/timer.cpp 100% <100%> (ø)
src/searchmanagement.cpp 85.22% <85.22%> (ø)
src/search.cpp 97.29% <92.68%> (ø)
include/value.hpp 57.14% <0%> (-42.86%) :arrow_down:
include/depth.hpp 100% <0%> (ø) :arrow_up:
... and 18 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 6ed378c...a56b2f8. Read the comment docs.

bsamseth commented 5 years ago

Significant strength boost:

    Goldfish v1.9.0 2353.1 :    430 (+201,=159,-70),  65.2 %

    vs.                    :  games (   +,   =,  -),   (%) :    Diff
    Goldfish v1.7.0        :    215 ( 101,  84, 30),  66.5 :  +101.6
    Goldfish v1.8.2        :    215 ( 100,  75, 40),  64.0 :  +119.1

   # PLAYER             :  RATING  POINTS  PLAYED   (%)
   1 Goldfish v1.9.0    :  2353.1   280.5     430    65
   2 Goldfish v1.7.0    :  2251.5   877.5    1699    52
   3 Goldfish v1.7.1    :  2243.8   244.0     477    51
   4 Goldfish v1.8.0    :  2237.0   324.0     650    50
   5 Goldfish v1.8.1    :  2234.1   485.5    1000    49
   6 Goldfish v1.8.2    :  2234.0   174.0     429    41
   7 Goldfish v1.6.0    :  2218.7   434.5     797    55
   8 Goldfish v1.7.2    :  2218.0    69.5     150    46
   9 Goldfish v1.5.1    :  2168.8   460.5     970    47
  10 Goldfish v1.5      :  2158.6   554.5    1145    48
  11 Goldfish v1.4      :  2153.5   487.0     970    50
  12 Goldfish v1.3      :  2130.7   162.5     325    50
  13 Goldfish v1.2      :  2112.2   107.5     230    47
  14 Goldfish v1.1      :  2055.2    93.0     232    40
  15 Goldfish v1.0      :  2000.0    13.5      32    42
bsamseth commented 5 years ago

This PR fixes #25, at least to the confidence provided by the testing that is now done.

This also fixes #26 with the addition of search tests. This test suite can always be extended, and the current setup makes this very easy via simply providing an EDP describing a puzzle.

With the above ELO strength improvement that has resulted from this PR, I'm considering this to be satisfactory for a merge into master, closing the two issues mentioned.