2020
10-08
10-08
keras分类模型中的输入数据与标签的维度实例
在《python深度学习》这本书中。一、21页mnist十分类导入数据集fromkeras.datasetsimportmnist(train_images,train_labels),(test_images,test_labels)=mnist.load_data()初始数据维度:>>>train_images.shape(60000,28,28)>>>len(train_labels)60000>>>train_labelsarray([5,0,4,...,5,6,8],dtype=uint8)数据预处理:train_images=train_images.reshape((60000,28*28))train_images=train_images.asty...
继续阅读 >