load_data_sets.py 文件源码

python
阅读 32 收藏 0 点赞 0 评论 0

项目:MuGo 作者: brilee 项目源码 文件源码
def write(self, filename):
        header_bytes = struct.pack(CHUNK_HEADER_FORMAT, self.data_size, self.board_size, self.input_planes, self.is_test)
        position_bytes = np.packbits(self.pos_features).tostring()
        next_move_bytes = np.packbits(self.next_moves).tostring()
        with gzip.open(filename, "wb", compresslevel=6) as f:
            f.write(header_bytes)
            f.write(position_bytes)
            f.write(next_move_bytes)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号