|
io-chess
UCI chess engine
|


Public Member Functions | |
| __init__ (self, in_channels, mid_channels=16) | |
| forward (self, x) | |
Public Attributes | |
| conv0 = nn.Conv2d(in_channels, mid_channels, kernel_size=3, padding=1) | |
| conv1 | |
| conv2 = nn.Conv2d(mid_channels, mid_channels, kernel_size=1) | |
| act = nn.ReLU(inplace=True) | |
The deep, cacheable spatial logic for a single piece type. Because these are computed BEFORE the mixer, they only cost CPU cycles when the specific piece type moves.
| model.PieceBranch.__init__ | ( | self, | |
| in_channels, | |||
| mid_channels = 16 ) |


| model.PieceBranch.forward | ( | self, | |
| x ) |
| model.PieceBranch.act = nn.ReLU(inplace=True) |
| model.PieceBranch.conv0 = nn.Conv2d(in_channels, mid_channels, kernel_size=3, padding=1) |
| model.PieceBranch.conv1 |
| model.PieceBranch.conv2 = nn.Conv2d(mid_channels, mid_channels, kernel_size=1) |