Answers.Body: <p>As the answer you linked elaborates: &quot;As you might guess, these numbers are empirically tuned.&quot;</p>
  <p>In practice this often boils down to self play. Traditionally you'd roughly speaking try different material values and see which ones perform best in a tournament that has different versions competing.</p>
  <p>Now with NNue for Stockfish, and the NNs in Leela things go one step further, they don't explicitly have material values at all anymore but rather evaluate the position as a whole. (though I suppose the piece values still have use for Stockfish in search heuristics etc.)</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-01-28T22:38:50.643Z
Answers.LastActivityDate: 2022-01-28T22:38:50.643Z
Answers.UserDisplayName: koedem
Answers.Body: <p>No. To be more precise, the inputs to the neural networks are high dimensional &quot;planes&quot;. The paper <a href="https://arxiv.org/pdf/1712.01815.pdf" rel="nofollow noreferrer">https://arxiv.org/pdf/1712.01815.pdf</a> has the representation:</p>
  <blockquote>
  <p>The input to the neural network is an N × N × (MT + L) image stack
  that represents state using a concatenation of T sets of M planes of
  size N × N. Each set of planes represents the board position at a
  time-step t − T + 1, ..., t, and is set to zero for time-steps less
  than 1. The board is oriented to the perspective of the current
  player. The M feature planes are composed of binary feature planes
  indicating the presence of the player’s pieces, with one plane for
  each piece type, and a second set of planes indicating the presence of
  the opponent’s pieces. For shogi there are additional planes
  indicating the number of captured prisoners of each type. There are an
  additional L constant-valued input planes denoting the player’s
  colour, the total move count, and the state of special rules: the
  legality of castling in chess (kingside or queenside); the repetition
  count for that position (3 repetitions is an automatic draw in chess;
  4 in shogi); and the number of moves without progress in chess (50
  moves without progress is an automatic draw). Input features are
  summarised in Table S1.</p>
  </blockquote>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-02-04T10:24:54.963Z
Answers.LastActivityDate: 2022-02-04T10:24:54.963Z
Answers.UserDisplayName: SmallChess
Body: <p>I have a simple question about how Chess engines like Stockfish and Leela value material. Do they use traditional material values (i.e. 1 for pawn, 3 for knight/bishop, 5 for rook, 9 for queen), or do they learn their own values through self-play?</p>
  <p>This question (<a href="https://chess.stackexchange.com/questions/5941/what-relative-point-values-of-pieces-do-engines-use">What relative point values of pieces do engines use?</a>) suggests that Stockfish has unique material values, which are defined explicitly. However, those values appear hand-tuned, not learned. Would learned values potentially deviate greatly from our standard piece values?</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-01-29T02:07:26.430Z
Comments.Text: https://chess.stackexchange.com/questions/35213/did-alphazero-also-have-to-learn-that-each-piece-has-a-value Closely related, maybe duplicate
Comments.UserDisplayName: Allure
Tags: <engines><point-value>
Title: Do modern chess engines learn material values through self-play?
ThreadText: # Do modern chess engines learn material values through self-play?
  
  (Asked by: username_0 on 2022-01-28)
  
  I have a simple question about how Chess engines like Stockfish and Leela value material. Do they use traditional material values (i.e. 1 for pawn, 3 for knight/bishop, 5 for rook, 9 for queen), or do they learn their own values through self-play?
  
  This question ([What relative point values of pieces do engines use?](https://chess.stackexchange.com/questions/5941/what-relative-point-values-of-pieces-do-engines-use)) suggests that Stockfish has unique material values, which are defined explicitly. However, those values appear hand-tuned, not learned. Would learned values potentially deviate greatly from our standard piece values?
  
  **Tags:** engines, point-value
  
  > **Comments:**
  > **username_1**: https://chess.stackexchange.com/questions/35213/did-alphazero-also-have-to-learn-that-each-piece-has-a-value Closely related, maybe duplicate  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_2 on 2022-01-28. Score: 7
  
  As the answer you linked elaborates: "As you might guess, these numbers are empirically tuned."
  
  In practice this often boils down to self play. Traditionally you'd roughly speaking try different material values and see which ones perform best in a tournament that has different versions competing.
  
  Now with NNue for Stockfish, and the NNs in Leela things go one step further, they don't explicitly have material values at all anymore but rather evaluate the position as a whole. (though I suppose the piece values still have use for Stockfish in search heuristics etc.)
  
  
  ---
  
  ### Answer by username_3 on 2022-02-04. Score: 1
  
  No. To be more precise, the inputs to the neural networks are high dimensional "planes". The paper <https://arxiv.org/pdf/1712.01815.pdf> has the representation:
  
  > The input to the neural network is an N × N × (MT + L) image stack
  > that represents state using a concatenation of T sets of M planes of
  > size N × N. Each set of planes represents the board position at a
  > time-step t − T + 1, ..., t, and is set to zero for time-steps less
  > than 1. The board is oriented to the perspective of the current
  > player. The M feature planes are composed of binary feature planes
  > indicating the presence of the player’s pieces, with one plane for
  > each piece type, and a second set of planes indicating the presence of
  > the opponent’s pieces. For shogi there are additional planes
  > indicating the number of captured prisoners of each type. There are an
  > additional L constant-valued input planes denoting the player’s
  > colour, the total move count, and the state of special rules: the
  > legality of castling in chess (kingside or queenside); the repetition
  > count for that position (3 repetitions is an automatic draw in chess;
  > 4 in shogi); and the number of moves without progress in chess (50
  > moves without progress is an automatic draw). Input features are
  > summarised in Table S1.
  
  
  ---
  
  