]> git.sesse.net Git - remoteglot/blobdiff - remoteglot.pl
Revert "Convert TB scores in low depth."
[remoteglot] / remoteglot.pl
index abbbd983a7127abf317ef1c61916d2038db70c76..56554a6d6b5589a65c13764a7d9ab0c5740bf624 100755 (executable)
@@ -540,17 +540,9 @@ sub parse_infos {
        my $now_depth = $info->{'depth1'} // $info->{'depth'};
        if (defined($prev_depth) && POSIX::floor($now_depth / 10) > POSIX::floor($prev_depth / 10)) {
                my $d = POSIX::floor($now_depth / 10) * 10;  # In case we skipped some.
-               complete_using_tbprobe($pos_calculating, $info, exists($info->{'depth1'}) ? '1' : '');
                my $cp = $info->{'score_cp1'} // $info->{'score_cp'};
                my $mate = $info->{'score_mate1'} // $info->{'score_mate'};
-               my $splicepos = $info->{'splicepos1'} // $info->{'splicepos'};
-               my $bestmove;
-               if (defined($info->{'pv1'})) {  # Avoid autovivification.
-                       $bestmove = $info->{'pv1'}[0];
-               } else {
-                       $bestmove = $info->{'pv'}[0];
-               }
-               push @{$info->{'lowdepth'}}, [ $d, $cp, $mate, $splicepos, $bestmove ];
+               push @{$info->{'lowdepth'}}, [ $d, $cp, $mate ];
        }
 }
 
@@ -965,9 +957,7 @@ sub output_json {
        $json->{'lowdepth'} = {};
        if (exists($info->{'lowdepth'})) {
                for my $ld (@{$info->{'lowdepth'}}) {
-                       my $score = score_digest_inner($ld->[1], $ld->[2], $ld->[3], 0, $pos_calculating);
-                       push @$score, prettyprint_pv($pos_calculating, $ld->[4]);
-                       $json->{'lowdepth'}{$ld->[0]} = $score;
+                       $json->{'lowdepth'}{$ld->[0]} = score_digest_inner($ld->[1], $ld->[2], undef, 0, $pos_calculating);
                }
        }