Keras Utility&Layer Collection.

kulc的Python项目详细描述


Keras实用程序和层集合[WIP]

主框架中缺少的路缘石自定义层的集合。这些层可能有助于使用keras复制当前最先进的深度学习论文。

应用程序

使用此库,以下研究论文已在Keras中重新实现:

实现层概述

目前,Keras Layer Collection提供以下层/功能:

缩放点积注意

Implementation as described in Attention Is All You Need。通过比较查询Q和键K,对值V执行非线性转换。下图摘自上述论文。

多头注意

Implementation as described in Attention Is All You Need。这基本上只是一堆aScaled Dot-Product Attention块,其输出与线性转换相结合。下图摘自上述论文。

层规范化

Sequencewise Attention

This layer applies various attention transformations on data. It needs a time-series of queries and a time-series of values to calculate the attention and the final linear transformation to obtain the output. This is a faster version of the general attention technique. It is similar to the ^{} method described in Effective Approaches to Attention-based Neural Machine Translation

注意包装纸

The idea of the implementation is based on the paper Effective Approaches to Attention-based Neural Machine Translation。这个层可以包裹在Keras中的任何RNN周围。它计算前一个输出步骤和所有输入步骤之间的注意力向量。这样,就为RNN构造了一个新的基于注意力的输入。这个输入最终被输入到RNN。这种技术类似于本文中描述的input-feeding方法。下图摘自上述论文。

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
ws-consumer服务地址中的java动态属性   java如何比较整数列表,然后按升序排序?   javascript我正在使用java脚本调用一个函数,但它没有调用代码下面的方法,也没有调用secretitnames()函数   在文本窗格中多次使用Java insertIcon图标   JavaMSAL安卓。AuthenticationActivity完成,但用于身份验证请求的线程池线程仍处于等待状态   if语句中的java多范围比较   java toString()表示输出   java如何在jcstrest测试中生成指令重新排序   java我怎样才能运行它?   web应用程序中使用Hibernate和Spring的java问题   如何将字符串数据写入Java文本文件   如何在java命令提示符下运行已签名的jar文件?   java从我的菜单调用RCP应用程序   java如何等待Canvas/GraphicsContext完成任务,然后再继续执行代码块?