---
# System prepended metadata

title: Format

---

# Format
  The input of moving model has exactly the same format as that  of picking model. This format required a 3D input with shape (**time_seq** , **bitmap** , 8 , 8). In the move prediction task, we fix the time_seq to 2 and bitmap to 14, which has the best performance among all setting. The setting and method can be reviewed in the previous section.
  
Since the picking model already predicts a possible set with high accuracy when the set extends to size 5, moving model then takes this set as an additional information input. In this section, the methods for taking advantage of this additional information will be discussed.
## Blend
The first method is very straightforward. Inspired by resnet's skip connection, the infomation with shape (8,8) is extended by third dimension and added to the board input. Thus the new input contains the prediction information inside its 3D cube and the peice with higher choosing possiblity will have a higher value.

This method is the best from experimental performance. In this project, I fix this method for our input.

## Hidden State Approach
This method is inspired by the concept of hidden state. IF the additional information are considered as a hidden state, we can let the input flow in and simulate a thinking process. 

Output example :　

![](https://i.imgur.com/xvUFRWZ.png)

Heat map : 

![](https://i.imgur.com/xBXj7Cc.png)


This approach leads the model to predict only for the piece that has highest picking probability. This will cause the moving model be highly dependent on the performance of picking model. If the previous choice was wrong, then the move prediction will not be correct. 
## Trim + Blend
Consider some of the positions aren't legal to be chosen in chess game, trim and blend method set these illegal position to 0, then blend it into the board input. This method is a very classical method ; the operation doesn't have gradient.

This method also suffer from the same problem as previous one. Since the model focus on specific peice, the output will only fit the motion of specific peice.

