2019-02-17から1日間の記事一覧

numpy.shuffleのメモ

import numpy import random with open('generated_sfens.bin', 'rb') as f: data = numpy.fromfile(f, dtype='int8').reshape(100000000, 40) numpy.random.shuffle(data) with open('shuffled_sfens.bin', 'wb') as f: data.tofile(f)