Zevra 1.6.2 r536

Discussion of anything and everything relating to chess playing software and machines.

Moderators: hgm, Rebel, chrisw

sovaz1997
Posts: 261
Joined: Sun Nov 13, 2016 10:37 am

Re: Tevra 1.6.2 r536

Post by sovaz1997 »

New versions of Zevra (v1.7):
https://github.com/sovaz1997/Zevra/rele ... /v1.7_r560
+100 ELO points
sovaz1997
Posts: 261
Joined: Sun Nov 13, 2016 10:37 am

Re: Tevra 1.6.2 r536

Post by sovaz1997 »

BrendanJNorman
Posts: 2581
Joined: Mon Feb 08, 2016 12:43 am
Full name: Brendan J Norman

Re: Tevra 1.6.2 r536

Post by BrendanJNorman »

Thanks Oleg, this is a cool engine, probably around 2100-2150 Elo (FIDE Elo not CCRL).

I played a blitz game against it and was positionally crushing it, but lost on time in a complicated pawn up endgame.

The final position was better for me, but getting more complicated due to an inaccuracy on my part.

I feel like I'm stronger than Zevra, but still need to work in order to beat it.

A nice sparring partner for humans - good work my friend. ;)

Brendan
sovaz1997
Posts: 261
Joined: Sun Nov 13, 2016 10:37 am

Re: Tevra 1.6.2 r536

Post by sovaz1997 »

Thank you for testing! :D
Gerd Isenberg
Posts: 2251
Joined: Wed Mar 08, 2006 8:47 pm
Location: Hattingen, Germany

Re: Tevra 1.6.2 r536

Post by Gerd Isenberg »

Hi Oleg,

your code looks like from an obfuscation contest or compiler optimization test - a violation of using bitboards ;-)

One sample of many:

Code: Select all

uint64_t possibleMoves, mask, emask;
uint8_t color;
if(currentState.whiteMove) {
  color = WHITE;
  mask = currentState.white_bit_mask;
  emask = currentState.black_bit_mask;
} else {
  color = BLACK;
  mask = currentState.black_bit_mask;
  emask = currentState.white_bit_mask;
}

possibleMoves = rookMagic[pos / 8][pos % 8]. 
 getPossibleMoves( rookMagicMask[pos / 8][pos % 8] 
       & (currentState.white_bit_mask | currentState.black_bit_mask)  
       & (UINT64_MAX ^ vec1_cells[pos])) // occupancy of from square should not care
  & ((currentState.figures[KING] ^ emask) ^ UINT64_MAX)   // exclude king captures
  & (UINT64_MAX ^ emask)                                  // exclude captures
  & (mask ^ UINT64_MAX);                                  // exclude capturing own pieces
Better use one dimensional board arrays, no branch on currentState.whiteMove but array access, and remove redundancies ...
If encapsulating rook magics as object for each square, it may also contain not only magic factor and shift but also the rook/bishop mask (and don't call the method getPossibleMoves but getControls, getAttacks or getTargets):

Code: Select all

  color = currentState.whiteMove;
  omask = currentState.piece_bit_mask[color];
  emask = currentState.piece_bit_mask[color^1];
  occu  = omask & emask;

  possibleMoves = rookMagic[pos].getTargets(occu) & ~occu; // only quite moves
Best regards,
Gerd
sovaz1997
Posts: 261
Joined: Sun Nov 13, 2016 10:37 am

Re: Tevra 1.6.2 r536

Post by sovaz1997 »

Release Zevra v1.8 r583:
https://github.com/sovaz1997/Zevra/rele ... /v1.8_r583

Code: Select all

tc=10+0.1 Hash=16

Score of Zevra 20180123 vs Zevra v1.7.1 r563: 869 - 240 - 191  [0.742] 1300
Elo difference: 183.44 +/- 19.41
---------------------------------------------------------------------------
tc=60+0.6 Hash=16

Score of Zevra 20180123 vs Zevra v1.7.1 r563: 707 - 227 - 241  [0.704] 1175
Elo difference: 150.73 +/- 18.90
Just now I saw your message. I'll try to fix it in the next version. Thank you.
BrendanJNorman
Posts: 2581
Joined: Mon Feb 08, 2016 12:43 am
Full name: Brendan J Norman

Re: Tevra 1.6.2 r536

Post by BrendanJNorman »

sovaz1997 wrote:Release Zevra v1.8 r583:
https://github.com/sovaz1997/Zevra/rele ... /v1.8_r583

Code: Select all

tc=10+0.1 Hash=16

Score of Zevra 20180123 vs Zevra v1.7.1 r563: 869 - 240 - 191  [0.742] 1300
Elo difference: 183.44 +/- 19.41
---------------------------------------------------------------------------
tc=60+0.6 Hash=16

Score of Zevra 20180123 vs Zevra v1.7.1 r563: 707 - 227 - 241  [0.704] 1175
Elo difference: 150.73 +/- 18.90
Just now I saw your message. I'll try to fix it in the next version. Thank you.
Very quick to release a new version Oleg...

What are the changes?
sovaz1997
Posts: 261
Joined: Sun Nov 13, 2016 10:37 am

Re: Tevra 1.6.2 r536

Post by sovaz1997 »

I added a mobility bonus and improved the security of the king (the main things that gave such a gain in the power of the game)
User avatar
CMCanavessi
Posts: 1142
Joined: Thu Dec 28, 2017 4:06 pm
Location: Argentina

Re: Tevra 1.6.2 r536

Post by CMCanavessi »

sovaz1997 wrote:I added a mobility bonus and improved the security of the king (the main things that gave such a gain in the power of the game)
That was a huge increase in strenght! Very nice.

Can we expect a 1.8.1 version soon (as you usually do) or you're confident this is stable enough and bug-free?
sovaz1997
Posts: 261
Joined: Sun Nov 13, 2016 10:37 am

Re: Tevra 1.6.2 r536

Post by sovaz1997 »

CMCanavessi wrote:
sovaz1997 wrote:I added a mobility bonus and improved the security of the king (the main things that gave such a gain in the power of the game)
That was a huge increase in strenght! Very nice.

Can we expect a 1.8.1 version soon (as you usually do) or you're confident this is stable enough and bug-free?
This version is much more stable than version 1.7. I plan to make some optimizations to the moves generator in version 1.8.1. Thank you!