官网实例详解-目录和实例简介-keras学习笔记四

官网实例详解-目录和实例简介-keras学习笔记四

版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
本文链接:https://blog.csdn.net/wyx100/article/details/80647379

https://github.com/keras-team/keras/tree/master/examples

Keras examples directory

Keras实例目录 (点击跳转)

官网实例详解4.1(addition_rnn.py)

官网实例详解4.2(antirectifier.py)

官网实例详解4.3(babi_memnn.py)

官网实例详解4.4(babi_rnn.py)

官网实例详解4.5(cifar10_cnn.py)

官网实例详解4.6(cifar10_cnn_capsule.py)

官网实例详解4.7(cifar10_cnn_tfaugment2d.py)

官网实例详解4.8(cifar10_resnet.py)

官网实例详解4.9(conv_filter_visualization.py)

官网实例详解4.10(conv_lstm.py)

官网实例详解4.11(deep_dream.py)

官网实例详解4.12(image_ocr.py)

官网实例详解4.13(imdb_bidirectional_lstm.py)

官网实例详解4.14(imdb_cnn.py)

官网实例详解4.15(imdb_cnn_lstm.py)

官网实例详解4.16(imdb_fasttext.py)

官网实例详解4.17(imdb_lstm.py)

官网实例详解4.18(lstm_seq2seq.py)

官网实例详解4.19(lstm_seq2seq_restore.py)

官网实例详解4.20(lstm_stateful.py)

官网实例详解4.21(lstm_text_generation.py)

官网实例详解4.22(mnist_acgan.py)

官网实例详解4.23(mnist_cnn.py)

官网实例详解4.24(mnist_dataset_api.py)

官网实例详解4.26(mnist_hierarchical_rnn.py)

官网实例详解4.25(mnist_denoising_autoencoder.py)

官网实例详解4.27(mnist_irnn.py)

官网实例详解4.28(mnist_mlp.py)

官网实例详解4.29(mnist_net2net.py)

官网实例详解4.31(mnist_sklearn_wrapper.py)

官网实例详解4.32(mnist_swwae.py)

官网实例详解4.33(mnist_tfrecord.py)

官网实例详解4.34(mnist_transfer_cnn.py)

官网实例详解4.35(neural_doodle.py)

官网实例详解4.37(pretrained_word_embeddings.py)

官网实例详解4.38(reuters_mlp.py)

官网实例详解4.39(reuters_mlp_relu_vs_selu.py)

官网实例详解4.40(variational_autoencoder.py)

官网实例详解4.41(variational_autoencoder_deconv.py)

官网实例详解4.42(imdb.py)

   Vision models examplesion models examples

视觉模型实例

mnist_mlp.py Trains a simple deep multi-layer perceptron on the MNIST dataset.

                         基于MINIST数据集训练简单的深度多层感知机

mnist_cnn.py Trains a simple convnet on the MNIST dataset.

                         基于MINIST数据集训练简单的卷积(神经网络)

cifar10_cnn.py Trains a simple deep CNN on the CIFAR10 small images dataset.

                         基于CIFAR10(较少图片)数据集训练简单深度卷积神经网络(deep CNN,深度卷积神经网络)

cifar10_resnet.py Trains a ResNet on the CIFAR10 small images dataset.

                         基于CIFAR10(较少图片)数据集训练ResNet(一种深度卷积神经网络)

conv_lstm.py Demonstrates the use of a convolutional LSTM network.

                         卷积LSTM(Long Short-Term Memory,长短期记忆网络)网络的使用演示

image_ocr.py Trains a convolutional stack followed by a recurrent stack and a CTC logloss function to perform optical character recognition (OCR).

                         训练一个卷积栈,后跟循环栈和CTC对数损失函数,演示光学字符识别。

                         CTC模型(Connectionist temporal classification,联结时间分类)接在RNN网络的最后一层用于序列学习所用;对于一段长度为T的序列来说,每个样本点 t 在RNN网络的最后一层都会输出一个softmax向量,表示预测概率;接上CTC模型之后,就可以正确预测出序列的标签;

                       OCR (Optical Character Recognition,光学字符识别)是指电子设备(例如扫描仪或数码相机)检查纸上打印的字符,通过检测暗、亮的模式确定其形状,然后用字符识别方法将形状翻译成计算机文字的过程;即,针对印刷体字符,采用光学的方式将纸质文档中的文字转换成为黑白点阵的图像文件,并通过识别软件将图像中的文字转换成文本格式,供文字处理软件进一步编辑加工的技术。

mnist_acgan.py Implementation of AC-GAN (Auxiliary Classifier GAN) on the MNIST dataset

                         基于MINIST数据集执行AC-GAN(辅助分类生成对抗网络)

                         GAN(Generative Adversarial Networks ,生成式对抗网络)是一种深度学习模型,是近年来复杂分布上无监督学习最具前景的方法之一。模型通过框架中(至少)两个模块:生成模型(Generative Model)和判别模型(Discriminative Model)的互相博弈学习产生相当好的输出。原始 GAN 理论中,并不要求 G 和 D 都是神经网络,只需要是能拟合相应生成和判别的函数即可。但实用中一般均使用深度神经网络作为 G 和 D 。一个优秀的GAN应用需要有良好的训练方法,否则可能由于神经网络模型的自由性而导致输出不理想。

mnist_hierarchical_rnn.py Trains a Hierarchical RNN (HRNN) to classify MNIST digits.

                         训练分层循环神经网络(HRNN)分类MINIST数字

mnist_siamese.py Trains a Siamese multi-layer perceptron on pairs of digits from the MNIST dataset.

                         在MNIST数据集的一对数字上训练一个连体多层感知器

mnist_swwae.py Trains a Stacked What-Where AutoEncoder built on residual blocks on the MNIST dataset.

                          基于MNIST数据集训练堆叠建立在残余模块的自解码器

mnist_transfer_cnn.py Transfer learning toy example.

                         迁移学习实例


Text & sequences examples

文本&序列实例

addition_rnn.py Implementation of sequence to sequence learning for performing addition of two numbers (as strings).

                         演示序列学习实现2个数字(字符串格式)的加法

babi_rnn.py Trains a two-branch recurrent network on the bAbI dataset for reading comprehension.

                         基于bAbI数据集训练两个分支的循环(神经)网络,实现阅读理解(看图说话)

babi_memnn.py Trains a memory network on the bAbI dataset for reading comprehension.

                         基于bAbI数据集训练记忆网络,实现阅读理解(看图说话)

imdb_bidirectional_lstm.py Trains a Bidirectional LSTM on the IMDB sentiment classification task.

                         基于IMDB(Internet Movie Database,互联网电影资料库。亚马逊旗下,一个关于电影演员、电影、电视节目、电视明星和电影制作的在线数据库)训练双向LSTM实现情感分类任务

imdb_cnn.py Demonstrates the use of Convolution1D for text classification.

                         基于IMDB(数据库)使用一维度卷积文本分类

imdb_cnn_lstm.py Trains a convolutional stack followed by a recurrent stack network on the IMDB sentiment classification task.

                         训练一个卷积栈,后跟循环栈网络,基于IMDB进行情感分类任务

imdb_fasttext.py Trains a FastText model on the IMDB sentiment classification task.

                         基于IMDB(数据库)情感分类任务训练快速文本模型

imdb_lstm.py Trains an LSTM model on the IMDB sentiment classification task.

                         基于IMDB(数据库)情感分类任务训练LSTM(一种RNN网络)模型

lstm_stateful.py Demonstrates how to use stateful RNNs to model long sequences efficiently.

                         带状态RNN高效地对长序列进行建模演示

pretrained_word_embeddings.py Loads pre-trained word embeddings (GloVe embeddings) into a frozen Keras Embedding layer, and uses it to train a text classification model on the 20 Newsgroup dataset.

                         加载预训练的词嵌入(手动)到Keras已冻结嵌入层,并基于20个Newsgroup(新闻组)数据集训练一个文本分类模型

                         新闻组(英文名Usenet或NewsGroup),简单地说就是一个基于网络的计算机组合,这些计算机被称为新闻服务器,不同的用户通过一些软件可连接到新闻服务器上,阅读其他人的消息并可以参与讨论。新闻组是一个完全交互式的超级电子论坛,是任何一个网络用户都能进行相互交流的工具。

reuters_mlp.py Trains and evaluate a simple MLP on the Reuters newswire topic classification task.

                         基于路透社的新闻专线主题分类任务,训练和评估一个简单的多层感知机。

                         Reuters,路透社(Reuters,LSE:RTR,NASDAQ: RTRSY)是世界上最早创办的通讯社之一,也是目前英国最大的通讯社和西方四大通讯社之一。路透社是世界前三大的多媒体新闻通讯社,提供各类新闻和金融数据,在128个国家运行。


Generative models examples

生成模型实例

lstm_text_generation.py Generates text from Nietzsche's writings.

                         基于尼采的作品生成文本(基于LSTM)

conv_filter_visualization.py Visualization of the filters of VGG16, via gradient ascent in input space.

                         通过输入空间中的梯度上升可视化VGG16滤波器

deep_dream.py Deep Dreams in Keras.

                         基于Keras的深度梦想(通过神经网络,生成梦幻的图片)

neural_doodle.py Neural doodle.

                         神经涂鸦

neural_style_transfer.py Neural style transfer.

                         神经风格转换

variational_autoencoder.py Demonstrates how to build a variational autoencoder.

                         如何建立变分自解码器

variational_autoencoder_deconv.py Demonstrates how to build a variational autoencoder with Keras using deconvolution layers.

                         使用Keras反卷积层建立变分自解码器演示


Examples demonstrating specific Keras functionality

Keras特定功能演示实例

antirectifier.py Demonstrates how to write custom layers for Keras.

                         如何使用Keras建立自定义层

mnist_sklearn_wrapper.py Demonstrates how to use the sklearn wrapper.

                         演示sklearn(scikit-learn,python机器学习库)包装器使用

mnist_irnn.py 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.

                         根据“A Simple Way to Initialize Recurrent Networks of Rectified Linear Units”(用RLU初始化RNN的简单方法)论文,基于MINIST数据集进行IRNN(Implementing Recurrent Neural Net using chainer,链表实现递归神经网络)实验

mnist_net2net.py Reproduction of the Net2Net experiment with MNIST in "Net2Net: Accelerating Learning via Knowledge Transfer".

                         根据“Net2Net: Accelerating Learning via Knowledge Transfe”(知识迁移加速学习)论文,基于MINIST数据集进行实验

reuters_mlp_relu_vs_selu.py Compares self-normalizing MLPs with regular MLPs.

                         比较自归一化感知机和规则感知机

mnist_tfrecord.py MNIST dataset with TFRecords, the standard TensorFlow data format.

                         TFRecords格式的MNIST数据集,该格式是Tensorflow标准数据格式

mnist_dataset_api.py MNIST dataset with TensorFlow's Dataset API.

                         基于TensorFlow数据集API(应用程序接口)的MINIST

推荐

https://blog.csdn.net/ice_actor/article/details/78290830

Keras相关资料

英文:https://keras.io/

中文:http://keras-cn.readthedocs.io/en/latest/

实例下载

https://github.com/keras-team/keras

https://github.com/keras-team/keras/tree/master/examples

原文地址:https://www.cnblogs.com/think90/p/11712115.html