TensorFlow 2. These MNIST images of 28×28 pixels are represented as an array of numbers whose values range from [0, 255] of type uint8. This example shows how to use the deep learning API to perform numeric classification using the Python Keras library. datasets import mnist import tensorflow as tf if K. What is Keras? The deep neural network API explained Easy to use and widely supported, Keras makes deep learning about as simple as deep learning can be. 動機はさておき、こちらのエントリ を読んで気になっていた Keras を触ってみたのでメモ。自分は機械学習にも Python にも触れたことはないので、とりあえず、サンプルコードを読み解きながら、誰しもが通るであろう(?)MNIST データセットの識字をやってみた。表題の通り、用いたモデルは. layers import Dense, Dropout, Activation, Flatten from keras. Find file Copy path. models import Sequential from keras. Skip to content. Sign up Why GitHub? keras / examples / mnist_cnn. ienet1308 August 2, 2018, 7:39am #1. layers import Flatten from keras. The mnist_test. Convolutional Neural Networks (CNN) for CIFAR-10 Dataset. datasets import mnist import tensorflow as tf if K. You can vote up the examples you like or vote down the ones you don't like. It has a function mnist. January 22, 2017. This is a sample from MNIST dataset. MNIST consists of 28 x 28 grayscale images of handwritten digits like this: The dataset also includes labels for each image, telling us which digit it is. Prerequisite Hardware: A machine with at least two GPUs Basic Software: Ubuntu (18. We can learn the basics of Keras by walking through a simple example: recognizing handwritten digits from the MNIST dataset. こんにちは。 本記事は、kerasの簡単な紹介とmnistのソースコードを軽く紹介するという記事でございます。 そこまで深い説明はしていないので、あんまり期待しないでね・・・笑 [追記:2017/02/10] kerasに関するエントリまとめました!. By voting up you can indicate which examples are most useful and appropriate. The winners of ILSVRC have been very generous in releasing their models to the open-source community. HorovodRunner TensorFlow and Keras MNIST example notebook. Keras implementation of depth residual shrinkage network (MNIST image) Time:2020-3-10 In essence, deep residual shrinkage network belongs to convolutional neural network, which is a variation of deep residual network (RESNET). This notebook is hosted on GitHub. fashion_mnist = keras. Creating the Keras LSTM structure In this example, the Sequential way of building deep learning networks will be used. I'm going to use one of the built-in datasets with tf/keras. In addition, we are sharing an. Keras is highly productive for developers; it often requires 50% less code to define a model than native APIs of deep learning frameworks require (here’s an example of LeNet-5 trained on MNIST data in Keras and TensorFlow ). When using the Theano backend, you must explicitly declare a dimension for the depth of the input image. In this tutorial, we will present a simple method to take a Keras model and deploy it as a REST API. Known issues. The Fashion MNIST data is available directly in the `tf. To use it, we first define a function that takes the arguments that we wish to tune, inside the function, you define the network's structure as usual and compile it. What's included? 1 file. First, let’s see some images without applying any augmentation techniques. Through Keras, users have access to a variety of different state-of-the-art deep learning frameworks, such as TensorFlow, CNTK, and others. January 23, 2017. 動機はさておき、こちらのエントリ を読んで気になっていた Keras を触ってみたのでメモ。自分は機械学習にも Python にも触れたことはないので、とりあえず、サンプルコードを読み解きながら、誰しもが通るであろう(?)MNIST データセットの識字をやってみた。表題の通り、用いたモデルは. layers import Dense, Dropout, Flatten from keras. Implement logical operators with TFLearn (also includes a usage of 'merge'). Hi, with an upgrade to JetPack 3. load_dataset() function. For example, the labels for the above images are 5. In previous posts, I introduced Keras for building convolutional neural networks and performing word embedding. layers import Dense, Dropout, Activation, Flatten from keras. Step 5: Preprocess input data for Keras. To continue with the preparation of the training data, let’s cast the MNIST image array into 32-bit format:. We will use the MNIST and CIFAR10 datasets for illustrating various concepts. There are many models such as AlexNet, VGGNet, Inception, ResNet, Xception and many more which we can choose from, for our own task. Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4. csv file contains the 60,000 training examples and labels. This, I will do here. Documentation for the TensorFlow for R interface. The Fashion MNIST data is available directly in the `tf. Eclipse Deeplearning4j is an open-source, distributed deep-learning project in Java and Scala spearheaded by the people at Konduit. 3)提供了一种能够顺利运行 keras 源码中 example 下 mnist 的相关案例; 4)找到了另外几种解决方案,提供了相关的链接。 numpy. We'll also discuss the difference between autoencoders and other generative models, such as Generative Adversarial Networks (GANs). Now let's work on applying an RNN to something simple, then we'll use an RNN on a more realistic use-case. Last week I published a blog post about how easy it is to train image classification models with Keras. The MNIST database (Modified National Institute of Standards and Technology database) is a large database of handwritten digits that is commonly used for training various image processing systems. In a previous tutorial of mine, I gave a very comprehensive introduction to recurrent neural networks and long short term memory (LSTM) networks, implemented in TensorFlow. It contains 60. For example, the label for the above image is. Example Description; addition_rnn: Implementation of sequence to sequence learning for performing addition of two numbers (as strings). Guide to the Sequential model; Guide to the Functional API; FAQ; Models. Importing Necessary Modules. And hence, Keras too doesn't have the corresponding support. This code is adapted from the Keras MNIST Example. It contains a training set of 60000 examples, and a test set of 10000 examples. Autoencoder is a data compression algorithm where the compression and decompression functions learned automatically from examples rather than engineered by a human. Tip: you can also follow us on Twitter. As a code along with the example, we looked at the MNIST Handwritten Digits Dataset: You can check out the “The Deep Learning Masterclass: Classify Images with Keras” tutorial to understand it more practically. Fasion-MNIST is mnist like data set. Fine-Tuning. Example one - MNIST classification. Eclipse Deeplearning4j. The Akida examples¶ The examples section comprises a zoo of event-based CNN and SNN tutorials. In fact, even Tensorflow and Keras allow us to import and download the MNIST dataset directly from their API. MNIST dataset is available in keras' built-in dataset library. The classes, or labels, in this example are {0,1,2,3,4,5,6,7,8,9}. Now that the input data for our Keras LSTM code is all setup and ready to go, it is time to create the LSTM network itself. Keras examples directory Vision models examples. You can use it to visualize filters, and inspect the filters as they are computed. The following are code examples for showing how to use keras. Classify each one of these 5 pieces. Skip to content. scikit_learn can be used to build KerasClassifier model, Keras be used to build clustering models? If it can be, are there any examples for that? you know i want to use some features like age, city, education, company, job title and so on to cluster people into some groups and to get the key features of each group. Trains a simple convnet on the MNIST dataset. mnist_demo_run. Browse our catalogue of tasks and access state-of-the-art solutions. Then submit your job using the sbatch command as discussed in [Getting Started with Slurm]. MNIST consists of 28 x 28 grayscale images of handwritten digits like these: The dataset also includes labels for each image, telling us which digit it is. MNIST Example We can learn the basics of Keras by walking through a simple example: recognizing handwritten digits from the MNIST dataset. MNIST dataset is a standard and keras provides API to download it for convenience. Gets to 98. load_data taken from open source projects. Posted by: Chengwei 1 year, 4 months ago () In this quick tutorial, I am going to show you two simple examples to use the sparse_categorical_crossentropy loss function and the sparse_categorical_accuracy metric when compiling your Keras model. Example 5 - MNIST¶. The proceeding example uses Keras, a high-level API to build and train models in TensorFlow. Additionally, in almost all contexts where the term “Autoencoder” is used, the compression and decompression functions are implemented with neural networks. We saw how to apply this model using Keras to compress images from the MNIST dataset in twapplied the autoencoder using Keras for compressing the MNIST dataset in just 2 elements. This is a tutorial of how to classify the Fashion-MNIST dataset with tf. if you want to take advantage of NVIDIA GPUs, see the documentation for install_keras(). com Keras DataCamp Learn Python for Data Science Interactively Data Also see NumPy, Pandas & Scikit-Learn Keras is a powerful and easy-to-use deep learning library for Theano and TensorFlow that provides a high-level neural. Classification is done by projecting an input vector onto a set of hyperplanes, each of which corresponds to a class. We could use native Nengo objects instead, but in this example we’ll use TensorNodes to make the parallels with standard deep networks as clear as possible. Our setup: only 2000 training examples (1000 per class) We will start from the following setup: a machine with Keras, SciPy, PIL installed. Example 1: Flatten Operation Using Keras Sequential() Function. In a previous tutorial of mine, I gave a very comprehensive introduction to recurrent neural networks and long short term memory (LSTM) networks, implemented in TensorFlow. models import Sequential: from keras. They are from open source Python projects. Gets to 98. Keras can conveniently download the MNIST data from the web. mnist_irnn: Reproduction of the IRNN experiment with pixel-by-pixel sequential MNIST in "A Simple Way to Initialize Recurrent Networks of Rectified Linear Units" by Le et al. Deep Learning for humans. Documentation for the TensorFlow for R interface. See this issue for example. We will be classifying sentences into a positive or negative label. They are from open source Python projects. # encoding:utf-8 from __future__ import print_function import keras from keras. 0 License , and code samples are licensed under the Apache 2. In this codelab, you'll learn about how to use convolutional neural Networks to improve your image classification models. mport tensorflow as tf from tensorflow. As you can see, this is composed of visually complex letters. Being able to go from idea to result with the least possible delay is key to doing good research. Work your way from a bag-of-words model with logistic regression to more advanced methods leading to convolutional neural networks. This scenario shows how to use TensorFlow to the classification task. We can learn the basics of Keras by walking through a simple example: recognizing handwritten digits from the MNIST dataset. Some of the generative work done in the past year or two using generative adversarial networks (GANs) has been pretty exciting and demonstrated some very impressive results. layers import Conv2D, MaxPooling2D: from keras import backend as K: batch_size = 128: num_classes = 10: epochs = 12 # input image dimensions: img_rows, img_cols = 28, 28 # the data, split between train and test sets. MNIST consists of 28 x 28 grayscale images of handwritten digits like these: The dataset also includes labels for each image, telling us which digit it is. Linear Regression. fashion_mnist (train_images, train_labels), (test_images, test_labels) = fashion_mnist. 25% test accuracy after 12 epochs Note: There is still a large margin for parameter tuning. Kerasは、バックエンドにTensorFlowやTheanoを利用したPythonの深層学習ライブラリ。日本語のドキュメントが充実しており、とっつきやすい。TensorFlowで書いたソフトマックス回帰によるMNISTの分類をKerasで書き直してみる。TensorFlow版は以下の記事。関連記事: TensorFlowでMNISTを分類(ソフトマックス編. datasets import mnist # load pre-shuffled MNIST data. x) MNIST with NNI API (TensorFlow v2. DNN and CNN of Keras with MNIST Data in Python Posted on June 19, 2017 June 19, 2017 by charleshsliao We talked about some examples of CNN application with KeRas for Image Recognition and Quick Example of CNN with KeRas with Iris Data. MNIST Handwritten digits classification using Keras. load_data() 3. It can take a very long time to train a GAN; however, this problem is small enough that it can be run on most laptops in a few hours, which makes it a great example. Trained using the mnist dataset, this model recognizes and classifies numbers you draw on the front panel. 0 based off a 1. Fashion MNIST is intended as a drop-in replacement for the classic MNIST dataset—often used as the "Hello, World" of machine learning programs for computer vision. In just a few lines of code, you can define and train a model that is able to classify the images with over 90% accuracy, even without much optimization. php/Using_the_MNIST_Dataset". This playlist is about Keras a High Level TensorFlow API. Therefore, I will start with the following two lines to import tensorflow and MNIST dataset under the Keras API. For most of them, I already explained why we need them. There are many models such as AlexNet, VGGNet, Inception, ResNet, Xception and many more which we can choose from, for our own task. Basically, this dataset is comprised of digit and the correponding label. mnist import input_data from sklearn. html: So I am having trouble learning Keras. import numpy as np import os import tempfile import keras from keras import backend as K from keras import layers from keras. The winners of ILSVRC have been very generous in releasing their models to the open-source community. TensorFlow MNIST Autoencoders. We use cookies on Kaggle to deliver our services, analyze web traffic, and improve your experience on the site. 50000 examples batch size = 1, 50000 updates in one epoch batch size = 10, 5000 updates in one epoch GTX 980 on MNIST with 50000 training examples 166s 166s 17s 17s 1 epoch 10 epochs Batch size = 1 and 10. Getting started: Import a Keras model in 60 seconds. 另外 "Keras_MNIST_CNN. We support import of all Keras model types, most layers and practically all utility functionality. Learning Keras. See this issue for example. Each row consists of 785 values: the first value is the label (a number from 0 to 9) and the remaining 784 values are the pixel values (a number from 0 to 255). MNIST with Keras. There is also data about the strokes used to create each character, but we won’t be using that. The MNIST Data. The MNIST dataset is comprised of 70,000 handwritten numeric digit images and their respective labels. py Trains a simple deep multi-layer perceptron on the MNIST dataset. MNIST database of handwritten digits Dataset of 60,000 28x28 grayscale images of the 10 digits, along with a test set of 10,000 images. Some tasks examples are available in the repository for this purpose: cd adding_problem/ python main. models import Sequential from keras. 25% test accuracy after 12 epochs Note: There is still a large margin for parameter tuning. import keras from keras. EPOCHS = 200 BATCH_SIZE = 128 VERBOSE = 1 NB_CLASSES = 10 # number of outputs = number of digits N_HIDDEN = 128 VALIDATION_SPLIT = 0. Problem running MNIST classifier example using Keras and TensorFlow extensions. This is a utility function for constructing TensorNodes that mimics the Keras functional API. Clicking on MNIST_MLP at the top of the dashboard will open up a panel of settings for controlling the appearance and functionality of the network display. CNN/DNN of KeRas in R, Backend Tensorflow, for MNIST Posted on April 24, 2017 April 29, 2017 by charleshsliao Keras is a library of tensorflow, and they are both developed under python. The proceeding example uses Keras, a high-level API to build and train models in TensorFlow. This post is a walkthrough on the keras example: mnist_cnn. The database is also widely used for training and testing in the field of machine learning. tune_mnist_keras: Converts the Keras MNIST example to use Tune with the function-based API and a Keras callback. Omniglot is sometimes referred to as the transpose of mnist, since it has 1623 types of character with only 20 examples each, in contrast to MNIST having thousands of examples for only 10 digits. net/introduction-deep-learning-. Take a look at the demo program in Figure 1. The following are code examples for showing how to use keras. Then, we need to load the MNIST dataset and reshape it so that it is suitable for use training a CNN. Train this neural network. By voting up you can indicate which examples are most useful and appropriate. Check performance Akida Examples. AutoKeras: An AutoML system based on Keras. The objective is to identify (predict) different fashion products from the given images using a CNN model. Documentation for the TensorFlow for R interface. Here is a utility I made for visualizing filters with Keras, using a few regularizations for more natural outputs. First, let's import the MNIST dataset from Keras. ienet1308 August 2, 2018, 7:39am #1. The examples covered in this post will serve as a template/starting point for building your own deep learning APIs — you will be able to extend the code and customize it based on how scalable and robust your API endpoint needs to be. import keras: from keras. py # run adding problem task cd copy_memory/ python main. Gets to 99. You’ll use both TensorFlow core and Keras to implement this logistic regression algorithm. keras package uses TensorFlow checkpoint format, which doesn’t have this issue. # encoding:utf-8 from __future__ import print_function import keras from keras. Reproduction of the IRNN experiment with pixel-by-pixel sequential MNIST in “A Simple Way to Initialize Recurrent Networks of. Simple steps to distributed deep learning with HorovodRunner. py" from the link above, and run: python mnist_mlp. Now that you have Keras and TensorFlow installed in your Python, they can be used for deep learning applications. Bear with me: MNIST is where everyone in machine learning starts, but I hope this tutorial is different from the others out there. mnist_irnn: Reproduction of the IRNN experiment with pixel-by-pixel sequential MNIST in "A Simple Way to Initialize Recurrent Networks of Rectified Linear Units" by Le et al. SimpleRNN(). layers import Dropout from keras. Let's import required libraries. We will learn about the basic functionality of keras using an example. January 23, 2017. Fashion-MNIST is intended to serve as a direct drop-in replacement for the original MNIST dataset for benchmarking machine learning algorithms, as it shares the same. import keras from keras. MNIST prediction using Keras and building CNN from scratch in Keras - MNISTwithKeras. load(path) numpy. Published July 1, 2018 | Full size is 1578 × 941 pixels MNIST_Viewer_5. Thanks for this excellent post! However, I think there is a problem with the cross-entropy implementation: since we are using vector donation of original image, the cross-entropy loss should not be like that in the code. This notebook is hosted on GitHub. utils import np_utils from keras. py Trains a simple deep multi-layer perceptron on the MNIST dataset. Neural Networks in Keras. MNIST Example. Browse our catalogue of tasks and access state-of-the-art solutions. For models built as a sequence of layers Keras offers the Sequential API. keras for Keras, which is TensorFlow’s implementation of the Keras API specification. Sequential(). callbacks import Callback from tensorflow. For example, the labels for the above images are 5. # encoding:utf-8 from __future__ import print_function import keras from keras. cifar10_cnn. Keras - tensorflow serving - Iris example. Examples to use pre-trained CNNs for image classification and feature extraction. This is a follow up to an earlier question where I had an issue with accuracy - resolved partially by changing the format of my input data. However, the code shown here is not exactly the same as in the Keras example. 16 seconds per epoch on a GRID K520 GPU. We support import of all Keras model types, most layers and practically all utility functionality. In this tutorial, I talk about making deep learning tutorial on MNIST data using dense layers. MNIST dataset is a standard and keras provides API to download it for convenience. " ] }, { "cell_type": "markdown", "metadata": { "colab_type": "text", "id": "udLObUVeGfTs" }, "source": [ "This tutorial builds a quantum neural network (QNN) to. Let us take a simple example of numpy random data to use this concept. As an example when we train the model on black and white images of digits. We will use the LSTM network to classify the MNIST data of handwritten digits. load() 函数起到很重要的作用。它可以读取. From there, I'll show you how to implement and train a. It shows how the flatten operation is performed as part of a model built using the Sequential() function which lets you sequentially add on layers to create your neural network model. layers import Dense, Flatten, Conv3D, MaxPooling3D from keras. Find file Copy path. Deep Learning for humans. We will show a practical implementation of using a Denoising Autoencoder on the MNIST handwritten digits dataset as an example. First of all, I am using the sequential model and eliminating the parallelism for simplification. models import Sequential from keras. Consult Auxiliary Classifier Generative Adversarial Networks in Keras for more information and example output. com 事前準備 入れるもの CUDA関係のインストール Anacondaのインストール Tensorflowのインストール 仮想環境の構築 インストール 動作確認 出会ったエラー達 Tensorflow編 CUDNNのPATHがない 初回実行時?の動作 Kerasのインストール MNISTの. fashion_mnist = keras. keras) module Part of core TensorFlow since v1. Let us take a simple example of numpy random data to use this concept. 4 mnist_cnn. A HelloWorld Example with Keras | DHPIT. MNIST with Keras You probably have already head about Keras - a high-level neural networks API, written in Python and capable of running on top of either TensorFlow or Theano. They are from open source Python projects. The MachineLearning community on Reddit. Burges, Microsoft Research, Redmond The MNIST database of handwritten digits, available from this page, has a training set of 60,000 examples, and a test set of 10,000 examples. This scenario shows how to use TensorFlow to the classification task. Text-tutorial and notes: https://pythonprogramming. MNIST Example. This is a sample of the tutorials available for these projects. Importing the fashion_mnist dataset has been outlined in tensorflow documention here. Since Keras runs on top of TensorFlow, you can use the TensorFlow estimator and import the Keras library using the pip_packages argument. Proceedings of the IEEE, 86(11):2278-2324, November 1998. I have played with the Keras official image_ocr. MNIST with Keras You probably have already head about Keras - a high-level neural networks API, written in Python and capable of running on top of either TensorFlow or Theano. An autoencoder is a regression task where the network is asked to predict its input (in other words, model the identity function). The mnist_test. models import Sequential from keras. HorovodRunner TensorFlow and Keras MNIST example notebook. Today, we will visualize the Convolutional Neural Network that we created earlier to demonstrate the benefits of using CNNs over densely-connected ones. Documentation for the TensorFlow for R interface. Once keras-tcn is installed as a package, you can take a glimpse of what's possible to do with TCNs. mnist import input_data from sklearn. layers import Input, Dense, Reshape, Flatten, Embedding, Dropout from keras. Keras is a popular machine learning library. mnist import input_data #MNIST 데이터 MNIST with Keras. As the title suggest, this post approaches building a basic Keras neural network using the Sequential model API. Implement various deep-learning algorithms in Keras and see how deep-learning can be used in games See how various deep-learning models and practical use-cases can be implemented using Keras A practical, hands-on guide with real-world examples to give you a strong foundation in Keras. For example, a full-color image with all 3 RGB channels will have a depth of 3. It contains a training set of 60000 examples, and a test set of 10000 examples. # encoding:utf-8 from __future__ import print_function import keras from keras. An updated deep learning introduction using Python, TensorFlow, and Keras. For Example: If you have 0-9 images, then you should make. layers import Dense, Flatten, Conv3D, MaxPooling3D from keras. Actually, TensorFlow itself in Python is mature enough to conduct deep learning activities and KeRas is even faster and more simple to train with than TensorFlow only in deep learning activities. Now that the input data for our Keras LSTM code is all setup and ready to go, it is time to create the LSTM network itself. First, let’s import the MNIST dataset from Keras. To begin with, let's take a look at the first 9 images in the training dataset. Trains a simple convnet on the MNIST dataset. mnist module is imported. learned automatically from examples rather than engineered by a human. layers import Dense, Dropout, LeakyReLU, Conv2D from keras. Implement various deep-learning algorithms in Keras and see how deep-learning can be used in games See how various deep-learning models and practical use-cases can be implemented using Keras A practical, hands-on guide with real-world examples to give you a strong foundation in Keras. Now that you know how the image augmentation API in Keras works, let's look at some examples. Fashion-MNIST is a dataset of Zalando’s article images consisting of a training set of 60,000 examples and a test set of 10,000 examples. Pre-trained models and datasets built by Google and the community. Contribute to keras-team/keras development by creating an account on GitHub. 0 ,想要運用 [ TensorFlow 2. MNIST prediction using Keras and building CNN from scratch in Keras - MNISTwithKeras. Why use Keras; Getting started. Autoencoder is a data compression algorithm where the compression and decompression functions learned automatically from examples rather than engineered by a human. In this post, we'll build a simple Convolutional Neural Network (CNN) and train it to solve a real problem with Keras. load_data() which downloads the data from its servers if it is not present on your computer. The MNIST dataset is one of the most common datasets used for image classification and accessible from many different sources. They are from open source Python projects. Being able to go from idea to result with the least possible delay is key to doing good research. However, for JPEG, we can compress it down to a tenth of the original data without any noticeable loss in image quality!. 4 Full Keras API. It downloads the mnist dataset and reshapes the matrices in order to. html: So I am having trouble learning Keras. Text-tutorial and notes: https://pythonprogramming. We build on the example above using timeserio ’s multinetwork, and demonstrate some key features: we add a digit classifier that uses pre-trained encodings. fashion_mnist. You can vote up the examples you like or vote down the ones you don't like. I hope you enjoyed this tutorial! If you did, please make sure to leave a like, comment, and subscribe! It really does help out a lot! Links: Source Code: ht. 3)提供了一种能够顺利运行 keras 源码中 example 下 mnist 的相关案例; 4)找到了另外几种解决方案,提供了相关的链接。 numpy. In this I'm gonna show how to build a CNN model to solve the mnist dataset, a dataset of 60,000 handwritten images, each image is 28x28. However, for JPEG, we can compress it down to a tenth of the original data without any noticeable loss in image quality!. save関数を追加して、学習したモデルをファイルとして保存します。 このコードを実行して学習が終わると"model_mnist_cnn. 0 I can now see that both Keras and TF are using the GPU w/ tegrastats, however whereas TF mnist example gives 92% accuracy, the Keras 1. By voting up you can indicate which examples are most useful and appropriate. Although the dataset is effectively solved, it can be used as the basis for learning and practicing how to develop, evaluate, and use convolutional …. Sep 22 2018- POSTED BY Brijesh Comments Off on Convolutional Neural Networks in TensorFlow Keras with MNIST x as a dict and y, respectively. But predictions alone are boring, so I’m adding explanations for the predictions using the lime package. This function downloads the data using keras's mnist dataset, shards it based on the rank and size of the worker, and converts it to shapes and types suitable for training. backward() and have all the gradients. ipynb 的速度较慢,建议在 Nbviewer 中查看该项目。 简介大部分内容来自keras项目中的exampleKera….