Merge branch 'main' into contribution_analysis

This commit is contained in:
Dalong
2022-04-24 15:06:27 +08:00
committed by GitHub
76 changed files with 4443 additions and 3353 deletions

View File

@@ -64,6 +64,8 @@
- **可解释性AI系统:** 随着机器学习在安全攸关(Safety-critical)领域的应用,机器学习系统越来越需要对决策给出充分解释。本书将会讨论可解释AI系统的常用方法和落地实践经验。
- **机器人学习系统:** 随着机器学习在机器人领域的应用,机器人学习及相关系统设计成为日益重要的研究领域。本书将会讨论机器人学习的常用方法及其相关系统设计。
我们在持续拓展拓展本书的内容,如元学习系统,自动并行,深度学习集群调度,绿色AI系统,图学习系统等。我们也非常欢迎社区对于新内容提出建议,贡献章节。
## 构建指南

View File

@@ -1,5 +1,4 @@
加速器基本组成原理
------------------
## 加速器基本组成原理
上节主要介绍了加速器的意义以及设计思路,了解到加速器与通用处理器在设计上的区别,因此加速器的硬件结构与CPU的硬件结构有着根本的不同,通常都是由多种片上缓存以及多种运算单元组成。本章节主要通过GPU的Volta架构作为样例进行介绍。
@@ -83,4 +82,4 @@ GPU计算单元主要由标量计算单元和三维向量计算单元组成。
:width:`800px`
:label:`davinci_architecture`
昇腾AI芯片的计算核心主要由AI Core构成,负责执行标量、向量和张量相关的计算密集型算子。AI Core采用了达芬奇架构,基本结构如 :numref:`davinci_architecture`所示,从控制上可以看成是一个相对简化的现代微处理器基本架构。它包括了三种基础计算单元:矩阵计算单元(Cube Unit)、向量计算单元(Vector Unit)和标量计算单元(Scalar Unit)。这三种计算单元分别对应了张量、向量和标量三种常见的计算模式,在实际的计算过程中各司其职,形成了三条独立的执行流水线,在系统软件的统一调度下互相配合达到优化计算效率的目的。 同GPU类似,在矩阵乘加速设计上,在AICore中也提供了矩阵计算单元作为昇腾AI芯片的核心计算模块,意图高效解决矩阵计算的瓶颈问题。矩阵计算单元提供强大的并行乘加计算能力,可以用一条指令完成两个$16\times16$矩阵的相乘运算,等同于在极短时间内进行了$16\times16\times16=4096$个乘加运算,并且可以实现FP16的运算精度。
昇腾AI芯片的计算核心主要由AI Core构成,负责执行标量、向量和张量相关的计算密集型算子。AI Core采用了达芬奇架构 :cite:`2021Ascend`,基本结构如 :numref:`davinci_architecture`所示,从控制上可以看成是一个相对简化的现代微处理器基本架构。它包括了三种基础计算单元:矩阵计算单元(Cube Unit)、向量计算单元(Vector Unit)和标量计算单元(Scalar Unit)。这三种计算单元分别对应了张量、向量和标量三种常见的计算模式,在实际的计算过程中各司其职,形成了三条独立的执行流水线,在系统软件的统一调度下互相配合达到优化计算效率的目的。 同GPU类似,在矩阵乘加速设计上,在AICore中也提供了矩阵计算单元作为昇腾AI芯片的核心计算模块,意图高效解决矩阵计算的瓶颈问题。矩阵计算单元提供强大的并行乘加计算能力,可以用一条指令完成两个$16\times16$矩阵的相乘运算,等同于在极短时间内进行了$16\times16\times16=4096$个乘加运算,并且可以实现FP16的运算精度。

View File

@@ -1,9 +1,8 @@
概述
----
## 概述
### 硬件加速器设计的意义
未来人工智能发展的三大核心要素是数据、算法和算力。目前,人工智能系统算力大都构建在CPU+GPU之上,主体多是GPU。随着神经网络层数的增多,模型体量的增大,算法复杂度的上升,CPU和GPU很难再满足新型网络对于算力的需求。例如,2015年谷歌的AlphaGo与樊麾对弈时,用了1202个CPU和176个GPU,每盘棋需要消耗上千美元的电费,而与之对应的是樊麾的功耗仅为20瓦。
未来人工智能发展的三大核心要素是数据、算法和算力。目前,人工智能系统算力大都构建在CPU+GPU之上,主体多是GPU。随着神经网络层数的增多,模型体量的增大,算法复杂度的上升,CPU和GPU很难再满足新型网络对于算力的需求。例如,2015年谷歌的AlphaGo与[樊麾](https://baike.baidu.com/item/樊麾)对弈时,用了1202个CPU和176个GPU,每盘棋需要消耗上千美元的电费,而与之对应的是樊麾的功耗仅为20瓦。
虽然GPU在面向向量、矩阵以及张量的计算上,引入许多新颖的优化设计,但由于GPU需要支持的计算类型复杂,芯片规模大、能耗高,人们开始将更多的精力转移到深度学习硬件加速器的设计上来。和传统CPU和GPU芯片相比,新型深度学习加速器会有更高的性能,以及更低的能耗。未来随着人们真正进入智能时代,智能应用的普及会越来越广泛,到那时每台服务器、每台智能手机、每个智能摄像头,都需要使用加速器。

View File

@@ -1,5 +1,4 @@
加速器基本编程原理
------------------
## 加速器基本编程原理
:label:`accelerator-program-title`
本章前两节主要介绍了硬件加速器设计的意义、思路以及基本组成原理。软硬件协同优化作为构建高效AI系统的一个重要指导思想,需要软件算法/软件栈和硬件架构在神经网络应用中互相影响、紧密耦合。为了最大限度地发挥加速器的优势,要求能够基于硬件系统架构提供易用、高效的编程方法。因此,在本节中将着重介绍加速器的可编程性,包括编程接口直接调用方式及算子编译器优化方式。最后,通过示例介绍如何通过编程使能加速器,提升神经网络算子的计算效率。
@@ -190,3 +189,5 @@ res = te.lang.cce.matmul(tensor_a, tensor_b, False, False, False, dst_dtype=dst_
4. **优化数据访存------提高并行性**:在进行内存结构变化(矩阵数据搬移)时,需要注意全局内存的合并访问、共享内存的存储体冲突等常见性能瓶颈点。
5. **资源负载均衡------增大吞吐量**:调整平衡每个线程处理的数据量、共享内存使用量、寄存器使用量,以获得更高的SM占用率。一般在实际程序中BlockTile和WarpTile的选取至关重要。
6. **优化指令执行**:使用\#unroll功能进行循环展开来提升指令级并行,如 :numref:`gemm-tensor-core-algorith`中13行;使用向量化加载指令以提高带宽等,对于GPU Volta架构,最大向量化加载指令为ldg128,即128比特带宽,对于 :numref:`gemm-tensor-core-algorith`中5-6行数据由全局内存加载至共享内存时,即可采用Float4\*类型指针进行内存读取。

View File

@@ -1,10 +1,16 @@
总结
----
## 总结
- 面向深度学习计算任务,加速器通常都是由多种片上缓存以及多种运算单元组成来提升性能。
- 面向深度学习计算任务,加速器通常都是由多种片上缓存以及多种运算单元组成来提升性能。
- 未来性能增长需要依赖架构上的改变,即需要利用可编程的硬件加速器来实现性能突破。
- 未来性能增长需要依赖架构上的改变,即需要利用可编程的硬件加速器来实现性能突破。
- 出于计算效率和易用性等原因,加速器一般会具有多个等级的编程方式,包括:算子库层级,编程原语层级和指令层级。
- 出于计算效率和易用性等原因,加速器一般会具有多个等级的编程方式,包括:算子库层级,编程原语层级和指令层级。
- 越底层的编程方式越能够灵活地控制加速器,但同时对程序员的能力要求也越高。
- 越底层的编程方式越能够灵活地控制加速器,但同时对程序员的能力要求也越高。
## 扩展阅读
- CUDA编程指导 [CUDA](https://docs.nvidia.com/cuda/cuda-c-programming-guide/index.html)
- 昇腾社区 [Ascend](https://gitee.com/ascend)
- MLIR应用进展 [MLIR](https://mlir.llvm.org/talks)

View File

@@ -4,7 +4,7 @@
如 :numref:`compiler-backend-architecture`所示,编译器后端处于前端和硬件驱动层中间,主要负责计算图优化、算子选择和内存分配的任务。首先,需要根据硬件设备的特性将IR图进行等价图变换,以便在硬件上能够找到对应的执行算子,该过程是计算图优化的重要步骤之一。前端IR生成是解析用户代码,属于一个较高的抽象层次,隐藏一些底层运行的细节信息,此时无法直接对应硬件上的算子(算子是设备上的基本计算序列,例如MatMul、Convolution和ReLU等),需要将细节信息进行展开后,才能映射到目标硬件上的算子。对于某些前端IR的子集来说,一个算子便能够执行对应的功能,此时可以将这些IR节点合并成为一个计算节点,该过程称之为算子融合;对于一些复杂计算,后端并没有直接与之对应的算子,但是可以通过几个基本运算的算子组合达到同样的计算效果,此时可以将前端IR节点拆分成多个小算子。然后,我们需要进行算子选择。算子选择是在得到优化的IR图后,需要选取最合适的目标设备算子。针对用户代码所产生的IR往往可以映射成多种不同的硬件算子,但是生成不同的算子执行效率往往有很大的差别,如何根据前端IR选择出最高效的算子,是算子选择的核心问题。算子选择本质上是一个模式匹配问题。其最简单的方法就是每一个IR节点对应一个目标硬件的算子,但是这种方法往往对目标硬件的资源利用比较差。目前来说对于现有的编译器一般都对每一个IR节点提供了多个候选的算子,算子选择目标就是从中选择最优的一个算子作为最终执行在设备上的算子。总的来说,在机器学习系统中,对前端生成的IR图上的各个节点进行拆分和融合,让前端所表示的高层次IR逐步转换为可以在硬件设备上执行的低层次IR。得到了这种更加贴合硬件的IR后,对于每个单节点的IR可能仍然有很多种不同的选择,例如可以选择不同的输入输出格式和数据类型,我们需要对IR图上每个节点选择出最为合适的算子,算子选择过程可以认为是针对IR图的细粒度优化过程,最终生成完整的算子序列。最后,遍历算子序列,为每个算子分配相应的输入输出内存,然后将算子加载到设备上执行计算。
![编译器后端总体架构简图](../img/ch05/compiler-backend-architecture.jpeg)
![编译器后端总体架构简图](../img/ch05/compiler-backend-architecture.png)
:width:`800px`
:label:`compiler-backend-architecture`

View File

@@ -7,7 +7,7 @@
:label:`simpledag`
### 张量和算子
在计算框架中,基础组件包含张量和算子,张量是基础数据结构,算子是基本运算单元。在数学中定义张量是基于向量与矩阵的推广,涵盖标量、向量与矩阵的概念。可以将标量理解为零阶张量,向量为一阶张量,我们熟悉的RGB彩色图像即为三阶张量。在计算框架中张量不仅存储数据,还存储数据类型、数据形状、维度或秩以及梯度传递状态等多个属性,如表3.2.1所示,列举了主要的属性和功能。
在计算框架中,基础组件包含张量和算子,张量是基础数据结构,算子是基本运算单元。在数学中定义张量是基于向量与矩阵的推广,涵盖标量、向量与矩阵的概念。可以将标量理解为零阶张量,向量为一阶张量,我们熟悉的RGB彩色图像即为三阶张量。在计算框架中张量不仅存储数据,还存储数据类型、数据形状、维度或秩以及梯度传递状态等多个属性,如:numref:`tensor_attr`所示,列举了主要的属性和功能。
:张量属性
@@ -145,7 +145,7 @@ $$
其中$\nabla_{\boldsymbol{X}}\boldsymbol{z}$表示$\boldsymbol{z}$关于$\boldsymbol{X}$的梯度矩阵。
上一小节中简单的循环控制模型前向传播可以表示为$\boldsymbol{Y}=\boldsymbol{W_2}(\boldsymbol{W_1}(\boldsymbol{W}(\boldsymbol{X})))$。在反向传播的过程中可以将前向计算等价为$\boldsymbol{Y}=\boldsymbol{W_2}\boldsymbol{X_2}$,首先得到参数$\boldsymbol{W_2}$的梯度表示。再接着根据$\boldsymbol{X_2}=\boldsymbol{W_1}\boldsymbol{X_1}$得到$\boldsymbol{W_1}$的梯度表示,按照层级即可推导得出$\boldsymbol{W}$的梯度表示。
上一小节中简单的循环控制模型前向传播可以表示为$\boldsymbol{Y}=\boldsymbol{W_2}(\boldsymbol{W_1}(\boldsymbol{W}(\boldsymbol{X})))$。在反向传播的过程中可以将前向计算等价为$\boldsymbol{Y}=\boldsymbol{W_2}\boldsymbol{X_2}$,首先得到参数$\boldsymbol{W_2}$的梯度表示。再接着根据$\boldsymbol{X_2}=\boldsymbol{W_1}\boldsymbol{X_1}$得到$\boldsymbol{W_1}$的梯度表示,按照层级即可推导得出$\boldsymbol{W}$的梯度表示:
$$
\begin{aligned}

View File

@@ -22,7 +22,7 @@ def model(X, flag):
```
完成前端语言的模型完整构建表达后,执行模型运算时不会直接接收输入数据进行计算,而是使用计算框架的编译器对模型进行编译。由于在进行静态生成编译时并不读取输入数据,此时需要一种特殊的张量来表示输入数据辅助构建完整的计算图,这种特殊张量就被称之为"数据占位符"。在上述的伪代码中输入数据**X**需要使用占位符在静态图中表示。构造伪代码中的条件控制时,由于在静态图模式下构建网络并没有执行任何计算,对于条件控制在编译阶段并不会进行逻辑运算完成判断,因此需要将条件控制算子以及所有的分支计算子图加入计算图中。在执行阶段网络接受数据流入,调度条件控制算子时进行逻辑判断,控制数据流入不同的分支计算子图中进行后续计算。由于控制流和静态生成的特殊性,在部分计算框架中前端语言Python的控制流不能够被正确编译为等价的静态图结构,因此需要使用复杂的图内方法实现控制流。
在后续的章节中我们会继续深入了解计算框架静态生成图结构的过程。静态生成的过程是采用计算框架编译器将代码编译为中间表示。计算框架编译器受传统编译器方案启发,设计体系结构包含两部分编译器前端和编译器后端。中间表示承上启下贯穿前端和后端,是前端源代码和目标硬件代码之间的中间数据格式。在计算框架编译器中中间表示以计算图形式存在,编译器会根据前端神经网络模型自动构建完整的前向计算图和反向计算图。
在后续的章节中我们会继续深入了解计算框架静态生成图结构的过程。静态生成的过程是采用计算框架编译器将代码编译为中间表示。计算框架编译器受传统编译器方案启发,设计体系结构包含两部分:编译器前端和编译器后端。中间表示承上启下贯穿前端和后端,是前端源代码和目标硬件代码之间的中间数据格式。在计算框架编译器中中间表示以计算图形式存在,编译器会根据前端神经网络模型自动构建完整的前向计算图和反向计算图。
![静态生成](../img/ch03/static-gen.svg)
:width:`800px`
@@ -136,8 +136,8 @@ def model(X, flag):
|框架|动态图转静态图|
| :-:| :---: |
| TensorFlow |@tf_function追踪算子调度构建静态图,<br>其中AutoGraph机制可以自动转换控制流为静态表达 |
| MindSpore | context.set_context(mode=context.PYNATIVE_MODE) 动态图模式 <br> context.set_context(mode=context.GRAPH_MODE) 静态图模式 <br>\@ms_function支持基于源码转换 |
| MindSpore | context.set_context(mode=context.PYNATIVE_MODE) 动态图模式,<br> context.set_context(mode=context.GRAPH_MODE) 静态图模式,<br>\@ms_function支持基于源码转换 |
| PyTorch | torch.jit.script()支持基于源码转换,<br>torch.jit.trace()支持基于追踪转换 |
| PaddlePaddle | paddle.jit.to_static()支持基于源码转换,<br>paddle.jit.TracedLayer.trace()支持基于追踪转换 |
| PaddlePaddle | paddle.jit.to_static()支持基于源码转换,<br>paddle.jit.TracedLayer.trace()支持基于追踪转换 |
:label:`dynamic_static_switch`

View File

@@ -2,7 +2,7 @@
### 云云场景中的横向联邦
在横向联邦学习系统中,具有相同数据结构的多个参与者通过参数或云服务器协同学习机器学习模型。一个典型的假设是参与者是诚实的,而服务器是诚实但好奇的,因此不允许任何参与者向服务器泄漏信息。这种系统的训练过程通常包括以下四个步骤:
在横向联邦学习系统中,具有相同数据结构的多个参与者通过参数或云服务器协同建立机器学习模型。一个典型的假设是参与者是诚实的,而服务器是诚实但好奇的,因此不允许任何参与者向服务器泄漏信息。这种系统的训练过程通常包括以下四个步骤:
①:参与者在本地计算训练梯度,使用加密、差异隐私或秘密共享技术掩饰所选梯度,并将掩码后的结果发送到服务器;
@@ -12,12 +12,14 @@
④:参与者用解密的梯度更新他们各自的模型。
和传统分布式学习相比,联邦学习存在训练结点不稳定和通信代价大的难点。这些难点导致了联邦学习无法和传统分布式学习一样:在每次单步训练之后,同步不同训练结点上的权重。为了提高计算通信比并降低频繁通信带来的高能耗,谷歌公司提出了联邦平均算法(Federated Averaging,FedAvg)。 :numfef:`ch10-federated-learning-fedavg`展示了FedAvg的整体流程。在每轮联邦训练过程中,端侧进行多次单步训练。然后云侧聚合多个端侧权重,并取加权平均。
和传统分布式学习相比,联邦学习存在训练结点不稳定和通信代价大的难点。这些难点导致了联邦学习无法和传统分布式学习一样:在每次单步训练之后,同步不同训练结点上的权重。为了提高计算通信比并降低频繁通信带来的高能耗,谷歌公司在2017年 :cite:`fedavg`提出了联邦平均算法(Federated Averaging,FedAvg)。 :numfef:`ch10-federated-learning-fedavg`展示了FedAvg的整体流程。在每轮联邦训练过程中,端侧进行多次单步训练。然后云侧聚合多个端侧权重,并取加权平均。
![联邦平均算法](../img/ch10/ch10-federated-learning-fedavg.png)
:width:`800px`
:label:`ch10-federated-learning-fedavg`
随着研究和应用的深入,研究者们意识到了FedAvg不适用于某些场景。比如在数据异质性(端上数据不是I.I.D分布)、系统异质性(端设备时断时连)的情况下,对模型参数只进行简单的加权平均会在训练过程中引入大量偏差,从而影响模型的收敛速度、预测性能。针对此,研究人员提出了基于Momentum :cite:`FedAvg_Momentum`、Variation Control :cite:`scaffold`、Bayesian :cite:`FedBE`、Distillation :cite:`PATE`和Proximal Estimation :cite:`FedProx`等原理开发的算法和系统框架。
### 端云场景中的横向联邦
端云联邦的总体流程和云云联邦一样,但端云联邦学习面临的难点还包括以下三个方面:
@@ -52,4 +54,4 @@
2.松耦合组网:使用FL-Server集群。每个FL-Server接收和下发权重给部分FL-Client,减少单个FL-Server的带宽压力。此外,支持FL-Client以松散的方式接入。任意FL-Client的中途退出都不会影响全局任务,并且FL-Client在任意时刻访问任意FL-Server都能获得训练所需的全量数据。
3.加密模块:MindSpore Federated为了防止模型梯度的泄露,部署了多种加密算法:本地差分隐私(LDP)、基于多方安全计算(MPC)的安全聚合算法和华为自研的基于符号的维度选择差分隐私算法(SignDS)。
3.加密模块:MindSpore Federated为了防止模型梯度的泄露,部署了多种加密算法:本地差分隐私(LDP)、基于多方安全计算(MPC)的安全聚合算法和华为自研的基于符号的维度选择差分隐私算法(SignDS)。

View File

@@ -1,45 +1,47 @@
## 概述
随着人工智能的飞速发展,大规模和高质量的数据越来越重要,但也制约了其进一步的发展。隐私、监管和工程等问题造成了设备与设备之间的数据不能共享,进而导致了数据孤岛问题的出现。为了解决这一难题,联邦学习(Federated Learning,FL)应运而生。联邦学习的概念最早在2016年被提了出来,能有效帮助多个机构在满足用户隐私保护、数据安全和政府法规的要求下,进行数据使用和机器学习建模。
### 定义
联邦学习的核心即为数据不动,模型动。显然,若是将数据从各方集中在一起,不符合法律法规。联邦学习让模型在各个数据方“移动”,这样就可以达到数据不出端即可建模的效果。在联邦学习中,各方数据都保留在本地,通过交换加密的参数建立机器学习模型。
### 应用场景
在实际的应用场景中,根据样本和特征的重叠情况,联邦学习可以被分为横向联邦学习(样本不同,特征重叠),纵向联邦学习(特征不同,样本重叠)和联邦迁移学习(样本和特征都不重叠)。
**横向联邦学习**适用于不同参与方拥有的特征相同但参与的个体不同的场景。比如,在广告推荐场景中,有多个不同的手机用户。算法开发人员使用不同手机用户的相同特征(点击次数、停留时间或使用频次等特征)的数据来建立模型。由于这些特征数据不能出端,因此,横向联邦学习可以被联合多个用户的数据来构建模型。
**纵向联邦学习**适用于样本重叠多特征重叠少的场景。比如,有两个不同机构,一家是保险公司,另一家是医院。它们的用户群体很有可能包含该地的大部分居民,用户的交集可能较大。由于保险公司记录的都是用户的收支行为与信用评级,而医院则保有用户的疾病与购药记录,因此它们的用户特征交集较小。纵向联邦学习就是将这些不同特征在加密的状态下加以聚合,以增强模型能力的联邦学习。
**联邦迁移学习**的核心是找到源领域和目标领域之间的相似性。比如有两个不同机构,一家是位于中国的银行,另一家是位于美国的电商。由于受到地域限制,这两家机构的用户群体交集很小。同时,由于机构类型的不同,二者的数据特征也只有小部分重合。在这种情况下,要想进行有效的联邦学习,就必须引入迁移学习,来解决单边数据规模小和标签样本少的问题,从而提升模型的效果。
### 部署场景
联邦学习和参数服务器(数据中心分布式学习)架构非常相似,都是采用中心化的服务器和分散的客户端去构建同一个机器学习模型。此外,根据客户端来源和规模的不同,联邦学习还可以细分为跨设备(cross-device)与跨组织(cross-silo)联邦学习。一般而言,跨组织联邦学习的用户一般是企业、机构单位级别的,而跨设备联邦学习针对的则是便携式电子设备、移动端设备等。 :numref:`ch10-federated-learning-different-connection`展示了三者的区别和联系:
![数据中心分布式训练、跨组织和跨设备联邦学习的区别和联系](../img/ch10/ch10-federated-learning-different-connection.png)
:label:`ch10-federated-learning-different-connection`
### 联邦学习框架
随着用户和开发人员对联邦学习技术的需求不断增长,联邦学习工具和框架的数量也越来越多。下面将介绍一些主流的联邦学习框架。
TensorFlow联邦(TFF)是谷歌公司牵头的联邦学习开源框架,用于在分散数据上进行机器学习和其他计算。TFF的开发是为了促进联邦学习(FL)的开放研究和实验,这是一种机器学习的方法,在许多参与的客户中训练共享的全局模型,这些客户将其训练数据保存在本地。例如,联邦学习已被用于训练移动键盘的预测模型,而无需将敏感的键入数据上载到服务器。
PaddleFL是百度提出的一个基于PaddlePaddle的开源联邦学习框架。研究人员可以很轻松地用PaddleFL复制和比较不同的联邦学习算法,开发人员也比较容易在大规模分布式集群中部署PaddleFL联邦学习系统。PaddleFL提供很多种联邦学习策略(横向联邦学习、纵向联邦学习)及其在计算机视觉、自然语言处理、推荐算法等领域的应用。此外,PaddleFL还将提供传统机器学习训练策略的应用,例如多任务学习、联邦学习环境下的迁移学习。依靠着PaddlePaddle的大规模分布式训练和Kubernetes对训练任务的弹性调度能力,PaddleFL可以基于全栈开源软件轻松地部署。
FATE (Federated AI Technology Enabler) 由微众银行提出,是全球首个联邦学习工业级开源框架,可以让企业和机构在保护数据安全和数据隐私的前提下进行数据协作。 FATE项目使用多方安全计算 (MPC) 以及同态加密 (HE) 技术构建底层安全计算协议,以此支持不同种类的机器学习的安全计算,包括逻辑回归、基于树的算法、深度学习和迁移学习等。 FATE于2019年2月首次对外开源,并成立 [FATE TSC](https://github.com/FederatedAI/FATE-Community/blob/master/FATE_Project_Technical_Charter.pdf) 对FATE社区进行开源治理,成员包含国内主要云计算和金融服务企业。
FedML是一个USC牵头提出的联邦学习开源研究和基准库,它有助于开发新的联合学习算法和公平的性能比较。FedML支持三种计算范式(分布式训练、移动设备上训练和独立模拟),供用户在不同的系统环境中进行实验。FedML还通过灵活和通用的API设计和参考基线实现促进多样化的算法研究。为非I.I.D设置精心策划的全面基准数据集旨在进行公平比较。FedML在https://FedML.ai上维护源代码、文档和用户社区。
PySyft是UCL、DeepMind和OpenMind发布的安全和隐私深度学习Python库,包括联邦学习、差分隐私和多方学习。PySyft使用差分隐私和加密计算(如多方计算(MPC)和同态加密(HE))将私有数据与模型训练解耦流。
Fedlearner是字节跳动提出的协作机器学习框架,它允许对分布在机构之间的数据进行联合建模。Fedlearner附带了用于群集管理、作业管理、作业监控和网络代理的周围基础架构。Fedlearner采用云原生部署方案。数据存放在HDFS。通过Kubernetes管理和拉起任务。每个Fedlearner的训练任务需要参与双方同时拉起K8S任务,通过Master节点统一管理,Worker建实现通信。
OpenFL是英特尔提出的用于联邦学习的Python框架。OpenFL旨在成为数据科学家的灵活、可扩展和易于学习的工具。OpenFL由英特尔物联网集团(IOTG)和英特尔实验室开发。
MindSpore Fedrated是华为提出的一款开源联邦学习框架,支持千万级无状态终端设备商用化部署,在用户数据留存在本地的情况下,使能全场景智能应用。 MindSpore Federated优先专注于大规模参与方的横向联邦的应用场景,使参与联邦学习的各用户在不共享本地数据的前提下共建AI模型。MindSpore Fedrated主要解决隐私安全、大规模联邦聚合、易用性和跨平台部署等联邦学习在工业场景部署的难点。
## 概述
随着人工智能的飞速发展,大规模和高质量的数据越来越重要,但也制约了其进一步的发展。隐私、监管和工程等问题造成了设备与设备之间的数据不能共享,进而导致了数据孤岛问题的出现。为了解决这一难题,联邦学习(Federated Learning,FL)应运而生。联邦学习的概念最早在2016年被提了出来,能有效帮助多个机构在满足用户隐私保护、数据安全和政府法规的要求下,进行数据使用和机器学习建模。
### 定义
联邦学习的核心即为数据不动,模型动。显然,若是将数据从各方集中在一起,无法保证对用户隐私的保护,不符合相关法律法规。联邦学习让模型在各个数据方“移动”,这样就可以达到数据不出端即可建模的效果。在联邦学习中,各方数据都保留在本地,通过(在中心服务器上)交换加密的参数建立机器学习模型。
### 应用场景
在实际的应用场景中,根据样本和特征的重叠情况,联邦学习可以被分为横向联邦学习(样本不同,特征重叠),纵向联邦学习(特征不同,样本重叠)和联邦迁移学习(样本和特征都不重叠)。
**横向联邦学习**适用于不同参与方拥有的特征相同、但参与的个体不同的场景。比如,在广告推荐场景中,算法开发人员使用不同手机用户的相同特征(点击次数、停留时间或使用频次等)的数据来建立模型;抑或者是在输入法中用来预测由于这些特征数据不能出端,因此,横向联邦学习被用来联合多用户的数据来构建模型。
**纵向联邦学习**适用于样本重叠多、特征重叠少的场景。比如,有两个不同机构,一家是保险公司,另一家是医院。它们的用户群体很有可能包含该地的大部分居民,用户的交集可能较大。由于保险公司记录的都是用户的收支行为与信用评级,而医院则保有用户的疾病与购药记录,因此它们的用户特征交集较小。纵向联邦学习就是将这些不同特征在加密的状态下加以聚合,以增强模型能力的联邦学习。
**联邦迁移学习**的核心是找到源领域和目标领域之间的相似性。比如有两个不同机构,一家是位于中国的银行,另一家是位于美国的电商。由于受到地域限制,这两家机构的用户群体交集很小。同时,由于机构类型的不同,二者的数据特征也只有小部分重合。在这种情况下,要想进行有效的联邦学习,就必须引入迁移学习,来解决单边数据规模小和标签样本少的问题,从而提升模型的效果。
### 部署场景
联邦学习和参数服务器(数据中心分布式学习)架构非常相似,都是采用中心化的服务器和分散的客户端去构建同一个机器学习模型。此外,根据客户端来源和规模的不同,联邦学习还可以细分为跨组织(cross-silo)与跨设备(cross-device)联邦学习。一般而言,跨组织联邦学习的用户一般是企业、机构单位级别的,而跨设备联邦学习针对的则是便携式电子设备、移动端设备等。 :numref:`ch10-federated-learning-different-connection`展示了三者的区别和联系:
![数据中心分布式训练、跨组织和跨设备联邦学习的区别和联系](../img/ch10/ch10-federated-learning-different-connection.png)
:width:`800px`
:label:`ch10-federated-learning-different-connection`
### 常用框架
随着用户和开发人员对联邦学习技术的需求不断增长,联邦学习工具和框架的数量也越来越多。下面将介绍一些主流的联邦学习框架。
[TFF](https://www.tensorflow.org/federated) (TensorFlow Federated)是谷歌牵头开发的联邦学习开源框架,用于在分散数据上进行机器学习和其他计算。TFF的开发是为了促进联邦学习的开放研究和实验,这是一种机器学习的方法,在许多参与的客户中训练共享的全局模型,这些客户将其训练数据保存在本地。例如,联邦学习已被用于训练移动键盘的预测模型,而无需将敏感的键入数据上载到服务器。
[PaddleFL](https://paddlefl.readthedocs.io/en/latest/index.html)是百度提出的一个基于PaddlePaddle的开源联邦学习框架。研究人员可以很轻松地用PaddleFL复制和比较不同的联邦学习算法,开发人员也比较容易在大规模分布式集群中部署PaddleFL联邦学习系统。PaddleFL提供很多种联邦学习策略(横向联邦学习、纵向联邦学习)及其在计算机视觉、自然语言处理、推荐算法等领域的应用。此外,PaddleFL还将提供传统机器学习训练策略的应用,例如多任务学习、联邦学习环境下的迁移学习。依靠着PaddlePaddle的大规模分布式训练和Kubernetes对训练任务的弹性调度能力,PaddleFL可以基于全栈开源软件轻松地部署。
[FATE](https://fate.fedai.org) (Federated AI Technology Enabler)由微众银行提出,是全球首个联邦学习工业级开源框架,可以让企业和机构在保护数据安全和数据隐私的前提下进行数据协作。 FATE项目使用多方安全计算 (MPC) 以及同态加密 (HE) 技术构建底层安全计算协议,以此支持不同种类的机器学习的安全计算,包括逻辑回归、基于树的算法、深度学习和迁移学习等。 FATE于2019年2月首次对外开源,并成立 [FATE TSC](https://github.com/FederatedAI/FATE-Community/blob/master/FATE_Project_Technical_Charter.pdf) 对FATE社区进行开源治理,成员包含国内主要云计算和金融服务企业。
[FedML](https://FedML.ai)是一个USC牵头提出的联邦学习开源研究和基准库,它有助于开发新的联合学习算法和公平的性能比较。FedML支持三种计算范式(分布式训练、移动设备上训练和独立模拟),供用户在不同的系统环境中进行实验。FedML还通过灵活和通用的API设计和参考基线实现促进多样化的算法研究。为非I.I.D设置精心策划的全面基准数据集旨在进行公平比较。
[PySyft](https://openmined.github.io/PySyft/index.html)是UCL、DeepMind和OpenMined发布的安全和隐私深度学习Python库,包括联邦学习、差分隐私和多方学习。PySyft使用差分隐私和加密计算(如多方计算(MPC)和同态加密(HE))将私有数据与模型训练解耦流。
[Fedlearner](https://github.com/bytedance/fedlearner)是字节跳动提出的协作机器学习框架,它允许对分布在机构之间的数据进行联合建模。Fedlearner附带了用于群集管理、作业管理、作业监控和网络代理的周围基础架构。Fedlearner采用云原生部署方案。数据存放在HDFS。通过Kubernetes管理和拉起任务。每个Fedlearner的训练任务需要参与双方同时拉起K8S任务,通过Master节点统一管理,Worker建实现通信。
[OpenFL](https://openfl.readthedocs.io/en/latest/index.html)是英特尔提出的用于联邦学习的Python框架。OpenFL旨在成为数据科学家的灵活、可扩展和易于学习的工具。
[Flower](https://flower.dev)是剑桥大学、Adap等发布的联邦学习开源系统,主要针对在大规模、异质化设备上部署联邦学习算法的应用场景进行优化。
[MindSpore Fedrated](https://www.mindspore.cn/en) (昇思)是华为提出的一款开源联邦学习框架,支持千万级无状态终端设备商用化部署,在用户数据留存在本地的情况下,使能全场景智能应用。 MindSpore Federated优先专注于大规模参与方的横向联邦的应用场景,使参与联邦学习的各用户在不共享本地数据的前提下共建AI模型。MindSpore Fedrated主要解决隐私安全、大规模联邦聚合、易用性和跨平台部署等联邦学习在工业场景部署的难点。

View File

@@ -49,4 +49,87 @@ $$
从而FL-Server聚合结果$\overline{x}$为:
上面的过程只是介绍了聚合算法的主要思想,基于MPC的聚合方案是精度无损的,代价是通讯轮次的增加。
上面的过程只是介绍了聚合算法的主要思想,基于MPC的聚合方案是精度无损的,代价是通讯轮次的增加。
### 基于LDP-SignDS算法的安全聚合
对于先前的基于维度加噪的LDP算法,在隐私预算一定时,添加到每个维度的噪声规模基本上与模型参数的数量成正比。因此,对于高维模型,可能需要非常多的参与方来减轻噪音对模型收敛的影响。为了解决上述“维度依赖”问题,MindSpore Federated Learning进一步提供了基于维度选择的**Sign-based Dimension Selection (SignDS)** :cite:`jiang2022signds`算法,进一步提升模型可用性。这里,我们考虑客户端仅上传本地模型更新(即本地模型和全局模型权重差值)的场景。SignDS算法的主要思想是,对于每一条真实的本地更新$\Delta\in\mathbb{R}^{d}$,用户端首先选择一小部分更新最明显的维度构建topk集合$S_k$,并以此选择一个维度集合$J$返回给服务器。服务器根据维度集合$J$构建一条对应的稀疏更新$\Delta^\prime$,并聚合所有稀疏更新进用于更新全局模型。由于本地模型更新与本地数据信息相关联,直接选取真实的最大更新维度可能导致隐私泄露。对此,SignDS算法在两方面实现了隐私保证。一方面,算法使用了一种基于指数机制(Exponential Mechanism, EM :cite:`mcsherry2007mechanism`)的维度选择算法**EM-MDS**,使得所选维度集满足严格的$\epsilon$-LDP保证;另一方面,在构建稀疏更新时,对所选维度分配一个常量值而不直接使用实际更新值,以保证稀疏更新和本地数据不再直接关联。由于维度选择满足$\epsilon$-LDP,且分配给所选维度的更新值与本地数据无关,根据差分隐私的传递性 :cite:`dwork2014algorithmic`,所构建的稀疏更新同样满足$\epsilon$-LDP保证。**相较于之前基于维度加噪的LDP算法,SignDS算法可以显著提升高维模型的训练精度。同时,由于客户端只需上传一小部分的维度值而不是所有的模型权重,因此联邦学习的上行通信量也被大大降低。**
下面,我们分别对topk集合$S_k$的构建和EM-MDS维度选择算法进行详细介绍。
首先,由于实际更新值有正负,直接给所有选定的维度分配相同的常量值可能会明显改变模型更新方向,影响模型收敛。为了解决这个问题,SignDS提出了一种基于符号的topk集合构建策略。具体来讲,算法引入了一个额外的符号变量$s\in\\{-1,1\\}$。该变量由客户端以等概率随机采样,用于确定本地更新$\Delta$的topk集合$S_k$。如果$s=1$,我们将$\Delta$按**真实更新值**排序,并将**最大**的$k$个更新维度记为$S_k$。我们进一步从$S_k$中随机选择一部分维度,并将$s=1$作为这些维度的更新值用以构建稀疏更新。直觉上,$S_k$中维度的更新值很可能大于零。因此,将$s=1$分配给选定的维度不会导致模型更新方向的太大差异,从而减轻了对模型精度的影响。类似的,当$s=-1$时,我们选取**最小**的$k$个更新维度记为$S_k$,并将$s=-1$分配给所选维度。
下面,我们进一步介绍用于维度选择的EM-MDS算法。简单来说,EM-MDS算法的目的是从输出维度域$\mathcal{J}$中以一定概率$\mathcal{P}$随机选择一个维度集合$J\in\mathcal{J}$,不同维度集合对应的概率不同。我们假设$J$总共包含$h$个维度,其中有$\nu$个维度属于topk集合(即$|S_k \cap J|=\nu$,且$\nu\in[0,h]$),另外$h-\nu$个维度属于非topk集合。直观上,$\nu$越大,$J$中包含的topk维度越多,模型收敛越好。因此,我们希望给$\nu$较大的维度集合分配更高的概率。基于这个想法,我们将评分函数定义为:
$$
u(S_{k}, J) = 𝟙(|S_k\cap J| \geq \nu_{th}) = 𝟙(\nu \geq \nu_{th})
$$
:eqlabel:`score_function`
$u(S_{k}, J)$用来衡量输出维度集合$J$中包含的topk维度的数量是否超过某一阈值$\nu_{th}$($\nu_{th}\in[1,h]$),超过则为1,否则为0。进一步,$u(S_{k}, J)$的敏感度可计算为:
$$
\phi = \max_{J\in\mathcal{J}} ||u(S_{k}, J) - u(S^\prime_{k}, J)||= 1 - 0 = 1
$$
:eqlabel:`sensitivity`
注意 :eqref:`sensitivity`对于任意一对不同的topk集合$S_k$和$S_k^\prime$均成立。
根据以上定义,EM-MDS算法描述如下:
*给定真实本地更新$\Delta\in\mathbb{R}^{d}$的topk集合$S_k$和隐私预算$\epsilon$,输出维度集合$J\in\mathcal{J}$的采样概率为:*
$$
\mathcal{P}=\frac{\mathrm{exp}(\frac{\epsilon}{\phi}\cdot u(S_{k}, J))}{\sum_{J^\prime\in\mathcal{J}}\mathrm{exp}(\frac{\epsilon}{\phi}\cdot u(S_{k}, J^\prime))}
=
\frac{\mathrm{exp}(\epsilon\cdot 𝟙(\nu \geq \nu_{th}))}{\sum_{\tau=0}^{\tau=h}\omega_{\tau}\cdot \mathrm{exp}(\epsilon\cdot 𝟙(\tau\geq\nu_{th}))}
=
\frac{\mathrm{exp}(\epsilon\cdot 𝟙(\nu \geq \nu_{th}))}{\sum_{\tau=0}^{\tau=\nu_{th}-1}\omega_{\tau} + \sum_{\tau=\nu_{th}}^{\tau=h}\omega_{\tau}\cdot \mathrm{exp}(\epsilon)}
$$
:eqlabel:`emmds`
*其中,$\nu$是$J$中包含的topk维度数量,$\nu_{th}$是评分函数的阈值,$J^\prime$是任意一输出维度集合,$\omega_{\tau}=\binom{k}{\tau}\binom{d-k}{h-\tau}$是所有包含$\tau$个topk维度的集合数。*
我们进一步提供了EM-MDS算法的隐私证明:
*对于每个客户端,给定随机采样的符号值$x$,任意两个本地更新$\Delta$,$\Delta^\prime$的topk集合记为$S_k$和$S_k^\prime$,对于任意输出维度集合$J\in\mathcal{J}$,令$\nu=|S_k \cap J|$, $\nu^\prime=|S_k^\prime \cap J|$为$J$与两组topk维度集的交集数量。根据 :eqref:`emmds`,以下不等式成立:*
$$
\frac{\mathrm{Pr}\[J|\Delta\]}{\mathrm{Pr}\[J|\Delta^\prime\]} = \frac{\mathrm{Pr}\[J|S_{k}\]}{\mathrm{Pr}\[J|S^\prime_{k}\]} = \frac{\frac{\mathrm{exp}(\frac{\epsilon}{\phi}\cdot u(S_{k}, J))}{\sum_{J^\prime\in\mathcal{J}}\mathrm{exp}(\frac{\epsilon}{\phi}\cdot u(S_{k}, J^\prime))}}{\frac{\mathrm{exp}(\frac{\epsilon}{\phi}\cdot u(S^\prime_{k}, J))}{\sum_{J^\prime\in\mathcal{J}}\mathrm{exp}(\frac{\epsilon}{\phi}\cdot u(S^\prime_{k}, J^\prime))}}
= \frac{\frac{\mathrm{exp}(\epsilon\cdot 𝟙(\nu \geq \nu_{th}))}{\sum_{\tau=0}^{\tau=h}\omega_{\tau}\cdot \mathrm{exp}(\epsilon\cdot 𝟙(\tau\geq\nu_{th}))}}{\frac{
\mathrm{exp}(\epsilon\cdot 𝟙(\nu^\prime \geq \nu_{th}))}{\sum_{\tau=0}^{\tau=h}\omega_{\tau}\cdot \mathrm{exp}(\epsilon\cdot 𝟙(\tau\geq\nu_{th}))}} \\
= \frac{\mathrm{exp}(\epsilon\cdot 𝟙(\nu \geq \nu_{th}))}{
\mathrm{exp}(\epsilon\cdot 𝟙(\nu^\prime \geq \nu_{th}))}
\leq \frac{\mathrm{exp}(\epsilon\cdot 1)}{\mathrm{exp}(\epsilon\cdot 0)} = \mathrm{exp}(\epsilon)
$$
*证明EM-MDS算法满足$\epsilon$-LDP保证。*
值得注意的是,计算 :eqref:`emmds`需要先确定topk维度数的阈值$\nu_{th}$。为此,我们首先推导在给定阈值$\nu_{th}$时,任意一组输出维度集合$J$包含的topk维度的概率分布和期望:
$$
\mathrm{Pr}(\nu=\tau|\nu_{th})=
\begin{cases}
\omega_{\tau} / \Omega \quad \quad \quad \quad \quad \mathrm{ } &if \quad \tau\in\[0,\nu_{th}\) \\
\omega_{\tau}\cdot\mathrm{exp}(\epsilon) / \Omega \quad \quad &if \quad \tau\in\[\nu_{th},h\]
\end{cases}
$$
:eqlabel:`discrete-prob`
$$
\mathbb{E}\[\nu|\nu_{th}\] = \sum_{\tau=0}^{\tau=h}\tau\cdot \mathrm{Pr}(\nu=\tau|\nu_{th})
$$
:eqlabel:`expectation`
这里,$\Omega$为 :eqref:`emmds`中$\mathcal{P}$的分母部分。直觉上,$\mathbb{E}\[\nu|\nu_{th}\]$越高,随机采样的$J$集合中包含的topk维度的概率就越大,从而模型效用就越好。因此,我们将$\mathbb{E}\[\nu|\nu_{th}\]$最高时的阈值确定为目标阈值$\nu_{th}^{\*}$,即:
$$
\nu_{th}^{\*} = \underset{\nu_{th}\in\[1, h\]}{\operatorname{argmax}} \mathbb{E}\[\nu|\nu_{th}\]
$$
:eqlabel:`threshold`
最后,我们在 :numref:`signds_workflow`中描述了SignDS算法的详细流程。给定本地模型更新$\Delta$,我们首先随机采样一个符号值$s$并构建topk集合$S_k$。接下来,我们根据 :eqref:`threshold`确定阈值$\nu_{th}^{\*}$并遵循 :eqref:`emmds`定义的概率选择输出集合$J$。考虑到输出域$\mathcal{J}$包含$\binom{d}{k}$个可能的维度集合,以一定概率直接从$\mathcal{J}$中随机采样一个组合需要很大的计算成本和空间成本。因此,我们采用了逆采样算法以提升计算效率。具体来说,我们首先从标准均匀分布中采样一个随机值$\beta\sim U(0,1)$,并根据 :eqref:`discrete-prob`中$p(\nu=\tau|\nu_{th})$的累计概率分布$CDF_{\tau}$确定输出维度集合中包含的topk维度数$\nu$。最后,我们从topk集合$S_k$中随机选取$\nu$个维度,从非topk集合中随机采样$h-\nu$个维度,以构建最终的输出维度集合$J$。
![SignDS工作流程](../img/ch10/ch10-federated-learning-signds.PNG)
:width:`800px`
:label:`signds_workflow`

View File

@@ -10,8 +10,8 @@
引入中间表示后,中间表示既能面向多个前端,表达多种源程序语言,又能对接多个后端,连接不同目标机器,如 :numref:`intermediate_representation`所示。在此基础上,编译流程就可以在前后端直接增加更多的优化流程,这些优化流程以现有IR为输入,又以新生成的IR为输出,被称为优化器。优化器负责分析并改进中间表示,极大程度的提高了编译流程的可拓展性,也降低了优化流程对前端和后端的破坏。
![中间表示](../img/ch04/中间表示-中间表示结构.svg)
:width:`800px`
![中间表示](../img/ch04/中间表示-中间表示结构.png)
:width:`850px`
:label:`intermediate_representation`
随着编译器技术的不断演进,中间表示主要经历了三个发展阶段。在早期阶段,中间表示是封闭在编译器内部的,供编译器编写者使用。在中期阶段,随着编译器的开源,中间表示逐步开源公开,主要供编译器设计者、分析工具设计者使用。现阶段,中间表示朝着软件生态构建的方向发展,旨在构建统一的中间表示。
@@ -30,14 +30,14 @@
: 中间表示的分类
:::
1\) 线性中间表示
1\) 线性中间表示/Users/liangzhibo/Desktop/中间表示-中间表示结构.png
线性中间表示类似抽象机的汇编代码,将被编译代码表示为操作的有序序列,对操作序列规定了一种清晰且实用的顺序。由于大多数处理器采用线性的汇编语言,线性中间表示广泛应用于编译器设计。
常用线性中间表示有堆栈机代码(Stack-Machine Code)和三地址代码(Three
Address Code) :cite:`2007Compilers` 。堆栈机代码是一种单地址代码,提供了简单紧凑的表示。堆栈机代码的指令通常只有一个操作码,其操作数存在一个栈中。大多数操作指令从栈获得操作数,并将其结果推入栈中。三地址代码,简称为3AC,模拟了现代RISC机器的指令格式。它通过一组四元组实现,每个四元组包括一个运算符和三个地址(两个操作数、一个目标)。对于表达式a-b\*5,堆栈机代码和三地址代码如 :numref:`linear_ir`所示。
![堆栈机代码和三地址代码](../img/ch04/中间表示-线性中间表示.svg)
![堆栈机代码和三地址代码](../img/ch04/中间表示-线性中间表示.png)
:width:`800px`
:label:`linear_ir`
@@ -50,7 +50,7 @@ Graph,DAG)、控制流图(Control-Flow Graph,CFG)等。
AST抽象语法树采用树型中间表示的形式,是一种接近源代码层次的表示。对于表达式$a*5+a*5*b$,其AST表示如 :numref:`AST_DAG`所示。可以看到,AST形式包含$a*5$的两个不同副本,存在冗余。在AST的基础上,DAG提供了简化的表达形式,一个节点可以有多个父节点,相同子树可以重用。如果编译器能够证明$a$的值没有改变,则DAG可以重用子树,降低求值过程的代价。
![AST图和DAG图](../img/ch04/中间表示-ASTDAG.svg)
:width:`600px`
:width:`400px`
:label:`AST_DAG`
3、混合中间表示
@@ -61,8 +61,8 @@ IR使用线性中间表示表示基本块,使用图中间表示表示这些块
Single Assignment, SSA) :cite:`Richard1995A`
形式呈现,这些指令构成一个指令线性列表。SSA形式要求每个变量只赋值一次,并且每个变量在使用之前定义。控制流图中,每个节点为一个基本块,基本块之间通过边实现控制转移。
![LLVM IR](../img/ch04/中间表示-LLVMIR.svg)
:width:`600px`
![LLVM IR](../img/ch04/中间表示-LLVMIR.png)
:width:`800px`
:label:`LLVM_IR`
### 机器学习框架的中间表示
@@ -99,12 +99,36 @@ IR作为PyTorch模型的中间表示,通过JIT即时编译的形式,将Pytho
PyTorch框架采用命令式编程方式,其TorchScript
IR以基于SSA的线性IR为基本组成形式,并通过JIT即时编译的Tracing和Scripting两种方法将Python代码转换成TorchScript
IR。如 :numref:`TorchScript_IR`给出了Python示例代码及其TorchScript
IR。
IR。如下Python代码使用了Scripting方法并打印其对应的中间表示图:
```python
import torch
![Python代码及输出的TorchScript IR](../img/ch04/中间表示-torchscript.png)
:width:`800px`
:label:`TorchScript_IR`
@torch.jit.script
def test_func(input):
rv = 10.0
for i in range(5):
rv = rv + input
rv = rv/2
return rv
print(test_func.graph)
```
该中间表示图的结构为:
```
graph(%input.1 : Tensor):
%9 : int = prim::Constant[value=1]()
%5 : bool = prim::Constant[value=1]() # test.py:6:1
%rv.1 : float = prim::Constant[value=10.]() # test.py:5:6
%2 : int = prim::Constant[value=5]() # test.py:6:16
%14 : int = prim::Constant[value=2]() # test.py:8:10
%rv : float = prim::Loop(%2, %5, %rv.1) # test.py:6:1
block0(%i : int, %rv.9 : float):
%rv.3 : Tensor = aten::add(%input.1, %rv.9, %9) # <string>:5:9
%12 : float = aten::FloatImplicit(%rv.3) # test.py:7:2
%rv.6 : float = aten::div(%12, %14) # test.py:8:7
-> (%5, %rv.6)
return (%rv)
```
TorchScript是PyTorch的JIT实现,支持使用Python训练模型,然后通过JIT转换为语言无关的模块,从而提升模型部署能力,提高编译性能。同时,TorchScript
@@ -116,12 +140,38 @@ Jax机器学习框架同时支持静态图和动态图,其中间表示采用Ja
Representation) IR。Jaxpr
IR是一种强类型、纯函数的中间表示,其输入、输出都带有类型信息,函数输出只依赖输入,不依赖全局变量。
![ANF文法与Jaxpr IR](../img/ch04/中间表示-Jaxpr.png)
:width:`800px`
:label:`Jaxpr`
Jaxpr IR的表达采用ANF(A-norm
Form)函数式表达形式,如 :numref:`Jaxpr`所示。ANF形式将表达式划分为两类:原子表达式(aexp)和复合表达式(cexp)。原子表达式用于表示常数、变量、原语、匿名函数,复合表达式由多个原子表达式组成,可看作一个匿名函数或原语函数调用,组合的第一个输入是调用的函数,其余输入是调用的参数。
Form)函数式表达形式,ANF文法如下所示:
```
<aexp> ::= NUMBER | STRING | VAR | BOOLEAN | PRIMOP
| (lambda (VAR ...) <exp>)
<cexp> ::= (<aexp> <aexp> ...)
| (if <aexp> <exp> <exp>)
<exp> ::= (let ([VAR <cexp>]) <exp>) | <cexp> | <aexp>
```
ANF形式将表达式划分为两类:原子表达式(aexp)和复合表达式(cexp)。原子表达式用于表示常数、变量、原语、匿名函数,复合表达式由多个原子表达式组成,可看作一个匿名函数或原语函数调用,组合的第一个输入是调用的函数,其余输入是调用的参数。如下代码打印了一个函数对应的JaxPr:
```python
from jax import make_jaxpr
import jax.numpy as jnp
def test_func(x, y):
ret = x + jnp.sin(y) * 3
return jnp.sum(ret)
print(make_jaxpr(test_func)(jnp.zeros(8), jnp.ones(8)))
```
其对应的JaxPr为:
```
{ lambda ; a:f32[8] b:f32[8]. let
c:f32[8] = sin b
d:f32[8] = mul c 3.0
e:f32[8] = add a d
f:f32[] = reduce_sum[axes=(0,)] e
in (f,) }
```
Jax框架结合了Autograd 和 JIT,基于Jaxpr
IR,支持循环、分支、递归、闭包函数求导以及三阶求导,并且支持自动微分的反向传播和前向传播。
@@ -132,8 +182,8 @@ TensorFlow框架同时支持静态图和动态图,是一个基于数据流编
为了适配不同的硬件平台,基于静态计算图,TensorFlow采用了多种IR设计,其编译生态系统如 :numref:`TFIR`所示。蓝色部分是基于图的中间表示,绿色部分是基于SSA的中间表示。在中间表示的转换过程中,各个层级的中间表示各自为政,无法互相有效地沟通信息,也不清楚其他层级的中间表示做了哪些优化,因此每个中间表示只能尽力将当前的优化做到最好,造成了很多优化在每个层级的中间表示中重复进行, 从而导致优化效率的低下。尤其是从图中间表示到SSA中间表示的变化过大,转换开销极大。此外,各个层级的相同优化的代码无法复用,也降低了开发效率。
![TensorFlow](../img/ch04/中间表示-MLIR.svg)
:width:`600px`
![TensorFlow](../img/ch04/中间表示-MLIR.png)
:width:`1000px`
:label:`TFIR`
4、MLIR
@@ -178,17 +228,38 @@ typed)。每个节点需要有一个具体的类型,这个对于性能最大
在结合MindSpore框架的自身特点后,MindIR的定义如 :numref:`MindIR`所示。
![MindIR文法。MindIR中的ANode对应于ANF的原子表达式,ValueNode用于表示常数值,ParameterNode用于表示函数的形参,CNode则对应于ANF的复合表达式,表示函数调用](../img/ch04/中间表示-MindIR.svg)
:width:`800px`
![MindIR文法。MindIR中的ANode对应于ANF的原子表达式,ValueNode用于表示常数值,ParameterNode用于表示函数的形参,CNode则对应于ANF的复合表达式,表示函数调用](../img/ch04/中间表示-MindIR.png)
:width:`1100px`
:label:`MindIR`
接下来我们通过 :numref:`MindIR_example`中的一段程序作为示例,来进一步分析MindIR。
接下来我们通过如下的一段程序作为示例,来进一步分析MindIR。
![MindIR的ANF表达](../img/ch04/中间表示-MindIR示例.png)
:width:`600px`
:label:`MindIR_example`
```python
def func(x, y):
return x / y
在ANF中,每个表达式都用let表达式绑定为一个变量,通过对变量的引用来表示对表达式输出的依赖,而在MindIR中,每个表达式都绑定为一个节点,通过节点与节点之间的有向边表示依赖关系。其函数图表示如 :numref:`MindIR_graph`所示。
@ms_function
def test_f(x, y):
a = x - 1
b = a + y
c = b * func(a, b)
return c
```
该函数对应的ANF表达式为:
```
lambda (x, y)
let a = x - 1 in
let b = a + y in
let func = lambda (x, y)
let ret = x / y in
ret end in
let %1 = func(a, b) in
let c = b * %1 in
c end
```
在ANF中,每个表达式都用let表达式绑定为一个变量,通过对变量的引用来表示对表达式输出的依赖,而在MindIR中,每个表达式都绑定为一个节点,通过节点与节点之间的有向边表示依赖关系。该函数对应的MindIR的可视化表示如 :numref:`MindIR_graph`所示。
![MindIR的函数图表示](../img/ch04/中间表示-MindIR图.png)
:width:`800px`

View File

@@ -1,11 +1,10 @@
总结
----
## 总结
- 中间表示是编译器的核心数据结构之一,是程序编译过程中介于源语言和目标语言之间的程序表示。
- 传统编译器的中间表示从组织结构出发,可以分为线性中间表示,图中间表示以及混合中间表示。
- 机器学习框架的中间对中间表示有一系列新的需求,这些新的需求是传统中间表示所不能完美支持的。因此需要在传统中间表示的基础上扩展新的,更适用于机器学习框架的中间表示。
- 机器学习框架对中间表示有一系列新的需求,这些新的需求是传统中间表示所不能完美支持的。因此需要在传统中间表示的基础上扩展新的,更适用于机器学习框架的中间表示。
- 自动微分的基本思想是将计算机程序中的运算操作分解为一个有限的基本操作集合,且集合中基本操作的求导规则均为已知,在完成每一个基本操作的求导后,使用链式法则将结果组合得到整体程序的求导结果。
@@ -20,3 +19,12 @@
- 静态分析,是指在不实际运行程序的情况下,通过词法分析、语法分析、控制流、数据流分析等技术对代码进行分析验证的技术
- 编译优化意在解决编译生成的中间表示的低效性,前端执行的均为与硬件无关的编译优化。
## 扩展阅读
- 一种基于图的中间表示类型: [综述](https://dl.acm.org/doi/10.1145/202530.202534)
- 机器学习框架中的自动微分: [综述](https://arxiv.org/abs/1502.05767)
- 函数式框架中的反向自动微分: [综述](https://dl.acm.org/doi/10.1145/1330017.1330018)

View File

@@ -125,46 +125,34 @@ ARMv8系列的CPU上有32个NEON寄存器v0-v31,如 :numref:`ch08-fig-register
以一维卷积运算为例,记为F(m,r),其中,m代表输出的个数,r为卷积核的个数。输入为$d=[d_0 \ d_1 \ d_2 \ d_3]$,卷积核为$g=[g_0 \ g_1 \ g_2]^T$,该卷积计算可以写成矩阵形式如公式 :eqref:`ch08-equ-conv_matmul_one_dimension`所示,需要6次乘法和4次加法。
$$F(2, 3)=
\left[ \begin{matrix} d_0 & d_1 & d_2 \\ d_1 & d_2 & d_3 \end{matrix} \right] \left[ \begin{matrix} g_0 \\ g_1 \\ g_2 \end{matrix} \right]=
\left[ \begin{matrix} y_0 \\ y_1 \end{matrix} \right]$$
$$F(2, 3)=\left[ \begin{matrix} d_0 & d_1 & d_2 \\ d_1 & d_2 & d_3 \end{matrix} \right] \left[ \begin{matrix} g_0 \\ g_1 \\ g_2 \end{matrix} \right]=\left[ \begin{matrix} y_0 \\ y_1 \end{matrix} \right]$$
:eqlabel:`ch08-equ-conv_matmul_one_dimension`
可以观察到,卷积运算转换为矩阵乘法时输入矩阵中存在着重复元素$d_1$和$d_2$,因此,卷积转换的矩阵乘法相对一般的矩阵乘有了优化空间。可以通过计算中间变量$m_0-m_3$得到矩阵乘的结果,见公式 :eqref:`ch08-equ-conv-2-winograd`:
$$F(2, 3)=
\left[ \begin{matrix} d_0 & d_1 & d_2 \\ d_1 & d_2 & d_3 \end{matrix} \right] \left[ \begin{matrix} g_0 \\ g_1 \\ g_2 \end{matrix} \right]=
\left[ \begin{matrix} m_0+m_1+m_2 \\ m_1-m_2+m_3 \end{matrix} \right]$$
$$F(2, 3)=\left[ \begin{matrix} d_0 & d_1 & d_2 \\ d_1 & d_2 & d_3 \end{matrix} \right] \left[ \begin{matrix} g_0 \\ g_1 \\ g_2 \end{matrix} \right]=\left[ \begin{matrix} m_0+m_1+m_2 \\ m_1-m_2+m_3 \end{matrix} \right]$$
:eqlabel:`ch08-equ-conv-2-winograd`
其中,$m_0-m_3$的分别见公式 :eqref:`ch08-equ-winograd-param`:
$$\begin{aligned}
m_0=(d_0-d_2)*g_0 \\
m_1=(d_1+d_2)*(\frac{g_0+g_1+g_2}{2}) \\
m_2=(d_0-d_2)*(\frac{g_0-g_1+g_2}{2}) \\
m_2=(d_1-d_3)*g_2
\end{aligned}$$
$$\begin{aligned}m_0=(d_0-d_2)*g_0 \\m_1=(d_1+d_2)*(\frac{g_0+g_1+g_2}{2}) \\m_2=(d_0-d_2)*(\frac{g_0-g_1+g_2}{2}) \\m_2=(d_1-d_3)*g_2\end{aligned}$$
:eqlabel:`ch08-equ-winograd-param`
通过$m_0-m_3$间接计算r1,r2,需要的运算次数包括:输入d的4次加法;输出m的4次乘法和4次加法。在推理阶段,权重的数值是常量,因此卷积核上的运算可以在图编译阶段计算,不计入在线的run时间。所以总的运算次数为4次乘法和8次加法,与直接运算的6次乘法和4次加法相比,乘法次数减少,加法次数增加。在计算机中,乘法一般比加法慢,通过减少乘法次数,增加少量加法,可以实现加速。
计算过程写成矩阵形式如公式 :eqref:`ch08-equ-winograd-matrix`所示,其中,⊙为对应位置相乘,A、B、G都是常量矩阵。这里写成矩阵计算是为了表达清晰,实际使用时,按照公式 :eqref:`ch08-equ-winograd-param`手写展开的计算速度更快。
$$\mathbf{Y}=\mathbf{A^T}(\mathbf{G}g)*(\mathbf{B^T}d)$$
:eqlabel:`ch08-equ-winograd-matrix`
$$\mathbf{B^T}=
\left[ \begin{matrix} 1 & 0 & -1 & 0 \\ 0 & 1 & 1 & 0 \\ 0 & -1 & 1 & 0 \\ 0 & 1 & 0 & -1 \end{matrix} \right]$$
$$\mathbf{B^T}=\left[ \begin{matrix} 1 & 0 & -1 & 0 \\ 0 & 1 & 1 & 0 \\ 0 & -1 & 1 & 0 \\ 0 & 1 & 0 & -1 \end{matrix} \right]$$
:eqlabel:`ch08-equ-winograd-matrix-bt`
$$\mathbf{G}=
\left[ \begin{matrix} 1 & 0 & 0 \\ 0.5 & 0.5 & 0.5 \\ 0.5 & -0.5 & 0.5 \\ 0 & 0 & 1 \end{matrix} \right]$$
$$\mathbf{G}=\left[ \begin{matrix} 1 & 0 & 0 \\ 0.5 & 0.5 & 0.5 \\ 0.5 & -0.5 & 0.5 \\ 0 & 0 & 1 \end{matrix} \right]$$
:eqlabel:`ch08-equ-winograd-matrix-g`
$$\mathbf{A^T}=
\left[ \begin{matrix} 1 & 1 & -1 & 0 \\ 0 & 1 & -1 & -1 \end{matrix} \right] \\$$
$$\mathbf{A^T}=\left[ \begin{matrix} 1 & 1 & -1 & 0 \\ 0 & 1 & -1 & -1 \end{matrix} \right] \\$$
:eqlabel:`ch08-equ-winograd-matrix-at`

View File

@@ -11,3 +11,11 @@
- 针对模型的推理功耗,主要的优化思路是降低模型的计算量,这与针对模型推理时延的优化手段有重合之处,可以参考离线的模型优化技术 :numref:`ch08-sec-fusion`和模型压缩技术 :numref:`ch08-sec-model_compression`。
- 本章除了介绍优化模型部署的各方面指标的优化技术以外,还介绍了安全部署相关的技术,如模型混淆、模型加密等。部署安全一方面可以保护企业的重要资产,另一方面可以防止黑客通过篡改模型从而入侵攻击部署环境。
## 扩展阅读
- Google量化白皮书 [量化](https://arxiv.org/abs/1806.08342)
- 诺亚高精度剪枝算法 [剪枝](https://arxiv.org/abs/2010.10732)
- 针对多核处理器的自动图并行调度框架 [性能优化](https://proceedings.mlsys.org/paper/2021/file/a5e00132373a7031000fd987a3c9f87b-Paper.pdf)

View File

@@ -2,7 +2,7 @@
现代机器学习框架包含大量的组件。这些组件使得用户得以高效开发机器学习算法,处理数据,部署模型,性能调优和使用硬件加速器。在设计这些组件的编程接口时,一个核心的诉求是:如何平衡框架性能和易用性?为了达到最优的性能,开发者需要利用硬件亲和的编程语言如:C和C++来进行开发。这是因为:C和C++的使用使得机器学习框架可以高效调用硬件的底层API,从而最大限度发挥硬件性能。同时,现代操作系统(如Linux和Windows)提供丰富的基于C和C++的编程接口(如文件系统,网络编程,多线程管理等),通过直接调用操作系统API,可以降低框架运行的开销。
从易用性的角度分析,机器学习框架的使用者往往具有丰富的行业背景(如数据科学家,生物学家,化学家,物理学家等)。他们的常用的编程语言是高层次脚本语言:Python,Matlab,R和Julia。相比于C和C++,这些语言在提供编程的易用性的同时,丧失了C和C++对底层硬件和操作系统进行深度优化的能力。因此,机器学习框架的核心设计目标是:其要具有易用编程接口来支持用户用高层次语言如Python来实现机器学习算法,同时其也要具备以C和C++为核心的低层次编程接口,使得框架开发者可以用C和C++实现大量高性能组件,从而在硬件上高效执行。在本章中,我们将会讲述如何达到这个设计目标。
从易用性的角度分析,机器学习框架的使用者往往具有丰富的行业背景(如数据科学家,生物学家,化学家,物理学家等)。他们常用的编程语言是高层次脚本语言:Python,Matlab,R和Julia。相比于C和C++,这些语言在提供编程的易用性的同时,丧失了C和C++对底层硬件和操作系统进行深度优化的能力。因此,机器学习框架的核心设计目标是:其要具有易用编程接口来支持用户用高层次语言如Python来实现机器学习算法,同时其也要具备以C和C++为核心的低层次编程接口,使得框架开发者可以用C和C++实现大量高性能组件,从而在硬件上高效执行。在本章中,我们将会讲述如何达到这个设计目标。
本章的学习目标包括:

View File

@@ -19,7 +19,7 @@
- **测试和调试:**
训练过程中,用户需要测试API来对当前模型的精度进行评估。当精度达到目标后,训练结束。这一过程中,用户往往需要调试API来完成对模型的性能和正确性进行验证。
![机器学习系统工作流](../img/ch02/workflow.svg)
![机器学习系统工作流](../img/ch02/img_workflow.svg)
:width:`800px`
:label:`img_workflow`

View File

@@ -19,3 +19,8 @@
- Python和C之间的互操作性一般通过CType等技术实现。
- 机器学习框架一般具有多种C和C++接口允许用户定义和注册C++实现的算子。这些算子使得用户可以开发高性能模型,数据处理函数,优化器等一系列框架拓展。
## 扩展阅读
- MindSpore编程指南:[MindSpore](https://www.mindspore.cn/docs/programming_guide/zh-CN/r1.6/index.html)
- Python和C/C++混合编程:[Pybind11](https://pybind11.readthedocs.io/en/latest/basics.html#creating-bindings-for-a-simple-function)

View File

@@ -5,7 +5,7 @@
### 推荐模型
基于深度学习的推荐模型在过去几年受到了学术界和工业界的高度关注,得到了快速发展。目前主流的推荐模型 :cite:`10.1145/2988450.2988454,10.1145/3124749.3124754,ijcai2017-239,naumov2019deep`的基本结构可以总结如图 :numref:`ch10-recommendation-models`。
![推荐模型的基本结构](../img/ch10/ch10-recommendation-models.svg)
![推荐模型的基本结构](../img/ch10/ch10-recommendation-models.png)
:width:`800px`
:label:`ch10-recommendation-models`
@@ -25,7 +25,7 @@ Wide & Deep模型对输入数据进行两部分处理:Wide部分和Deep部分
在实际的生产环境中,除了推荐模型本身,推荐系统通常包括:数据收集、数据处理、数据存储、模型训练、模型存储、模型评估、推理服务等多个子系统。如图 :numref:`ch10-abstract-recommendation-systems`所示,这些子系统之间分工协作、紧密配合,构成一个从用户反馈、到模型更新、再到新推荐结果生成的闭环。下一小节中将以英伟达(NVIDIA)公司的Merlin开源框架 :cite:`Merlin`为例,概括介绍推荐系统流水线上的组件,并重点介绍模型训练、推理子系统的结构。
![推荐系统的基本组件](../img/ch10/ch10-abstract-recommendation-systems.svg)
![推荐系统的基本组件](../img/ch10/ch10-abstract-recommendation-systems.png)
:width:`800px`
:label:`ch10-abstract-recommendation-systems`

View File

@@ -1,3 +1,15 @@
## 小结
推荐系统作为深度学习在工业界最成功的落地成果之一,极大地提升了用户的在线服务体验,并且为各大公司创造了可观的利润,然而也带来了许多系统层面的挑战亟待解决。本节简单介绍了典型的工业界推荐系统架构及其面临的挑战,并给出了潜在的解决方案的方向。在实际生产环境中,具体的系统设计方案根据不同推荐场景的需求而变化,不存在一种万能的解决方案。
推荐系统作为深度学习在工业界最成功的落地成果之一,极大地提升了用户的在线服务体验,并且为各大公司创造了可观的利润,然而也带来了许多系统层面的挑战亟待解决。本节简单介绍了典型的工业界推荐系统架构及其面临的挑战,并给出了潜在的解决方案的方向。在实际生产环境中,具体的系统设计方案需要根据不同推荐场景的需求而变化,不存在一种万能的解决方案。
## 扩展阅读
- 推荐模型:[Wide & Deep](https://arxiv.org/abs/1606.07792)
- 开源推荐系统框架:[Merlin](https://irsworkshop.github.io/2020/publications/paper_21_Oldridge_Merlin.pdf)
- 软硬件协同设计加速超大规模深度学习推荐系统训练:[ZionEX](https://arxiv.org/abs/2104.05158v5)
- 利用多级缓存支持超大规模深度学习推荐系统训练:[Distributed Hierarchical GPU Parameter Server for Massive Scale Deep Learning Ads Systems](https://arxiv.org/abs/2003.05622)
- 工业界机器学习系统的实践:[Hidden Technical Debt in Machine Learning Systems](https://papers.nips.cc/paper/2015/hash/86df7dcfd896fcaf2674f757a2463eba-Abstract.html)

View File

@@ -13,7 +13,7 @@ Merlin是英伟达公司开发的一个开源推荐系统框架,帮助使用
在工业界,为了提升系统在发生故障的情况下的可用性,以上介绍的各个组件在实际中部署中都应该具备基本的容灾和故障恢复能力。以推理服务为例,在线服务中的深度学习推荐模型通常都采用多副本分布式部署。同一个模型的多个副本通常会被部署在至少两个不同的地理区域内的多个数据中心中,如 :numref:`ch10-recommendation-systems`,以应对大面积停电或者网络中断而导致整个地区的所有副本都不可用。除了容错方面的考虑,部署多个副本还有其他几点优势。首先,将模型部署在靠近用户的云服务器上可以提升响应速度。其次,部署多份副本也可以拓展模型推理服务的吞吐率。
![推荐系统的分布式架构](../img/ch10/ch10-recommendation-systems.svg)
![推荐系统的分布式架构](../img/ch10/ch10-recommendation-systems.png)
:width:`800px`
:label:`ch10-recommendation-systems`

22
chapter_rl_sys/control.md Normal file
View File

@@ -0,0 +1,22 @@
## 控制系统
虽然控制理论已牢牢植根于基于模型(Model-based)的设计传统,但丰富的数据和机器学习给控制理论带来了新的机遇。控制理论和机器学习的交叉点涵盖了广泛的研究方向,包括但不限于动态系统的学习、在线学习和控制、深度学习的控制理论观点、强化学习以及在各种现实世界系统中的应用。
从机器学习的角度来看,未来的主要挑战之一是超越模式识别并解决数据驱动控制和动态过程优化方面的问题。
理论方面,线性二次控制(Linear-Quadratic
Control)是经典的控制方法,最近有关于图神经网络在分布式线性二次控制的研究 :cite:`pmlr-v144-gama21a`。作者称将线性二次问题转换为自监督学习问题,能够找到基于图神经网络(Graph
Neural
Networks,GNN)的最佳分布式控制器,他们还推导出了所得闭环系统稳定的充分条件。随着基于数据和学习的机器人控制方法不断得到重视,研究人员必须了解何时以及如何在现实世界中最好地利用这些方法,因为安全是至关重要的,有的研究通过学习不确定的动力学来安全地提高性能,鼓励安全或稳健的强化学习方法,以及可以正式认证所学控制策略的安全性的方法 :cite:`brunke2021safe`。图:numref:`safe\_learning\_control`展示了安全学习控制(Safe Learning
Control)系统的框架图,用数据驱动的方法来学习控制策略,兼顾安全性。Lyapunov :cite:`pmlr-v144-mehrjou21a`
函数是评估非线性动力系统稳定性的有效工具,最近有人提出Neural
Lyapunov来将安全性纳入考虑。
应用方面,有基于神经网络的自动驾驶汽车模型预测控制 :cite:`vianna2021neural`,也有研究将最优控制和学习相结合并应用在陌生环境中的视觉导航 :cite:`pmlr-v100-bansal20a`,该研究将基于模型的控制与基于学习的感知相结合来解决。基于学习的感知模块产生一系列航路点通过无碰撞路径引导机器人到达目标。基于模型的规划器使用这些航路点来生成平滑且动态可行的轨迹,该轨迹使用反馈控制在物理系统上执行。在模拟的现实世界杂乱环境和实际地面车辆上的实验表明,与纯粹基于几何映射或基于端到端学习的替代方案相比,这种新的系统可以在新环境中更可靠、更有效地到达目标位置。强化学习和模仿学习与控制论有密切联系:LEOC :cite:`pmlr-v144-zhang21b`整合了强化学习和经典控制理论的原则方法。有人将基于模型的离线强化学习算法扩展到高维视觉观察空间并在真实机器人上执行基于图像的抽屉关闭任务方面表现出色 :cite:`pmlr-v144-rafailov21a`。控制部分通过神经网络优化可以更加平滑、节能、安全,如何将
神经网络和传统控制理论结合,特别是和运动学算法相结合,将会是一个有趣的方向。
![安全学习控制系统,数据被用来更新控制策略或或安全滤波器 :cite:`brunke2021safe`](../img/ch13/safe_learning_control.png)
:width:`800px`
:label:`safe\_learning\_control`

20
chapter_rl_sys/index.md Normal file
View File

@@ -0,0 +1,20 @@
# 机器人学习系统
在本章中,我们介绍机器学习的一个重要分支——机器人学习及其在系统方面的知识。本章的学习目标包括:
- 掌握机器人学习基本知识。
- 掌握通用机器人操作系统。
- 掌握感知系统、规划系统、控制系统。
```toc
:maxdepth: 2
rl_sys_intro
ros
perception
planning
control
summary
```

View File

@@ -0,0 +1,23 @@
## 感知系统
感知系统不仅可以包括视觉,还可以包含触觉、声音等。在未知环境中,机器人想实现自主移动和导航必须知道自己在哪(例如通过相机重定位 :cite:`ding2019camnet`),周围什么情况(例如通过3D物体检测 :cite:`yi2020segvoxelnet`或语义分割),这些要依靠感知系统来实现 :cite:`xu2019depth`:cite:`xu2020selfvoxelo`:cite:`xu2022rnnpose`:cite:`xu2022robust`:cite:`yang2021pdnet`:cite:`huang2021vs`:cite:`huang2021life:cite:`:cite:`huang2019prior`:cite:`zhu2020ssn`。
一提到感知系统,不得不提的就是即时定位与建图(Simultaneous Localization
and
Mapping,SLAM)系统。SLAM大致过程包括地标提取、数据关联、状态估计、状态更新以及地标更新等。视觉里程计Visual
Odometry是SLAM中的重要部分,它估计两个时刻机器人的相对运动(Ego-motion)。ORB-SLAM :cite:`campos2021orb`系列是视觉SLAM中有代表性的工作,图 :numref:`orbslam3` 展示了最新的ORB-SLAM3的主要系统组件。香港科技大学开源的基于单目视觉与惯导融合的SLAM技术VINS-Mono :cite:`8421746`也很值得关注。多传感器融合、优化数据关联与回环检测、与前端异构处理器集成、提升鲁棒性和重定位精度都是SLAM技术接下来的发展方向。
最近,随着机器学习的兴起,基于学习的SLAM框架也被提了出来。TartanVO :cite:`tartanvo2020corl`是第一个基于学习的视觉里程计(VO)模型,该模型可以推广到多个数据集和现实世界场景,并优于传统基于几何的方法。
UnDeepVO :cite:`li2018undeepvo`是一个无监督深度学习方案,能够通过使用深度神经网络估计单目相机的
6-DoF 位姿及其视图深度。DROID-SLAM :cite:`teed2021droid`是用于单目、立体和
RGB-D 相机的深度视觉 SLAM,它通过Bundle
Adjustment层对相机位姿和像素深度的反复迭代更新,具有很强的鲁棒性,故障大大减少,尽管对单目视频进行了训练,但它可以利用立体声或
RGB-D 视频在测试时提高性能。其中,Bundle Adjustment
(BA)与机器学习的结合被广泛研究 :cite:`tang2018ba`:cite:`tanaka2021learning`。CMU提出通过主动神经
SLAM
的模块化系统帮助智能机器人在未知环境中的高效探索 :cite:`chaplot2020learning`。
![ORB-SLAM3主要系统组件 :cite:`campos2021orb`](../img/ch13/orbslam3.png)
:width:`800px`
:label:`orbslam3`

View File

@@ -0,0 +1,14 @@
## 规划系统
规划不仅包含运动路径规划,还包含高级任务规划 :cite:`9712373`。其中,运动规划是机器人技术的核心问题之一,应用范围从导航到复杂环境中的操作。它具有悠久的研究历史,方法需要有概率完整性和最优性的保证。然而,当经典运动规划在处理现实世界的机器人问题(在高维空间中)时,挑战仍然存在。研究人员在继续开发新算法来克服与这些方法相关的限制,包括优化计算和内存负载、更好的规划表示和处理维度灾难等。
相比之下,机器学习的最新进展为机器人专家研究运动规划问题开辟了新视角:经典运动规划器的瓶颈可以以数据驱动的方式解决;基于深度学习的规划器可以避免几何输入的局限性,例如使用视觉或语义输入进行规划等。最近的工作有:基于深度神经网络的四足机器人快速运动规划框架 :cite:`jangdeep`,通过贝叶斯学习进行运动规划 :cite:`quintero2021motion`,通过运动规划器指导的视觉运动策略学习 :cite:`kadubandimotion`。ML4KP :cite:`ML4KP`是一个用于有效运动动力学运动规划的C++库,该库可以轻松地将机器学习方法集成到规划过程中。
自动驾驶领域和行人和车辆轨迹预测 :cite:`qiu2021egocentric`方面也涌现出使用机器学习解决运动规划的工作,比如斯坦福大学提出Trajectron++ :cite:`salzmann2020trajectron++`。强化学习在规划系统上也有重要应用 :cite:`aradi2020survey`:cite:`sun2021adversarial`,比如基于MetaDrive模拟器 :cite:`li2021metadrive`,最近有一些关于多智能体强化学习,多智能体车流模拟、驾驶行为分析 :cite:`peng2021learning`,考虑安全性因素的强化学习 :cite:`peng2021safe`,以及拓展到由真人专家在旁边监督,出现危险的时候接管的专家参与的强化学习工作(Online
Imitation Learning、Offline
RL):cite:`li2021efficient`,样本效率极高,是单纯强化学习算法的50倍。为了更好地说明强化学习是如何应用在自动驾驶中的,图 :numref:`rl\_ad`展示了一个基于深度强化学习的自动驾驶POMDP模型。
![基于深度强化学习的自动驾驶POMDP模型 :cite:`aradi2020survey`](../img/ch13/rl_ad.png)
:width:`800px`
:label:`rl\_ad`

View File

@@ -0,0 +1,30 @@
## 概述
机器人学是一个交叉学科,它涉及了计算机科学、机械工程、电气工程、生物医学工程、数学等多种学科,并有诸多应用,比如自动驾驶汽车、机械臂、无人机、医疗机器人等。机器人能够自主地完成一种或多种任务或者辅助人类完成指定任务。通常,人们把机器人系统划分为感知系统、决策(规划)和控制系统等组成部分 :cite:`buehler2009darpa`。
近些年,随着机器学习的兴起,经典机器人技术出现和机器学习技术结合的趋势,称为机器人学习(Robot
Learning):cite:`peters2016robot`。机器人学习包含了计算机视觉、自然语言处理、语音处理、强化学习和模仿学习等人工智能技术在机器人上的应用,让机器人通过学习,自主地执行各种决策控制任务。
机器人学习系统(Robot Learning
System)是一个较新的概念。作为系统和机器人学习的交叉方向,仿照机器学习系统的概念,我们把机器人学习系统定义为"支持机器人模型训练和部署的系统"。按照涉及的机器人数量,可以划分为单机器人学习系统和多机器人学习系统。多机器人学习系统协作和沟通中涉及的安全和隐私问题,也会是一个值得研究的方向。最近机器人学习系统在室内自主移动 :cite:`zhu2017target`:cite:`pmlr-v100-bansal20a`:cite:`9123682`:cite:`huang2018navigationnet`,道路自动驾驶 :cite:`pmlr-v155-huang21a`:cite:`pmlr-v155-sun21a`:cite:`Sun2022SelfSupervisedTA`,机械臂工业操作 :cite:`tobin2017domain`:cite:`finn2017deep`:cite:`chen2020transferable`:cite:`duan2017one`等行业场景得到充分应用和发展。一些机器人学习基础设施项目也在进行中,如具备从公开可用的互联网资源、计算机模拟和
真实机器人试验中学习能力的大规模的计算系统RobotBrain :cite:`saxena2014robobrain`。在自动驾驶领域,受联网的自动驾驶汽车
(CAV) 对传统交通运输行业的影响,"车辆计算"(Vehicle Computing) :cite:`9491826`
(如图:numref:`vehicle-computing`)概念引起广泛关注,并激发了如何让计算能力有限使用周围的CAV计算平台来执行复杂的计算任务的研究。最近,有很多自动驾驶系统的模拟器,代表性的比如CARLA :cite:`Dosovitskiy17`,支持安全RL、MARL、真实地图数据导入、泛化性测试等任务的MetaDrive :cite:`li2021metadrive`,还有CarSim和
TruckSim :cite:`benekohal1988carsim`,它们可以作为各种自动驾驶算法的训练场并对算法效果进行评估。另外针对自动驾驶的系统开发平台也不断涌现,如ERDOS,
D3 (Dynamic
Deadline-Driven) :cite:`10.1145/3492321.3519576`和强调模块化思想的Pylot :cite:`gog2021pylot`,可以让模型训练与部署系统与这些平台对接。
![车辆计算框架图 :cite:`9491826`](../img/ch13/vehicle_computing.png)
:width:`800px`
:label:`vehicle\_computing`
图 :numref:`learning\_decision\_module`是一个典型的感知、规划、控制的模块化设计的自动驾驶系统框架图,接下来,我们也将按照这个顺序依次介绍通用框架、感知系统、规划系统和控制系统。
![通过模仿学习进行自动驾驶框架图。
绿线表示自主驾驶系统的模块化流程。橙色实线表示神经判别器的训练。而橙色虚线表示规划和控制模块是不可微的。但是决策策略可以通过判别器对控制行动的奖励,重新参数化技术进行训练,如蓝色虚线所示 :cite:`pmlr-v155-huang21a`。](../img/ch13/idm.png)
:width:`800px`
:label:`learning\_decision\_module`

106
chapter_rl_sys/ros.md Normal file
View File

@@ -0,0 +1,106 @@
## 通用机器人操作系统
![ROS/ROS2架构概述 :cite:`maruyama2016exploring`](../img/ch13/ROS2_arch.png)
:width:`800px`
:label:`ROS2\_arch`
机器人操作系统(ROS) :cite:`quigley2009ros,maruyama2016exploring,koubaa2017robot`起源于斯坦福大学人工智能实验室的一个机器人项目。它是一个自由、开源的框架,提供接口、工具来构建先进的机器人。由于机器人领域的快速发展和复杂化,代码复用和模块化的需求日益强烈,ROS适用于机器人这种多节点多任务的复杂场景。目前也有一些机器人、无人机甚至无人车都开始采用ROS作为开发平台。在机器人学习方面,ROS/ROS2可以与深度学习结合,有开发人员为ROS/ROS2开发了的深度学习节点,并支持NVIDIA
Jetson和TensorRT。NVIDIA
Jetson是NVIDIA为自主机器开发的一个嵌入式系统,包括CPU、GPU、PMIC、DRAM
和闪存的一个模组化系统,可以将自主机器软件运作系统运行速率提升。TensorRT
是由 Nvidia 发布的机器学习框架,用于在其硬件上运行机器学习推理。
作为一个适用于机器人编程的框架,ROS把原本松散的零部件耦合在了一起,为他们提供了通信架构。虽然叫做"操作系统",ROS更像是一个中间件,给各种基于ROS的应用程序建立起了沟通的桥梁,通过这个中间件,机器人的感知、决策、控制算法可以组织和运行。ROS采用了分布式的设计思想,支持C++、Pyhton等多种编程语言,方便移植。对ROS来讲,最小的进程单元是节点,由节点管理器来管理。参数配置存储在参数服务器中。ROS的通信方式包含:主题(Topic)、服务(Service)、参数服务器(Parameter
Server)、动作库(ActionLib)这四种。
ROS提供了很多内置工具,比如三维可视化器rviz,用于可视化机器人、它们工作的环境和传感器数据。它是一个高度可配置的工具,具有许多不同类型的可视化和插件。catkin是ROS
构建系统(类似于Linux下的CMake),Catkin
Workspace是创建、修改、编译catkin软件包的目录。roslaunch可用于在本地和远程启动多个ROS
节点以及在ROS参数服务器上设置参数的工具。此外还有机器人仿真工具Gazebo和移动操作软件和规划框架MoveIt! :cite:`coleman2014reducing`。ROS为机器人开发者提供了不同编程语言的接口,比如C++语言ROS接口roscpp,python语言的ROS接口rospy。ROS中提供了许多机器人的统一机器人描述格式URDF(Unified
Robot Description
Format)文件,URDF使用XML格式描述机器人文件。ROS也有一些需要提高的地方,比如它的通信实时性能有限,与工业级要求的系统稳定性还有一定差距。
ROS2 :cite:`maruyama2016exploring`项目在ROSCon 2014上被宣布,第一个ROS2发行版
Ardent Apalone
是于2017年发布。ROS2增加了对多机器人系统的支持,提高了多机器人之间通信的网络性能,而且支持微控制器和跨系统平台,不仅可以运行在现有的X86和ARM系统上,还将支持MCU等嵌入式微控制器,不止能运行在Linux系统之上,还增加了对Windows、MacOS、RTOS等系统的支持。更重要的是,ROS
2还加入了实时控制的支持,可以提高控制的时效性和整体机器人的性能。ROS
2的通信系统基于DDS(Data Distribution
Service),即数据分发服务,如图:numref:`ROS2\_arch`所示。
ROS2依赖于使用shell环境组合工作区。"工作区"(Workspace)是一个ROS术语,表示使用ROS2进行开发的系统位置。核心ROS2
工作区称为Underlay。随后的工作区称为Overlays。使用ROS2
进行开发时,通常会同时有多个工作区处于活动状态。接下来我们详细介绍一下ROS2的核心概念(这一部分我们参考了文献 [^1])。
### ROS2 Nodes
ROS
Graph是一个由ROS2元素组成的网络,在同一时间一起处理数据。它包括所有的可执行文件和它们之间的联系。ROS2
中的每个节点都应负责一个单一的模块用途(例如,一个节点用于控制车轮马达,一个节点用于控制激光测距仪等)。每个节点都可以通过主题、服务、动作或参数向其他节点发送和接收数据。一个完整的机器人系统由许多协同工作的节点组成。在
ROS 2 中,单个可执行文件(C++ 程序、Python
程序等)可以包含一个或多个节点,如图:numref:`ros2\_graph`。
![一个完整的机器人系统由许多协同工作的节点组成。在ROS 2
中,单个可执行文件(C++ 程序、Python
程序等)可以包含一个或多个节点](../img/ch13/ros2_graph.png)
:width:`800px`
:label:`ros2\_graph`
节点之间的互相发现是通过ROS2底层的中间件实现的。 过程总结如下
- 当一个节点启动后, 它会向其他拥有相同ROS域名(ROS domain,
可以通过设置ROS\_DOMAIN\_ID环境变量来设
置)的节点进行广播,说明它已经上线。
其他节点在收到广播后返回自己的相关信息,这样节点间的连接就可以建
立了,之后就可以通信了。
- 节点会定时广播它的信息,这样即使它已经错过了最初的发现过程,它也可以和新上线的节点进行连接。
- 节点在下线前它也会广播其他节点自己要下线了。
### ROS2 Topics
ROS2将复杂系统分解为许多模块化节点。主题(Topics)是 ROS
Graph的重要元素,它充当节点交换消息的总线。一个节点可以向任意数量的主题发布数据,同时订阅任意数量的主题,如图:numref:`ros2\_topics`所示。主题是数据在节点之间以及因此在系统的不同部分之间移动的主要方式之一。
rqt是ROS的一个软件框架,以插件的形式实现了各种 GUI 工具。可以在 rqt
中将所有现有的GUI工具作为可停靠窗口运行!这些工具仍然可以以传统的独立方法运行,但rqt可以更轻松地同时管理屏幕上的所有各种窗口。
![一个节点可以向任意数量的主题发布数据,同时订阅任意数量的主题](../img/ch13/ros2_topics.png)
:width:`800px`
:label:`ros2\_topics`
### ROS 2 Services
服务(Services)是 ROS
图中节点的另一种通信方式。服务基于调用和响应模型,而不是主题的发布者-订阅者模型。虽然主题允许节点订阅数据流并获得持续更新,但服务仅在客户端专门调用它们时才提供数据。节点可以使用ROS2中的服务进行通信。与主题那种单向通信模式,节点发布可由一个或多个订阅者使用的信息的方式不同
服务是客户端向节点发出请求的请求/响应模式提供服务,服务处理请求并生成响应。
![ROS2服务](../img/ch13/ros2_services.png)
:width:`800px`
:label:`ros2\_services`
### ROS 2 Parameters
参数(Parameters)是节点的配置值。您可以将参数视为节点设置。节点可以将参数存储为整数、浮点数、布尔值、字符串和列表。在ROS2
中,每个节点都维护自己的参数。
### ROS 2 Actions
动作(Actions)是ROS2中的一种通信类型,适用于长时间运行的任务。它们由三个部分组成:目标、反馈和结果。动作建立在主题和服务之上。它们的功能类似于服务,除了可以取消动作。它们还提供稳定的反馈,而不是返回单一响应的服务。动作使用客户端-服务器模型,类似于发布者-订阅者模型(在主题教程中描述)。"动作客户端"节点将目标发送到"动作服务器"节点,该节点确认目标并返回反馈流和结果。动作类似于允许您执行长时间运行的任务、提供定期反馈并且可以取消的服务。机器人系统可能会使用动作进行导航。动作目标可以告诉机器人前往某个位置。当机器人导航到该位置时,它可以沿途发送更新(即反馈),然后在到达目的地后发送最终结果消息。
![ROS2动作](../img/ch13/ros2_actions.png)
:width:`800px`
:label:`ros2\_actions`
[^1]: https://docs.ros.org/en/foxy/Tutorials/Understanding-ROS2-Nodes.html

View File

@@ -0,0 +1,3 @@
## 小结
在这一章,我们简单介绍了机器人学习系统的基本概念,包括通用机器人操作系统、感知系统、规划系统和控制系统等,给读者对机器人学习问题的基本认识。当前,机器人学习是一个快速发展的人工智能分支,许多实际问题都有可能通过机器人学习算法的进一步发展得到解决。另一方面,由于机器人学习问题设置的特殊性,也使得相应系统与相关硬件的耦合程度更高、更复杂:如何更好地平衡各种传感器负载?如何在计算资源有限的情况下最大化计算效率(实时性)?等等,都需要对计算机系统的设计和使用有更好的理解。

View File

@@ -77,7 +77,7 @@ header_links = GitHub, https://github.com/openmlsys/openmlsys-zh, fab fa-github,
favicon = static/favicon.png
# html_logo = static/logo-with-text.png
html_logo = static/logo-with-text.png
[pdf]

172
img/ch02/img_workflow.svg Normal file

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 34 KiB

View File

@@ -1,168 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
version="1.1"
id="svg2"
xml:space="preserve"
width="1251.4545"
height="158.8"
viewBox="0 0 1251.4545 158.8"
sodipodi:docname="workflow.svg"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs6"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath18"><path
d="M 0,0 H 939.9273 V 120 H 0 Z"
id="path16" /></clipPath></defs><sodipodi:namedview
id="namedview4"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
showgrid="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:zoom="0.99494688"
inkscape:cx="963.36801"
inkscape:cy="-127.64501"
inkscape:window-width="1920"
inkscape:window-height="1137"
inkscape:window-x="1912"
inkscape:window-y="-8"
inkscape:window-maximized="1"
inkscape:current-layer="g22" /><g
id="g8"
inkscape:groupmode="layer"
inkscape:label="workflow"
transform="matrix(1.3333333,0,0,-1.3333333,-1.2545919,159.3272)"><g
id="g10" /><g
id="g22"><g
id="g26"
transform="matrix(7.874016e-5,0,0,-7.874016e-5,1.690944,118.7454)"><path
d="M 0,0 H 1648690 V 1493520 H 0 Z"
style="fill:none;stroke:#000000;stroke-width:19050;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:8;stroke-dasharray:none;stroke-opacity:1"
id="path28" /></g><g
id="g30"
transform="matrix(0.2181818,0,0,0.2181818,30.4146,-65.45454)"><text
transform="matrix(1,0,0,-1,0,550)"
style="font-variant:normal;font-weight:normal;font-size:83px;font-family:STSongti-SC;-inkscape-font-specification:STSongti-SC-Regular;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text34"><tspan
x="0 82.501991 165.00398 247.50597"
y="0"
sodipodi:role="line"
id="tspan32">数据处理</tspan></text></g><g
id="g38"
transform="matrix(7.874016e-5,0,0,-7.874016e-5,203.5091,118.7454)"><path
d="M 0,0 H 1645920 V 1493520 H 0 Z"
style="fill:none;stroke:#000000;stroke-width:19050;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:8;stroke-dasharray:none;stroke-opacity:1"
id="path40" /></g><g
id="g42"
transform="matrix(0.2181818,0,0,0.2181818,232.2039,-65.45454)"><text
transform="matrix(1,0,0,-1,0,550)"
style="font-variant:normal;font-weight:normal;font-size:83px;font-family:STSongti-SC;-inkscape-font-specification:STSongti-SC-Regular;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text46"><tspan
x="0 82.501991 165.00398 247.50597"
y="0"
sodipodi:role="line"
id="tspan44">模型结构</tspan></text></g><g
id="g50"
transform="matrix(7.874016e-5,0,0,-7.874016e-5,607.3636,118.7454)"><path
d="M 0,0 H 1648691 V 1493520 H 0 Z"
style="fill:none;stroke:#000000;stroke-width:19050;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:8;stroke-dasharray:none;stroke-opacity:1"
id="path52" /></g><g
id="g54"
transform="matrix(0.2181818,0,0,0.2181818,636.1186,-65.45454)"><text
transform="matrix(1,0,0,-1,0,550)"
style="font-variant:normal;font-weight:normal;font-size:83px;font-family:STSongti-SC;-inkscape-font-specification:STSongti-SC-Regular;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text58"><tspan
x="0 82.501991"
y="0"
sodipodi:role="line"
id="tspan56">训练</tspan></text></g><g
id="g60"
transform="matrix(0.2181818,0,0,0.2181818,672.1186,-65.45454)"><text
transform="matrix(1,0,0,-1,0,550)"
style="font-variant:normal;font-weight:normal;font-size:83px;font-family:STSongti-SC;-inkscape-font-specification:STSongti-SC-Regular;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text64"><tspan
x="0 82.501991"
y="0"
sodipodi:role="line"
id="tspan62">过程</tspan></text></g><path
d="m 142.4182,68.72725 h 33.7091 v 8.78181 L 193.6909,59.94544 176.1273,42.38182 v 8.78181 h -33.7091 z"
style="fill:#deebf7;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path66" /><g
id="g68"
transform="matrix(7.874016e-5,0,0,-7.874016e-5,142.4182,77.50906)"><path
d="M 0,111529 H 428106.1 V 0 L 651164,223058 428106.1,446116 V 334587 H 0 Z"
style="fill:none;stroke:#000000;stroke-width:19050;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:8;stroke-dasharray:none;stroke-opacity:1"
id="path70" /></g><path
d="m 545.8364,68.72726 h 33.491 v 8.7818 L 596.8909,59.94541 579.3274,42.38182 v 8.78179 h -33.491 z"
style="fill:#deebf7;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path72" /><g
id="g74"
transform="matrix(7.874016e-5,0,0,-7.874016e-5,545.8364,77.50906)"><path
d="M 0,111528.8 H 425335.6 V 0 L 648393,223058.3 425335.6,446116 V 334587.2 H 0 Z"
style="fill:none;stroke:#000000;stroke-width:19050;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:8;stroke-dasharray:none;stroke-opacity:1"
id="path76" /></g><path
d="m 342.9272,68.72726 h 33.491 v 8.7818 L 393.9818,59.94541 376.4182,42.38182 v 8.78179 h -33.491 z"
style="fill:#deebf7;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path78" /><g
id="g80"
transform="matrix(7.874016e-5,0,0,-7.874016e-5,342.9272,77.50906)"><path
d="M 0,111528.8 H 425335.6 V 0 L 648393,223058.3 425335.6,446116 V 334587.2 H 0 Z"
style="fill:none;stroke:#000000;stroke-width:19050;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:8;stroke-dasharray:none;stroke-opacity:1"
id="path82" /></g><g
id="g86"
transform="matrix(7.874016e-5,0,0,-7.874016e-5,405.1091,118.7454)"><path
d="M 0,0 H 1648691 V 1493520 H 0 Z"
style="fill:none;stroke:#000000;stroke-width:19050;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:8;stroke-dasharray:none;stroke-opacity:1"
id="path88" /></g><g
id="g90"
transform="matrix(0.2181818,0,0,0.2181818,415.9932,-54.76363)"><text
transform="matrix(1,0,0,-1,0,550)"
style="font-variant:normal;font-weight:normal;font-size:83px;font-family:STSongti-SC;-inkscape-font-specification:STSongti-SC-Regular;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text94"><tspan
x="0 82.501991 165.00398 247.50597 330.00797 412.50995"
y="0"
sodipodi:role="line"
id="tspan92">损失函数和优</tspan></text></g><g
id="g96"
transform="matrix(0.2181818,0,0,0.2181818,442.9932,-76.36363)"><text
transform="matrix(1,0,0,-1,0,550)"
style="font-variant:normal;font-weight:normal;font-size:83px;font-family:STSongti-SC;-inkscape-font-specification:STSongti-SC-Regular;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text100"><tspan
x="0 82.501991 165.00398"
y="0"
sodipodi:role="line"
id="tspan98">化算法</tspan></text></g><g
id="g104"
transform="matrix(7.874016e-5,0,0,-7.874016e-5,808.9636,118.7454)"><path
d="M 0,0 H 1648691 V 1493520 H 0 Z"
style="fill:none;stroke:#000000;stroke-width:19050;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:8;stroke-dasharray:none;stroke-opacity:1"
id="path106" /></g><g
id="g108"
transform="matrix(0.2181818,0,0,0.2181818,828.8295,-65.45454)"><text
transform="matrix(1,0,0,-1,0,550)"
style="font-variant:normal;font-weight:normal;font-size:83px;font-family:STSongti-SC;-inkscape-font-specification:STSongti-SC-Regular;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text112"><tspan
x="0 82.501991 165.00398 247.50597 330.00797"
y="0"
sodipodi:role="line"
id="tspan110">测试和调试</tspan></text></g><path
d="m 747.4364,72.05453 h 33.8181 v 8.72729 L 798.709,63.32729 781.2545,45.87276 V 54.6 h -33.8181 z"
style="fill:#deebf7;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path114" /><g
id="g116"
transform="matrix(7.874016e-5,0,0,-7.874016e-5,747.4364,80.78182)"><path
d="M 0,110836.6 H 429490.6 V 0 L 651163,221672.5 429490.6,443345 V 332509.1 H 0 Z"
style="fill:none;stroke:#000000;stroke-width:19050;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:8;stroke-dasharray:none;stroke-opacity:1"
id="path118" /></g></g></g></svg>

Before

Width:  |  Height:  |  Size: 9.3 KiB

View File

@@ -3,79 +3,74 @@
<svg
version="1.1"
id="svg9"
id="svg2"
xml:space="preserve"
width="1269.72"
height="277.57623"
viewBox="0 0 1269.72 277.57623"
sodipodi:docname="ast.svg"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
width="1205.1733"
height="196.77014"
viewBox="0 0 1205.1733 196.77014"
sodipodi:docname="ch04-graph_23.svg"
inkscape:version="1.1.2 (b8e25be833, 2022-02-05)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs13"><clipPath
id="defs6"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath23"><path
id="clipPath16"><path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path21" /></clipPath><clipPath
id="path14" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath35"><path
id="clipPath30"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path33" /></clipPath><clipPath
id="path28" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath49"><path
id="clipPath42"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path47" /></clipPath><clipPath
id="path40" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath61"><path
id="clipPath58"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path59" /></clipPath><clipPath
id="path56" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath75"><path
id="clipPath76"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path73" /></clipPath><clipPath
id="path74" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath87"><path
id="clipPath88"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path85" /></clipPath><clipPath
id="path86" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath103"><path
id="clipPath104"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path101" /></clipPath><clipPath
id="path102" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath115"><path
id="clipPath116"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path113" /></clipPath><clipPath
id="path114" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath129"><path
id="clipPath134"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path127" /></clipPath><clipPath
id="path132" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath143"><path
id="clipPath150"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path141" /></clipPath><clipPath
id="path148" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath155"><path
id="clipPath166"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path153" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath185"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path183" /></clipPath></defs><sodipodi:namedview
id="namedview11"
id="path164" /></clipPath></defs><sodipodi:namedview
id="namedview4"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
@@ -87,172 +82,168 @@
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:zoom="1.321875"
inkscape:cx="636.21749"
inkscape:cy="138.06147"
inkscape:zoom="0.88014498"
inkscape:cx="611.83102"
inkscape:cy="96.574998"
inkscape:window-width="2560"
inkscape:window-height="1361"
inkscape:window-x="-9"
inkscape:window-y="-9"
inkscape:window-height="1377"
inkscape:window-x="-8"
inkscape:window-y="-8"
inkscape:window-maximized="1"
inkscape:current-layer="g15" /><g
id="g15"
inkscape:current-layer="g8" /><g
id="g8"
inkscape:groupmode="layer"
inkscape:label="ast"
transform="matrix(1.3333333,0,0,-1.3333333,-3.8599999,498.70537)"><path
d="m 4.02,282.28 c 0,4.78 3.8773,8.66 8.66,8.66 H 147.4 c 4.78,0 8.66,-3.88 8.66,-8.66 v -34.64 c 0,-4.78 -3.88,-8.66 -8.66,-8.66 H 12.68 c -4.7827,0 -8.66,3.88 -8.66,8.66 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path27" /><g
id="g29"><g
id="g31"
clip-path="url(#clipPath35)"><text
transform="matrix(1,0,0,-1,19.992,256.3)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text39"><tspan
x="0 24 48 72 96"
y="0"
sodipodi:role="line"
id="tspan37">动态图代码</tspan></text></g></g><path
d="m 204.54,345.94 c 0,6.08 4.92,11 11,11 h 130.04 c 6.08,0 11,-4.92 11,-11 v -44 c 0,-6.08 -4.92,-11 -11,-11 H 215.54 c -6.08,0 -11,4.92 -11,11 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path41" /><g
id="g43"><g
id="g45"
clip-path="url(#clipPath49)"><text
transform="matrix(1,0,0,-1,256.49,329.74)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text53"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan51">分词</tspan></text></g></g><g
id="g55"><g
id="g57"
clip-path="url(#clipPath61)"><text
transform="matrix(1,0,0,-1,232.49,300.94)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text65"><tspan
x="0 24 48 72"
y="0"
sodipodi:role="line"
id="tspan63">词法分析</tspan></text></g></g><path
d="m 201.3,237.94 c 0,6.08 4.92,11 11,11 h 130.04 c 6.08,0 11,-4.92 11,-11 v -44 c 0,-6.08 -4.92,-11 -11,-11 H 212.3 c -6.08,0 -11,4.92 -11,11 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path67" /><g
id="g69"><g
id="g71"
clip-path="url(#clipPath75)"><text
transform="matrix(1,0,0,-1,253.25,221.64)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text79"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan77">解析</tspan></text></g></g><g
id="g81"><g
id="g83"
clip-path="url(#clipPath87)"><text
transform="matrix(1,0,0,-1,229.25,192.84)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text91"><tspan
x="0 24 48 72"
y="0"
sodipodi:role="line"
id="tspan89">语法分析</tspan></text></g></g><g
id="g93"><path
d="m 188.1,342.74 c 0,16.66 13.5,30.16 30.16,30.16 H 338.9 c 16.66,0 30.16,-13.5 30.16,-30.16 v -145.6 c 0,-16.66 -13.5,-30.16 -30.16,-30.16 H 218.26 c -16.66,0 -30.16,13.5 -30.16,30.16 z"
inkscape:label="ch04-graph_23"
transform="matrix(1.3333333,0,0,-1.3333333,-7.1733332,458.70611)"><g
id="g20"><path
d="m 188.1,318.68 c 0,13.38 10.84,24.22 24.22,24.22 h 132.52 c 13.38,0 24.22,-10.84 24.22,-24.22 V 221.8 c 0,-13.38 -10.84,-24.22 -24.22,-24.22 H 212.32 c -13.38,0 -24.22,10.84 -24.22,24.22 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:6.75, 2.25;stroke-dashoffset:0;stroke-opacity:1"
id="path95" /></g><g
id="g97"><g
id="g99"
clip-path="url(#clipPath103)"><text
transform="matrix(1,0,0,-1,396.07,316.25)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text107"><tspan
x="0 24"
id="path22" /></g><g
id="g24"><g
id="g26"
clip-path="url(#clipPath30)"><text
transform="matrix(1,0,0,-1,402.5,305.93)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text34"><tspan
x="0 18"
y="0"
sodipodi:role="line"
id="tspan105">抽象</tspan></text></g></g><g
id="g109"><g
id="g111"
clip-path="url(#clipPath115)"><text
transform="matrix(1,0,0,-1,384.07,287.45)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text119"><tspan
x="0 24 48"
id="tspan32">抽象</tspan></text></g></g><g
id="g36"><g
id="g38"
clip-path="url(#clipPath42)"><text
transform="matrix(1,0,0,-1,393.5,284.33)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text46"><tspan
x="0 18 36"
y="0"
sodipodi:role="line"
id="tspan117">语法树</tspan></text></g></g><path
d="m 472.26,286.9 c 0,6.08 4.92,11 11,11 H 613.3 c 6.08,0 11,-4.92 11,-11 v -44 c 0,-6.08 -4.92,-11 -11,-11 H 483.26 c -6.08,0 -11,4.92 -11,11 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path121" /><g
id="g123"><g
id="g125"
clip-path="url(#clipPath129)"><text
transform="matrix(1,0,0,-1,488.28,256.3)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text133"><tspan
x="0 24 48 72 96"
id="tspan44">语法树</tspan></text></g></g><path
d="m 5.88,289.43 c 0,1.33 1.0789,2.41 2.4097,2.41 H 155.39 c 1.33,0 2.41,-1.08 2.41,-2.41 v -38.02 c 0,-1.33 -1.08,-2.41 -2.41,-2.41 H 8.2897 C 6.9589,249 5.88,250.08 5.88,251.41 Z"
style="fill:#dae3f3;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path48" /><path
d="m 5.88,289.43 c 0,1.33 1.0789,2.41 2.4097,2.41 H 155.39 c 1.33,0 2.41,-1.08 2.41,-2.41 v -38.02 c 0,-1.33 -1.08,-2.41 -2.41,-2.41 H 8.2897 C 6.9589,249 5.88,250.08 5.88,251.41 Z"
style="fill:none;stroke:#404040;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path50" /><g
id="g52"><g
id="g54"
clip-path="url(#clipPath58)"><text
transform="matrix(1,0,0,-1,36.768,264.38)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text62"><tspan
x="0 18 36 54 72"
y="0"
sodipodi:role="line"
id="tspan131">语法树转写</tspan></text></g></g><path
d="m 675.06,286.9 c 0,6.08 4.92,11 11,11 h 83 c 6.08,0 11,-4.92 11,-11 v -44 c 0,-6.08 -4.92,-11 -11,-11 h -83 c -6.08,0 -11,4.92 -11,11 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path135" /><g
id="g137"><g
id="g139"
clip-path="url(#clipPath143)"><text
transform="matrix(1,0,0,-1,691.54,270.7)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text147"><tspan
x="0 24 48"
id="tspan60">动态图代码</tspan></text></g></g><path
d="m 157.87,271.17 25.25,-0.21 -0.02,-1.5 -25.25,0.21 z m 24.26,2.05 5.98,-3.05 -6.02,-2.95 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path64" /><path
d="m 202.56,319.91 c 0,1.33 1.08,2.41 2.41,2.41 h 147.1 c 1.33,0 2.41,-1.08 2.41,-2.41 v -38.02 c 0,-1.33 -1.08,-2.41 -2.41,-2.41 h -147.1 c -1.33,0 -2.41,1.08 -2.41,2.41 z"
style="fill:#dae3f3;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path66" /><path
d="m 202.56,319.91 c 0,1.33 1.08,2.41 2.41,2.41 h 147.1 c 1.33,0 2.41,-1.08 2.41,-2.41 v -38.02 c 0,-1.33 -1.08,-2.41 -2.41,-2.41 h -147.1 c -1.33,0 -2.41,1.08 -2.41,2.41 z"
style="fill:none;stroke:#404040;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path68" /><g
id="g70"><g
id="g72"
clip-path="url(#clipPath76)"><text
transform="matrix(1,0,0,-1,260.54,305.69)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text80"><tspan
x="0 18"
y="0"
sodipodi:role="line"
id="tspan145">静态图</tspan></text></g></g><g
id="g149"><g
id="g151"
clip-path="url(#clipPath155)"><text
transform="matrix(1,0,0,-1,703.54,241.9)"
style="font-variant:normal;font-weight:normal;font-size:24.024px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text159"><tspan
x="0 24"
id="tspan78">分词</tspan></text></g></g><g
id="g82"><g
id="g84"
clip-path="url(#clipPath88)"><text
transform="matrix(1,0,0,-1,242.52,284.09)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text92"><tspan
x="0 18 36 54"
y="0"
sodipodi:role="line"
id="tspan157">代码</tspan></text></g></g><path
d="m 156,271.29 h 19.5 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 H 156 Z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path161" /><path
d="m 156,271.29 h 19.5 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 H 156 Z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path163" /><path
d="m 369.24,274.29 h 88.98 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -88.98 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path165" /><path
d="m 369.24,274.29 h 88.98 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -88.98 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path167" /><path
d="m 624.24,271.29 h 37.02 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -37.02 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path169" /><path
d="m 624.24,271.29 h 37.02 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -37.02 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path171" /><path
d="m 779.4,271.29 h 36.9 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -36.9 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path173" /><path
d="m 779.4,271.29 h 36.9 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -36.9 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path175" /><path
d="m 830.82,286.9 c 0,6.08 4.92,11 11,11 h 101.24 c 6.08,0 11,-4.92 11,-11 v -44 c 0,-6.08 -4.92,-11 -11,-11 H 841.82 c -6.08,0 -11,4.92 -11,11 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path177" /><g
id="g179"><g
id="g181"
clip-path="url(#clipPath185)"><text
transform="matrix(1,0,0,-1,844.42,256.3)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text189"><tspan
x="0 24 48 72"
id="tspan90">词法分析</tspan></text></g></g><path
d="m 202.56,254.5 c 0,1.34 1.08,2.42 2.42,2.42 h 147.08 c 1.34,0 2.42,-1.08 2.42,-2.42 v -38.24 c 0,-1.34 -1.08,-2.42 -2.42,-2.42 H 204.98 c -1.34,0 -2.42,1.08 -2.42,2.42 z"
style="fill:#dae3f3;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path94" /><path
d="m 202.56,254.5 c 0,1.34 1.08,2.42 2.42,2.42 h 147.08 c 1.34,0 2.42,-1.08 2.42,-2.42 v -38.24 c 0,-1.34 -1.08,-2.42 -2.42,-2.42 H 204.98 c -1.34,0 -2.42,1.08 -2.42,2.42 z"
style="fill:none;stroke:#404040;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path96" /><g
id="g98"><g
id="g100"
clip-path="url(#clipPath104)"><text
transform="matrix(1,0,0,-1,260.54,240.1)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text108"><tspan
x="0 18"
y="0"
sodipodi:role="line"
id="tspan187">静态生成</tspan></text></g></g></g></svg>
id="tspan106">解析</tspan></text></g></g><g
id="g110"><g
id="g112"
clip-path="url(#clipPath116)"><text
transform="matrix(1,0,0,-1,242.52,218.5)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text120"><tspan
x="0 18 36 54"
y="0"
sodipodi:role="line"
id="tspan118">语法分析</tspan></text></g></g><path
d="m 369.06,269.42 91.63,0.24 -0.01,1.5 -91.62,-0.24 z m 90.63,-2.02 5.99,3.02 -6,2.98 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path122" /><path
d="m 465.6,289.43 c 0,1.33 1.08,2.41 2.41,2.41 h 120.58 c 1.33,0 2.41,-1.08 2.41,-2.41 v -38.02 c 0,-1.33 -1.08,-2.41 -2.41,-2.41 H 468.01 c -1.33,0 -2.41,1.08 -2.41,2.41 z"
style="fill:#dae3f3;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path124" /><path
d="m 465.6,289.43 c 0,1.33 1.08,2.41 2.41,2.41 h 120.58 c 1.33,0 2.41,-1.08 2.41,-2.41 v -38.02 c 0,-1.33 -1.08,-2.41 -2.41,-2.41 H 468.01 c -1.33,0 -2.41,1.08 -2.41,2.41 z"
style="fill:none;stroke:#404040;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path126" /><g
id="g128"><g
id="g130"
clip-path="url(#clipPath134)"><text
transform="matrix(1,0,0,-1,483.36,264.38)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text138"><tspan
x="0 18 36 54 72"
y="0"
sodipodi:role="line"
id="tspan136">语法树转写</tspan></text></g></g><path
d="m 630.96,289.43 c 0,1.33 1.08,2.41 2.41,2.41 h 117.1 c 1.33,0 2.41,-1.08 2.41,-2.41 v -38.02 c 0,-1.33 -1.08,-2.41 -2.41,-2.41 h -117.1 c -1.33,0 -2.41,1.08 -2.41,2.41 z"
style="fill:#dae3f3;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path140" /><path
d="m 630.96,289.43 c 0,1.33 1.08,2.41 2.41,2.41 h 117.1 c 1.33,0 2.41,-1.08 2.41,-2.41 v -38.02 c 0,-1.33 -1.08,-2.41 -2.41,-2.41 h -117.1 c -1.33,0 -2.41,1.08 -2.41,2.41 z"
style="fill:none;stroke:#404040;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path142" /><g
id="g144"><g
id="g146"
clip-path="url(#clipPath150)"><text
transform="matrix(1,0,0,-1,646.97,264.38)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text154"><tspan
x="0 18 36 54 72"
y="0"
sodipodi:role="line"
id="tspan152">静态图代码</tspan></text></g></g><path
d="m 792.84,289.43 c 0,1.33 1.08,2.41 2.41,2.41 h 111.1 c 1.33,0 2.41,-1.08 2.41,-2.41 v -38.02 c 0,-1.33 -1.08,-2.41 -2.41,-2.41 h -111.1 c -1.33,0 -2.41,1.08 -2.41,2.41 z"
style="fill:#dae3f3;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path156" /><path
d="m 792.84,289.43 c 0,1.33 1.08,2.41 2.41,2.41 h 111.1 c 1.33,0 2.41,-1.08 2.41,-2.41 v -38.02 c 0,-1.33 -1.08,-2.41 -2.41,-2.41 h -111.1 c -1.33,0 -2.41,1.08 -2.41,2.41 z"
style="fill:none;stroke:#404040;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path158" /><g
id="g160"><g
id="g162"
clip-path="url(#clipPath166)"><text
transform="matrix(1,0,0,-1,814.85,264.38)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text170"><tspan
x="0 18 36 54"
y="0"
sodipodi:role="line"
id="tspan168">静态生成</tspan></text></g></g><path
d="m 591.06,271.17 h 35 v -1.5 h -35 z m 34,2.25 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path172" /><path
d="m 752.94,271.17 h 35 v -1.5 h -35 z m 34,2.25 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path174" /></g></svg>

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 14 KiB

258
img/ch03/ast1.svg Normal file
View File

@@ -0,0 +1,258 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
version="1.1"
id="svg9"
xml:space="preserve"
width="1269.72"
height="277.57623"
viewBox="0 0 1269.72 277.57623"
sodipodi:docname="ast.svg"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs13"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath23"><path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path21" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath35"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path33" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath49"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path47" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath61"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path59" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath75"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path73" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath87"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path85" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath103"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path101" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath115"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path113" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath129"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path127" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath143"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path141" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath155"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path153" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath185"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path183" /></clipPath></defs><sodipodi:namedview
id="namedview11"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
showgrid="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:zoom="1.321875"
inkscape:cx="636.21749"
inkscape:cy="138.06147"
inkscape:window-width="2560"
inkscape:window-height="1361"
inkscape:window-x="-9"
inkscape:window-y="-9"
inkscape:window-maximized="1"
inkscape:current-layer="g15" /><g
id="g15"
inkscape:groupmode="layer"
inkscape:label="ast"
transform="matrix(1.3333333,0,0,-1.3333333,-3.8599999,498.70537)"><path
d="m 4.02,282.28 c 0,4.78 3.8773,8.66 8.66,8.66 H 147.4 c 4.78,0 8.66,-3.88 8.66,-8.66 v -34.64 c 0,-4.78 -3.88,-8.66 -8.66,-8.66 H 12.68 c -4.7827,0 -8.66,3.88 -8.66,8.66 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path27" /><g
id="g29"><g
id="g31"
clip-path="url(#clipPath35)"><text
transform="matrix(1,0,0,-1,19.992,256.3)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text39"><tspan
x="0 24 48 72 96"
y="0"
sodipodi:role="line"
id="tspan37">动态图代码</tspan></text></g></g><path
d="m 204.54,345.94 c 0,6.08 4.92,11 11,11 h 130.04 c 6.08,0 11,-4.92 11,-11 v -44 c 0,-6.08 -4.92,-11 -11,-11 H 215.54 c -6.08,0 -11,4.92 -11,11 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path41" /><g
id="g43"><g
id="g45"
clip-path="url(#clipPath49)"><text
transform="matrix(1,0,0,-1,256.49,329.74)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text53"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan51">分词</tspan></text></g></g><g
id="g55"><g
id="g57"
clip-path="url(#clipPath61)"><text
transform="matrix(1,0,0,-1,232.49,300.94)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text65"><tspan
x="0 24 48 72"
y="0"
sodipodi:role="line"
id="tspan63">词法分析</tspan></text></g></g><path
d="m 201.3,237.94 c 0,6.08 4.92,11 11,11 h 130.04 c 6.08,0 11,-4.92 11,-11 v -44 c 0,-6.08 -4.92,-11 -11,-11 H 212.3 c -6.08,0 -11,4.92 -11,11 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path67" /><g
id="g69"><g
id="g71"
clip-path="url(#clipPath75)"><text
transform="matrix(1,0,0,-1,253.25,221.64)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text79"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan77">解析</tspan></text></g></g><g
id="g81"><g
id="g83"
clip-path="url(#clipPath87)"><text
transform="matrix(1,0,0,-1,229.25,192.84)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text91"><tspan
x="0 24 48 72"
y="0"
sodipodi:role="line"
id="tspan89">语法分析</tspan></text></g></g><g
id="g93"><path
d="m 188.1,342.74 c 0,16.66 13.5,30.16 30.16,30.16 H 338.9 c 16.66,0 30.16,-13.5 30.16,-30.16 v -145.6 c 0,-16.66 -13.5,-30.16 -30.16,-30.16 H 218.26 c -16.66,0 -30.16,13.5 -30.16,30.16 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:6.75, 2.25;stroke-dashoffset:0;stroke-opacity:1"
id="path95" /></g><g
id="g97"><g
id="g99"
clip-path="url(#clipPath103)"><text
transform="matrix(1,0,0,-1,396.07,316.25)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text107"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan105">抽象</tspan></text></g></g><g
id="g109"><g
id="g111"
clip-path="url(#clipPath115)"><text
transform="matrix(1,0,0,-1,384.07,287.45)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text119"><tspan
x="0 24 48"
y="0"
sodipodi:role="line"
id="tspan117">语法树</tspan></text></g></g><path
d="m 472.26,286.9 c 0,6.08 4.92,11 11,11 H 613.3 c 6.08,0 11,-4.92 11,-11 v -44 c 0,-6.08 -4.92,-11 -11,-11 H 483.26 c -6.08,0 -11,4.92 -11,11 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path121" /><g
id="g123"><g
id="g125"
clip-path="url(#clipPath129)"><text
transform="matrix(1,0,0,-1,488.28,256.3)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text133"><tspan
x="0 24 48 72 96"
y="0"
sodipodi:role="line"
id="tspan131">语法树转写</tspan></text></g></g><path
d="m 675.06,286.9 c 0,6.08 4.92,11 11,11 h 83 c 6.08,0 11,-4.92 11,-11 v -44 c 0,-6.08 -4.92,-11 -11,-11 h -83 c -6.08,0 -11,4.92 -11,11 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path135" /><g
id="g137"><g
id="g139"
clip-path="url(#clipPath143)"><text
transform="matrix(1,0,0,-1,691.54,270.7)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text147"><tspan
x="0 24 48"
y="0"
sodipodi:role="line"
id="tspan145">静态图</tspan></text></g></g><g
id="g149"><g
id="g151"
clip-path="url(#clipPath155)"><text
transform="matrix(1,0,0,-1,703.54,241.9)"
style="font-variant:normal;font-weight:normal;font-size:24.024px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text159"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan157">代码</tspan></text></g></g><path
d="m 156,271.29 h 19.5 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 H 156 Z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path161" /><path
d="m 156,271.29 h 19.5 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 H 156 Z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path163" /><path
d="m 369.24,274.29 h 88.98 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -88.98 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path165" /><path
d="m 369.24,274.29 h 88.98 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -88.98 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path167" /><path
d="m 624.24,271.29 h 37.02 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -37.02 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path169" /><path
d="m 624.24,271.29 h 37.02 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -37.02 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path171" /><path
d="m 779.4,271.29 h 36.9 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -36.9 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path173" /><path
d="m 779.4,271.29 h 36.9 v 6.27 l 12.54,-12.54 -12.54,-12.54 v 6.27 h -36.9 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path175" /><path
d="m 830.82,286.9 c 0,6.08 4.92,11 11,11 h 101.24 c 6.08,0 11,-4.92 11,-11 v -44 c 0,-6.08 -4.92,-11 -11,-11 H 841.82 c -6.08,0 -11,4.92 -11,11 z"
style="fill:none;stroke:#2f528f;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path177" /><g
id="g179"><g
id="g181"
clip-path="url(#clipPath185)"><text
transform="matrix(1,0,0,-1,844.42,256.3)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text189"><tspan
x="0 24 48 72"
y="0"
sodipodi:role="line"
id="tspan187">静态生成</tspan></text></g></g></g></svg>

After

Width:  |  Height:  |  Size: 14 KiB

File diff suppressed because it is too large Load Diff

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 39 KiB

508
img/ch03/dynamic-gen1.svg Normal file
View File

@@ -0,0 +1,508 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
version="1.1"
id="svg5783"
xml:space="preserve"
width="850.20532"
height="324.56"
viewBox="0 0 850.20532 324.56"
sodipodi:docname="dynamic-gen.svg"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs5787"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5797"><path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path5795" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5807"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5805" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5819"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5817" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5831"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5829" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5843"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5841" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5855"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5853" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5867"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5865" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5879"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5877" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5891"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5889" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5903"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5901" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5915"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5913" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5943"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5941" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5955"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5953" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5967"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5965" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5981"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5979" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5993"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5991" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath6007"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path6005" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath6019"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path6017" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath6031"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path6029" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath6045"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path6043" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath6057"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path6055" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath6071"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path6069" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath6083"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path6081" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath6095"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path6093" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath6109"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path6107" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath6121"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path6119" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath6135"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path6133" /></clipPath></defs><sodipodi:namedview
id="namedview5785"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
showgrid="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:zoom="1.321875"
inkscape:cx="497.02128"
inkscape:cy="215.22459"
inkscape:window-width="2560"
inkscape:window-height="1361"
inkscape:window-x="-9"
inkscape:window-y="-9"
inkscape:window-maximized="1"
inkscape:current-layer="g5789" /><g
id="g5789"
inkscape:groupmode="layer"
inkscape:label="dynamic-gen"
transform="matrix(1.3333333,0,0,-1.3333333,-143.19687,575.47999)"><g
id="g5801"><g
id="g5803"
clip-path="url(#clipPath5807)"><text
transform="matrix(1,0,0,-1,106.8,371.16)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#2e75b6;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5811"><tspan
x="0 9 17.063999"
y="0"
sodipodi:role="line"
id="tspan5809">def</tspan></text></g></g><g
id="g5813"><g
id="g5815"
clip-path="url(#clipPath5819)"><text
transform="matrix(1,0,0,-1,134.3,371.16)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5823"><tspan
x="0 13.914 22.914 31.914 39.905998 44.981998 50.976002 63.972 68.472 72.972 78.966003 83.970001 91.998001 100.998 106.992"
y="0"
sodipodi:role="line"
id="tspan5821">model(X, flag):</tspan></text></g></g><g
id="g5825"><g
id="g5827"
clip-path="url(#clipPath5831)"><text
transform="matrix(1,0,0,-1,133.82,349.56)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5835"><tspan
x="0 5.0106721 11.012664 15.518664 21.520657 26.531328 34.533985 43.545982 53.711521 62.723518"
y="0"
sodipodi:role="line"
id="tspan5833">if flag&gt;0:</tspan></text></g></g><g
id="g5837"><g
id="g5839"
clip-path="url(#clipPath5843)"><text
transform="matrix(1,0,0,-1,160.1,327.94)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5847"><tspan
x="0 12.24 16.902 27.054001 31.554001 45.467999 53.459999 58.535999 72.449997 81.449997 86.454002 92.447998 109.44 118.44 122.94 127.512 140.508"
y="0"
sodipodi:role="line"
id="tspan5845">Y = matmul(W1, X)</tspan></text></g></g><g
id="g5849"><g
id="g5851"
clip-path="url(#clipPath5855)"><text
transform="matrix(1,0,0,-1,133.82,306.34)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5859"><tspan
x="0 7.9920001 13.068 20.07 28.062"
y="0"
sodipodi:role="line"
id="tspan5857">else:</tspan></text></g></g><g
id="g5861"><g
id="g5863"
clip-path="url(#clipPath5867)"><text
transform="matrix(1,0,0,-1,160.1,284.74)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5871"><tspan
x="0 12.24 16.902 27.054001 31.554001 45.467999 53.459999 58.535999 72.449997 81.449997 86.454002 92.447998 109.44 118.44 122.94 127.512 140.508"
y="0"
sodipodi:role="line"
id="tspan5869">Y = matmul(W2, X)</tspan></text></g></g><g
id="g5873"><g
id="g5875"
clip-path="url(#clipPath5879)"><text
transform="matrix(1,0,0,-1,133.1,263.14)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5883"><tspan
x="0 12.24 16.902 27.054001 30.816 43.056 47.591999 57.743999 62.243999"
y="0"
sodipodi:role="line"
id="tspan5881">Y = Y + b</tspan></text></g></g><g
id="g5885"><g
id="g5887"
clip-path="url(#clipPath5891)"><text
transform="matrix(1,0,0,-1,133.1,241.54)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5895"><tspan
x="0 12.238296 16.906511 27.072048 31.578049 37.58004 45.582695 50.593369 59.60537 65.607361 78.620689"
y="0"
sodipodi:role="line"
id="tspan5893">Y = relu(Y)</tspan></text></g></g><g
id="g5897"><g
id="g5899"
clip-path="url(#clipPath5903)"><text
transform="matrix(1,0,0,-1,133.82,219.91)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#2e75b6;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5907"><tspan
x="0 5.994 13.986 19.062 28.062 34.056"
y="0"
sodipodi:role="line"
id="tspan5905">return</tspan></text></g></g><g
id="g5909"><g
id="g5911"
clip-path="url(#clipPath5915)"><text
transform="matrix(1,0,0,-1,180.62,219.91)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5919"><tspan
x="0"
y="0"
id="tspan5917">Y</tspan></text></g></g><path
d="m 310.38,334.36 h 54.56 v 68.3 l -0.75,-0.75 h 48.82 v 1.5 h -49.57 v -68.3 l 0.75,0.75 h -53.81 z m 101.63,65.3 6,3 -6,3 z"
style="fill:#0070c0;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path5921" /><g
id="g5923"><path
d="m 417.9,423.54 c 0,4.04 3.28,7.32 7.32,7.32 h 307.8 c 4.04,0 7.32,-3.28 7.32,-7.32 v -29.28 c 0,-4.04 -3.28,-7.32 -7.32,-7.32 h -307.8 c -4.04,0 -7.32,3.28 -7.32,7.32 z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:1.5, 1.5;stroke-dashoffset:0;stroke-opacity:1"
id="path5925" /></g><g
id="g5927"><path
d="m 421.98,348.92 c 0,4.03 3.27,7.3 7.3,7.3 H 737 c 4.03,0 7.3,-3.27 7.3,-7.3 v -29.2 c 0,-4.03 -3.27,-7.3 -7.3,-7.3 H 429.28 c -4.03,0 -7.3,3.27 -7.3,7.3 z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:1.5, 1.5;stroke-dashoffset:0;stroke-opacity:1"
id="path5929" /></g><g
id="g5931"><path
d="m 417.9,277.02 c 0,4.04 3.28,7.32 7.32,7.32 h 307.8 c 4.04,0 7.32,-3.28 7.32,-7.32 v -29.28 c 0,-4.04 -3.28,-7.32 -7.32,-7.32 h -307.8 c -4.04,0 -7.32,3.28 -7.32,7.32 z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:1.5, 1.5;stroke-dashoffset:0;stroke-opacity:1"
id="path5933" /></g><path
d="m 425.46,417.84 c 0,2.49 2.01,4.5 4.5,4.5 h 120.48 c 2.49,0 4.5,-2.01 4.5,-4.5 v -18 c 0,-2.49 -2.01,-4.5 -4.5,-4.5 H 429.96 c -2.49,0 -4.5,2.01 -4.5,4.5 z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5935" /><g
id="g5937"><g
id="g5939"
clip-path="url(#clipPath5943)"><text
transform="matrix(1,0,0,-1,435.82,404.59)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5947"><tspan
x="0 12 24 36"
y="0"
sodipodi:role="line"
id="tspan5945">运行前向</tspan></text></g></g><g
id="g5949"><g
id="g5951"
clip-path="url(#clipPath5955)"><text
transform="matrix(1,0,0,-1,483.82,404.59)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5959"><tspan
x="0 9.3360004 14.664 18 27.336 33.335999"
y="0"
sodipodi:role="line"
id="tspan5957">matmul</tspan></text></g></g><g
id="g5961"><g
id="g5963"
clip-path="url(#clipPath5967)"><text
transform="matrix(1,0,0,-1,520.56,404.59)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5971"><tspan
x="0 12"
y="0"
sodipodi:role="line"
id="tspan5969">算子</tspan></text></g></g><path
d="m 573.42,417.24 c 0,2.49 2.01,4.5 4.5,4.5 H 723 c 2.49,0 4.5,-2.01 4.5,-4.5 v -18 c 0,-2.49 -2.01,-4.5 -4.5,-4.5 H 577.92 c -2.49,0 -4.5,2.01 -4.5,4.5 z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5973" /><g
id="g5975"><g
id="g5977"
clip-path="url(#clipPath5981)"><text
transform="matrix(1,0,0,-1,596.09,403.9)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5985"><tspan
x="0 9.3360004 14.664 18 27.336 33.335999"
y="0"
sodipodi:role="line"
id="tspan5983">matmul</tspan></text></g></g><g
id="g5987"><g
id="g5989"
clip-path="url(#clipPath5993)"><text
transform="matrix(1,0,0,-1,632.81,403.9)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5997"><tspan
x="0 12 24 36 48 60"
y="0"
sodipodi:role="line"
id="tspan5995">算子反向计算</tspan></text></g></g><path
d="m 436.98,344.34 c 0,3.05 2.47,5.52 5.52,5.52 h 110.64 c 3.05,0 5.52,-2.47 5.52,-5.52 v -22.08 c 0,-3.05 -2.47,-5.52 -5.52,-5.52 H 442.5 c -3.05,0 -5.52,2.47 -5.52,5.52 z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5999" /><g
id="g6001"><g
id="g6003"
clip-path="url(#clipPath6007)"><text
transform="matrix(1,0,0,-1,453.14,329.02)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text6011"><tspan
x="0 12 24 36"
y="0"
sodipodi:role="line"
id="tspan6009">运行前向</tspan></text></g></g><g
id="g6013"><g
id="g6015"
clip-path="url(#clipPath6019)"><text
transform="matrix(1,0,0,-1,501.14,329.02)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text6023"><tspan
x="0 5.2785358 11.290536"
y="0"
sodipodi:role="line"
id="tspan6021">add</tspan></text></g></g><g
id="g6025"><g
id="g6027"
clip-path="url(#clipPath6031)"><text
transform="matrix(1,0,0,-1,518.42,329.02)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text6035"><tspan
x="0 12"
y="0"
sodipodi:role="line"
id="tspan6033">算子</tspan></text></g></g><path
d="m 576.18,344.46 c 0,3.05 2.47,5.52 5.52,5.52 h 149.52 c 3.05,0 5.52,-2.47 5.52,-5.52 v -22.08 c 0,-3.05 -2.47,-5.52 -5.52,-5.52 H 581.7 c -3.05,0 -5.52,2.47 -5.52,5.52 z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path6037" /><g
id="g6039"><g
id="g6041"
clip-path="url(#clipPath6045)"><text
transform="matrix(1,0,0,-1,611.78,329.11)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text6049"><tspan
x="0 5.2785358 11.290536"
y="0"
sodipodi:role="line"
id="tspan6047">add</tspan></text></g></g><g
id="g6051"><g
id="g6053"
clip-path="url(#clipPath6057)"><text
transform="matrix(1,0,0,-1,629.06,329.11)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text6061"><tspan
x="0 12 24 36 48 60"
y="0"
sodipodi:role="line"
id="tspan6059">算子反向计算</tspan></text></g></g><path
d="m 432.9,273.42 c 0,3.05 2.47,5.52 5.52,5.52 h 112.2 c 3.05,0 5.52,-2.47 5.52,-5.52 v -22.08 c 0,-3.05 -2.47,-5.52 -5.52,-5.52 h -112.2 c -3.05,0 -5.52,2.47 -5.52,5.52 z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path6063" /><g
id="g6065"><g
id="g6067"
clip-path="url(#clipPath6071)"><text
transform="matrix(1,0,0,-1,443.98,258.05)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text6075"><tspan
x="0 12 24 36"
y="0"
sodipodi:role="line"
id="tspan6073">运行前向</tspan></text></g></g><g
id="g6077"><g
id="g6079"
clip-path="url(#clipPath6083)"><text
transform="matrix(1,0,0,-1,491.98,258.05)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text6087"><tspan
x="0 8.0200081 13.322592 20.404728"
y="0"
sodipodi:role="line"
id="tspan6085">ReLU</tspan></text></g></g><g
id="g6089"><g
id="g6091"
clip-path="url(#clipPath6095)"><text
transform="matrix(1,0,0,-1,521.02,258.05)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text6099"><tspan
x="0 12.024"
y="0"
sodipodi:role="line"
id="tspan6097">算子</tspan></text></g></g><path
d="m 573.42,273.42 c 0,3.05 2.47,5.52 5.52,5.52 h 149.52 c 3.05,0 5.52,-2.47 5.52,-5.52 v -22.08 c 0,-3.05 -2.47,-5.52 -5.52,-5.52 H 578.94 c -3.05,0 -5.52,2.47 -5.52,5.52 z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path6101" /><g
id="g6103"><g
id="g6105"
clip-path="url(#clipPath6109)"><text
transform="matrix(1,0,0,-1,603.19,258.05)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text6113"><tspan
x="0 8.052 13.332 20.436001"
y="0"
sodipodi:role="line"
id="tspan6111">ReLU</tspan></text></g></g><g
id="g6115"><g
id="g6117"
clip-path="url(#clipPath6121)"><text
transform="matrix(1,0,0,-1,632.26,258.05)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text6125"><tspan
x="0 12 24 36 48 60"
y="0"
sodipodi:role="line"
id="tspan6123">算子反向计算</tspan></text></g></g><path
d="m 599.82,211.44 c 0,2.49 2.01,4.5 4.5,4.5 h 102.6 c 2.49,0 4.5,-2.01 4.5,-4.5 v -18 c 0,-2.49 -2.01,-4.5 -4.5,-4.5 h -102.6 c -2.49,0 -4.5,2.01 -4.5,4.5 z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path6127" /><g
id="g6129"><g
id="g6131"
clip-path="url(#clipPath6135)"><text
transform="matrix(1,0,0,-1,619.61,198.17)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text6139"><tspan
x="0 12.024 24.048 36.071999 48.096001 60.119999"
y="0"
sodipodi:role="line"
id="tspan6137">梯度反向计算</tspan></text></g></g><path
d="m 488.64,368.76 h 2.4 v 11.16 h 4.8 v -11.16 h 2.4 l -4.8,-4.8 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path6141" /><path
d="m 488.64,368.76 h 2.4 v 11.16 h 4.8 v -11.16 h 2.4 l -4.8,-4.8 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path6143" /><path
d="m 491.16,292.56 h 2.58 v 14.52 h 5.16 v -14.52 h 2.58 l -5.16,-5.16 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path6145" /><path
d="m 491.16,292.56 h 2.58 v 14.52 h 5.16 v -14.52 h 2.58 l -5.16,-5.16 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path6147" /><path
d="m 658.56,232.26 h -2.37 v -11.22 h -4.74 v 11.22 h -2.37 l 4.74,4.74 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path6149" /><path
d="m 658.56,232.26 h -2.37 v -11.22 h -4.74 v 11.22 h -2.37 l 4.74,4.74 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path6151" /><path
d="m 658.68,300.06 h -2.37 v -11.22 h -4.74 v 11.22 h -2.37 l 4.74,4.74 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path6153" /><path
d="m 658.68,300.06 h -2.37 v -11.22 h -4.74 v 11.22 h -2.37 l 4.74,4.74 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path6155" /><path
d="m 658.44,375.78 h -2.37 v -11.22 h -4.74 v 11.22 h -2.37 l 4.74,4.74 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path6157" /><path
d="m 658.44,375.78 h -2.37 v -11.22 h -4.74 v 11.22 h -2.37 l 4.74,4.74 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path6159" /><path
d="m 220.86,269.14 h 157.75 v 65.12 l -0.75,-0.75 h 39.18 v 1.5 h -39.93 v -65.12 l 0.75,0.75 h -157 z m 195.18,62.12 6,3 -6,3 z"
style="fill:#0070c0;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path6161" /><path
d="M 220.86,242.88 H 385.5 v 19.5 l -0.75,-0.75 H 413 v 1.5 h -29 v -19.5 l 0.75,0.75 H 220.86 Z m 191.14,16.5 6,3 -6,3 z"
style="fill:#0070c0;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path6163" /></g></svg>

After

Width:  |  Height:  |  Size: 28 KiB

View File

@@ -2,259 +2,673 @@
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
width="162.68581mm"
height="67.656052mm"
viewBox="0 0 162.68581 67.656052"
version="1.1"
id="svg5016"
xml:space="preserve"
width="762.47937"
height="246.65395"
viewBox="0 0 762.47937 246.65395"
sodipodi:docname="dynamic.svg"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
id="svg5"
inkscape:version="1.1.2 (b8e25be833, 2022-02-05)"
sodipodi:docname="动态图.svg"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs5020"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5030"><path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path5028" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5042"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5040" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5056"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5054" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5070"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5068" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5086"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5084" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5102"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5100" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5122"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5120" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5134"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5132" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5146"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5144" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5158"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5156" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5176"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5174" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5188"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5186" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5200"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5198" /></clipPath></defs><sodipodi:namedview
id="namedview5018"
xmlns:svg="http://www.w3.org/2000/svg">
<sodipodi:namedview
id="namedview7"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
inkscape:document-units="mm"
showgrid="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:zoom="1.321875"
inkscape:cx="442.55319"
inkscape:cy="117.63593"
inkscape:window-width="2560"
inkscape:window-height="1361"
inkscape:window-x="-9"
inkscape:window-y="-9"
inkscape:window-maximized="1"
inkscape:current-layer="g5022" /><g
id="g5022"
inkscape:zoom="0.77771465"
inkscape:cx="278.37974"
inkscape:cy="35.360013"
inkscape:window-width="1926"
inkscape:window-height="1164"
inkscape:window-x="434"
inkscape:window-y="158"
inkscape:window-maximized="0"
inkscape:current-layer="g571" />
<defs
id="defs2">
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath23">
<path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path21" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath35">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path33" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath49">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path47" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath63">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path61" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath79">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path77" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath95">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path93" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath109">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path107" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath129">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path127" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath141">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path139" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath153">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path151" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath165">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path163" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath177">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path175" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath189">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path187" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath201">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path199" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath213">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path211" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath229">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path227" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath241">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path239" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath253">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path251" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath265">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path263" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath579">
<path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path577" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath591">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path589" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath605">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path603" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath619">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path617" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath635">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path633" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath651">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path649" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath665">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path663" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath685">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path683" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath697">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path695" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath709">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path707" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath721">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path719" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath733">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path731" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath745">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path743" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath757">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path755" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath769">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path767" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath785">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path783" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath797">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path795" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath809">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path807" />
</clipPath>
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath821">
<path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path819" />
</clipPath>
</defs>
<g
inkscape:label="图层 1"
inkscape:groupmode="layer"
inkscape:label="dynamic"
transform="matrix(1.3333333,0,0,-1.3333333,-197.68062,478.01395)"><path
d="m 163.02,295.32 44.52,-20.85 -0.96,-2.03 -44.52,20.84 z m 44.45,-18.33 4.69,-5.92 -7.55,-0.19 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path5034" /><g
id="g5036"><g
id="g5038"
clip-path="url(#clipPath5042)"><text
transform="matrix(1,0,0,-1,245.38,273.79)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:20.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5046"><tspan
x="0"
y="0"
id="tspan5044">Y</tspan></text></g></g><path
d="m 167.62,228.57 34.61,23.81 -1.28,1.86 -34.61,-23.81 z m 34.95,21.32 3.65,6.61 -7.47,-1.05 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path5048" /><g
id="g5050"><g
id="g5052"
clip-path="url(#clipPath5056)"><text
transform="matrix(1,0,0,-1,149.28,287.81)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:18.024px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5060"><tspan
x="0"
y="0"
id="tspan5058">W</tspan></text></g></g><path
d="m 237.42,265.55 27.18,-0.01 v -2.24 h -27.18 z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path5062" /><g
id="g5064"><g
id="g5066"
clip-path="url(#clipPath5070)"><text
transform="matrix(1,0,0,-1,149.28,223.01)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5074"><tspan
x="0"
y="0"
id="tspan5072">A</tspan></text></g></g><path
d="m 206.22,264 c 0,7.09 5.88,12.84 13.14,12.84 7.26,0 13.14,-5.75 13.14,-12.84 0,-7.09 -5.88,-12.84 -13.14,-12.84 -7.26,0 -13.14,5.75 -13.14,12.84 z"
style="fill:none;stroke:#000000;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5078" /><g
id="g5080"
transform="translate(-3.9716313,-4.5390074)"><g
id="g5082"
clip-path="url(#clipPath5086)"><text
transform="matrix(1,0,0,-1,216.24,252.65)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5090"><tspan
x="0"
y="0"
id="tspan5088">*</tspan></text></g></g><path
d="m 269.34,265.2 c 0,11.1 9,20.1 20.1,20.1 11.1,0 20.1,-9 20.1,-20.1 0,-11.1 -9,-20.1 -20.1,-20.1 -11.1,0 -20.1,9 -20.1,20.1 z"
style="fill:none;stroke:#000000;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5094" /><g
id="g5096"><g
id="g5098"
clip-path="url(#clipPath5102)"><text
transform="matrix(1,0,0,-1,273.22,260.16)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5106"><tspan
x="0 9.3646803 15.59844 24.12072"
y="0"
sodipodi:role="line"
id="tspan5104">ReLU</tspan></text></g></g><path
d="m 309.54,265.55 27.18,-0.01 v -2.24 h -27.18 z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path5108" /><path
d="m 364.2,269.34 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 H 364.2 Z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path5110" /><path
d="m 364.2,269.34 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 H 364.2 Z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5112" /><path
d="m 434.58,304.56 c 0,27.21 22.05,49.26 49.26,49.26 v 0 c 27.21,0 49.26,-22.05 49.26,-49.26 v -80.28 c 0,-27.21 -22.05,-49.26 -49.26,-49.26 v 0 c -27.21,0 -49.26,22.05 -49.26,49.26 z"
style="fill:none;stroke:#2f528f;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5114" /><g
id="g5116"><g
id="g5118"
clip-path="url(#clipPath5122)"><text
transform="matrix(1,0,0,-1,459.77,298.97)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5126"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5124">计算</tspan></text></g></g><g
id="g5128"><g
id="g5130"
clip-path="url(#clipPath5134)"><text
transform="matrix(1,0,0,-1,459.77,270.17)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5138"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5136">框架</tspan></text></g></g><g
id="g5140"><g
id="g5142"
clip-path="url(#clipPath5146)"><text
transform="matrix(1,0,0,-1,459.77,241.37)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5150"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5148">算子</tspan></text></g></g><g
id="g5152"><g
id="g5154"
clip-path="url(#clipPath5158)"><text
transform="matrix(1,0,0,-1,459.77,212.42)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5162"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5160">分发</tspan></text></g></g><path
d="m 545.52,269.34 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path5164" /><path
d="m 545.52,269.34 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5166" /><path
d="m 630.78,295.98 c 0,24.26 19.66,43.92 43.92,43.92 v 0 c 24.26,0 43.92,-19.66 43.92,-43.92 v -59.76 c 0,-24.26 -19.66,-43.92 -43.92,-43.92 v 0 c -24.26,0 -43.92,19.66 -43.92,43.92 z"
style="fill:none;stroke:#2f528f;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5168" /><g
id="g5170"><g
id="g5172"
clip-path="url(#clipPath5176)"><text
transform="matrix(1,0,0,-1,650.88,277.1)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5180"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5178">硬件</tspan></text></g></g><g
id="g5182"><g
id="g5184"
clip-path="url(#clipPath5188)"><text
transform="matrix(1,0,0,-1,650.88,248.18)"
style="font-variant:normal;font-weight:normal;font-size:24.024px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5192"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5190">执行</tspan></text></g></g><g
id="g5194"><g
id="g5196"
clip-path="url(#clipPath5200)"><text
transform="matrix(1,0,0,-1,182.09,331.66)"
style="font-variant:normal;font-weight:normal;font-size:32.064px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5204"><tspan
x="0 32.040001 64.080002 96.120003"
y="0"
sodipodi:role="line"
id="tspan5202">前端定义</tspan></text></g></g></g></svg>
id="layer1"
transform="translate(-31.425089,-138.98401)">
<g
id="g571"
inkscape:label="ch04-graph_29"
transform="matrix(0.35277777,0,0,-0.35277777,-14.539515,268.41498)">
<path
d="m 163.02,295.32 44.52,-20.85 -0.96,-2.03 -44.52,20.84 z m 44.45,-18.33 4.69,-5.92 -7.55,-0.19 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path583" />
<g
id="g585">
<g
id="g587"
clip-path="url(#clipPath591)">
<text
transform="matrix(1,0,0,-1,245.38,273.82)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:20.064px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text595"><tspan
x="0"
y="0"
id="tspan593">Y</tspan></text>
</g>
</g>
<path
d="m 167.62,228.57 34.61,23.81 -1.28,1.86 -34.61,-23.81 z m 34.95,21.32 3.65,6.61 -7.47,-1.05 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path597" />
<g
id="g599">
<g
id="g601"
clip-path="url(#clipPath605)">
<text
transform="matrix(1,0,0,-1,149.28,287.81)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text609"><tspan
x="0"
y="0"
id="tspan607">W</tspan></text>
</g>
</g>
<path
d="m 237.42,265.55 h 27.18 v -2.25 h -27.18 z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path611" />
<g
id="g613">
<g
id="g615"
clip-path="url(#clipPath619)">
<text
transform="matrix(1,0,0,-1,149.28,223.01)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text623"><tspan
x="0"
y="0"
id="tspan621">A</tspan></text>
</g>
</g>
<path
d="m 211.14,264.42 c 0,7.09 5.88,12.84 13.14,12.84 7.26,0 13.14,-5.75 13.14,-12.84 0,-7.09 -5.88,-12.84 -13.14,-12.84 -7.26,0 -13.14,5.75 -13.14,12.84 z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path625" />
<path
d="m 211.14,264.42 c 0,7.09 5.88,12.84 13.14,12.84 7.26,0 13.14,-5.75 13.14,-12.84 0,-7.09 -5.88,-12.84 -13.14,-12.84 -7.26,0 -13.14,5.75 -13.14,12.84 z"
style="fill:none;stroke:#000000;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path627" />
<g
id="g629">
<g
id="g631"
clip-path="url(#clipPath635)">
<text
transform="matrix(1,0,0,-1,217.68,253.73)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text639"><tspan
x="0"
y="0"
id="tspan637">*</tspan></text>
</g>
</g>
<path
d="m 269.34,265.2 c 0,11.1 9,20.1 20.1,20.1 11.1,0 20.1,-9 20.1,-20.1 0,-11.1 -9,-20.1 -20.1,-20.1 -11.1,0 -20.1,9 -20.1,20.1 z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path641" />
<path
d="m 269.34,265.2 c 0,11.1 9,20.1 20.1,20.1 11.1,0 20.1,-9 20.1,-20.1 0,-11.1 -9,-20.1 -20.1,-20.1 -11.1,0 -20.1,9 -20.1,20.1 z"
style="fill:none;stroke:#000000;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path643" />
<g
id="g645">
<g
id="g647"
clip-path="url(#clipPath651)">
<text
transform="matrix(1,0,0,-1,273.22,260.18)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text655"><tspan
x="0 9.3806877 15.625104 24.119761"
y="0"
sodipodi:role="line"
id="tspan653">ReLU</tspan></text>
</g>
</g>
<path
d="m 309.54,265.55 h 27.18 v -2.25 h -27.18 z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path657" />
<g
id="g659">
<g
id="g661"
clip-path="url(#clipPath665)">
<text
transform="matrix(1,0,0,-1,189.29,347.93)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text669"><tspan
x="0 24 48 72"
y="0"
sodipodi:role="line"
id="tspan667">前端定义</tspan></text>
</g>
</g>
<g
id="g671">
<path
d="m 130.8,318.24 c 0,3.64 2.96,6.6 6.6,6.6 h 199.8 c 3.64,0 6.6,-2.96 6.6,-6.6 V 214.08 c 0,-3.64 -2.96,-6.6 -6.6,-6.6 H 137.4 c -3.64,0 -6.6,2.96 -6.6,6.6 z"
style="fill:none;stroke:#4472c4;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:3, 1;stroke-dashoffset:0;stroke-opacity:1"
id="path673" />
</g>
<path
d="m 413.82,324.66 c 0,16.5 13.38,29.88 29.88,29.88 v 0 c 16.5,0 29.88,-13.38 29.88,-29.88 V 205.74 c 0,-16.5 -13.38,-29.88 -29.88,-29.88 v 0 c -16.5,0 -29.88,13.38 -29.88,29.88 z"
style="fill:#b4c7e7;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path675" />
<path
d="m 413.82,324.66 c 0,16.5 13.38,29.88 29.88,29.88 v 0 c 16.5,0 29.88,-13.38 29.88,-29.88 V 205.74 c 0,-16.5 -13.38,-29.88 -29.88,-29.88 v 0 c -16.5,0 -29.88,13.38 -29.88,29.88 z"
style="fill:none;stroke:#000000;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path677" />
<g
id="g679">
<g
id="g681"
clip-path="url(#clipPath685)">
<text
transform="matrix(1,0,0,-1,434.64,334.82)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text689"><tspan
x="0"
y="0"
id="tspan687">计</tspan></text>
</g>
</g>
<g
id="g691">
<g
id="g693"
clip-path="url(#clipPath697)">
<text
transform="matrix(1,0,0,-1,434.64,313.22)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text701"><tspan
x="0"
y="0"
id="tspan699">算</tspan></text>
</g>
</g>
<g
id="g703">
<g
id="g705"
clip-path="url(#clipPath709)">
<text
transform="matrix(1,0,0,-1,434.64,291.62)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text713"><tspan
x="0"
y="0"
id="tspan711">框</tspan></text>
</g>
</g>
<g
id="g715">
<g
id="g717"
clip-path="url(#clipPath721)">
<text
transform="matrix(1,0,0,-1,434.64,270.02)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text725"><tspan
x="0"
y="0"
id="tspan723">架</tspan></text>
</g>
</g>
<g
id="g727">
<g
id="g729"
clip-path="url(#clipPath733)">
<text
transform="matrix(1,0,0,-1,434.64,248.42)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text737"><tspan
x="0"
y="0"
id="tspan735">算</tspan></text>
</g>
</g>
<g
id="g739">
<g
id="g741"
clip-path="url(#clipPath745)">
<text
transform="matrix(1,0,0,-1,434.64,226.8)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text749"><tspan
x="0"
y="0"
id="tspan747">子</tspan></text>
</g>
</g>
<g
id="g751">
<g
id="g753"
clip-path="url(#clipPath757)">
<text
transform="matrix(1,0,0,-1,434.64,205.2)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text761"><tspan
x="0"
y="0"
id="tspan759">分</tspan></text>
</g>
</g>
<g
id="g763">
<g
id="g765"
clip-path="url(#clipPath769)">
<text
transform="matrix(1,0,0,-1,434.64,183.6)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text773"><tspan
x="0"
y="0"
id="tspan771">发</tspan></text>
</g>
</g>
<path
d="m 543.54,315.48 c 0,13.02 10.56,23.58 23.58,23.58 v 0 c 13.02,0 23.58,-10.56 23.58,-23.58 V 215.04 c 0,-13.02 -10.56,-23.58 -23.58,-23.58 v 0 c -13.02,0 -23.58,10.56 -23.58,23.58 z"
style="fill:#b4c7e7;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path775" />
<path
d="m 543.54,315.48 c 0,13.02 10.56,23.58 23.58,23.58 v 0 c 13.02,0 23.58,-10.56 23.58,-23.58 V 215.04 c 0,-13.02 -10.56,-23.58 -23.58,-23.58 v 0 c -13.02,0 -23.58,10.56 -23.58,23.58 z"
style="fill:none;stroke:#000000;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path777" />
<g
id="g779">
<g
id="g781"
clip-path="url(#clipPath785)">
<text
transform="matrix(1,0,0,-1,558.02,291.62)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text789"><tspan
x="0"
y="0"
id="tspan787">硬</tspan></text>
</g>
</g>
<g
id="g791">
<g
id="g793"
clip-path="url(#clipPath797)">
<text
transform="matrix(1,0,0,-1,558.02,270.02)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text801"><tspan
x="0"
y="0"
id="tspan799">件</tspan></text>
</g>
</g>
<g
id="g803">
<g
id="g805"
clip-path="url(#clipPath809)">
<text
transform="matrix(1,0,0,-1,558.02,248.42)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text813"><tspan
x="0"
y="0"
id="tspan811">执</tspan></text>
</g>
</g>
<g
id="g815">
<g
id="g817"
clip-path="url(#clipPath821)">
<text
transform="matrix(1,0,0,-1,558.02,226.8)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text825"><tspan
x="0"
y="0"
id="tspan823">行</tspan></text>
</g>
</g>
<path
d="m 351.06,264.51 h 57.83 v 1.5 h -57.83 z m 56.83,-2.25 6,3 -6,3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path827" />
<path
d="m 473.58,266.01 h 64.96 v -1.5 h -64.96 z m 63.96,2.25 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path829" />
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 23 KiB

260
img/ch03/dynamic1.svg Normal file
View File

@@ -0,0 +1,260 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
version="1.1"
id="svg5016"
xml:space="preserve"
width="762.47937"
height="246.65395"
viewBox="0 0 762.47937 246.65395"
sodipodi:docname="dynamic.svg"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs5020"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5030"><path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path5028" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5042"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5040" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5056"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5054" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5070"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5068" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5086"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5084" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5102"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5100" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5122"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5120" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5134"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5132" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5146"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5144" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5158"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5156" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5176"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5174" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5188"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5186" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath5200"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path5198" /></clipPath></defs><sodipodi:namedview
id="namedview5018"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
showgrid="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:zoom="1.321875"
inkscape:cx="442.55319"
inkscape:cy="117.63593"
inkscape:window-width="2560"
inkscape:window-height="1361"
inkscape:window-x="-9"
inkscape:window-y="-9"
inkscape:window-maximized="1"
inkscape:current-layer="g5022" /><g
id="g5022"
inkscape:groupmode="layer"
inkscape:label="dynamic"
transform="matrix(1.3333333,0,0,-1.3333333,-197.68062,478.01395)"><path
d="m 163.02,295.32 44.52,-20.85 -0.96,-2.03 -44.52,20.84 z m 44.45,-18.33 4.69,-5.92 -7.55,-0.19 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path5034" /><g
id="g5036"><g
id="g5038"
clip-path="url(#clipPath5042)"><text
transform="matrix(1,0,0,-1,245.38,273.79)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:20.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5046"><tspan
x="0"
y="0"
id="tspan5044">Y</tspan></text></g></g><path
d="m 167.62,228.57 34.61,23.81 -1.28,1.86 -34.61,-23.81 z m 34.95,21.32 3.65,6.61 -7.47,-1.05 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path5048" /><g
id="g5050"><g
id="g5052"
clip-path="url(#clipPath5056)"><text
transform="matrix(1,0,0,-1,149.28,287.81)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:18.024px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5060"><tspan
x="0"
y="0"
id="tspan5058">W</tspan></text></g></g><path
d="m 237.42,265.55 27.18,-0.01 v -2.24 h -27.18 z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path5062" /><g
id="g5064"><g
id="g5066"
clip-path="url(#clipPath5070)"><text
transform="matrix(1,0,0,-1,149.28,223.01)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5074"><tspan
x="0"
y="0"
id="tspan5072">A</tspan></text></g></g><path
d="m 206.22,264 c 0,7.09 5.88,12.84 13.14,12.84 7.26,0 13.14,-5.75 13.14,-12.84 0,-7.09 -5.88,-12.84 -13.14,-12.84 -7.26,0 -13.14,5.75 -13.14,12.84 z"
style="fill:none;stroke:#000000;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5078" /><g
id="g5080"
transform="translate(-3.9716313,-4.5390074)"><g
id="g5082"
clip-path="url(#clipPath5086)"><text
transform="matrix(1,0,0,-1,216.24,252.65)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5090"><tspan
x="0"
y="0"
id="tspan5088">*</tspan></text></g></g><path
d="m 269.34,265.2 c 0,11.1 9,20.1 20.1,20.1 11.1,0 20.1,-9 20.1,-20.1 0,-11.1 -9,-20.1 -20.1,-20.1 -11.1,0 -20.1,9 -20.1,20.1 z"
style="fill:none;stroke:#000000;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5094" /><g
id="g5096"><g
id="g5098"
clip-path="url(#clipPath5102)"><text
transform="matrix(1,0,0,-1,273.22,260.16)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5106"><tspan
x="0 9.3646803 15.59844 24.12072"
y="0"
sodipodi:role="line"
id="tspan5104">ReLU</tspan></text></g></g><path
d="m 309.54,265.55 27.18,-0.01 v -2.24 h -27.18 z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path5108" /><path
d="m 364.2,269.34 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 H 364.2 Z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path5110" /><path
d="m 364.2,269.34 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 H 364.2 Z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5112" /><path
d="m 434.58,304.56 c 0,27.21 22.05,49.26 49.26,49.26 v 0 c 27.21,0 49.26,-22.05 49.26,-49.26 v -80.28 c 0,-27.21 -22.05,-49.26 -49.26,-49.26 v 0 c -27.21,0 -49.26,22.05 -49.26,49.26 z"
style="fill:none;stroke:#2f528f;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5114" /><g
id="g5116"><g
id="g5118"
clip-path="url(#clipPath5122)"><text
transform="matrix(1,0,0,-1,459.77,298.97)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5126"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5124">计算</tspan></text></g></g><g
id="g5128"><g
id="g5130"
clip-path="url(#clipPath5134)"><text
transform="matrix(1,0,0,-1,459.77,270.17)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5138"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5136">框架</tspan></text></g></g><g
id="g5140"><g
id="g5142"
clip-path="url(#clipPath5146)"><text
transform="matrix(1,0,0,-1,459.77,241.37)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5150"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5148">算子</tspan></text></g></g><g
id="g5152"><g
id="g5154"
clip-path="url(#clipPath5158)"><text
transform="matrix(1,0,0,-1,459.77,212.42)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5162"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5160">分发</tspan></text></g></g><path
d="m 545.52,269.34 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path5164" /><path
d="m 545.52,269.34 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5166" /><path
d="m 630.78,295.98 c 0,24.26 19.66,43.92 43.92,43.92 v 0 c 24.26,0 43.92,-19.66 43.92,-43.92 v -59.76 c 0,-24.26 -19.66,-43.92 -43.92,-43.92 v 0 c -24.26,0 -43.92,19.66 -43.92,43.92 z"
style="fill:none;stroke:#2f528f;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path5168" /><g
id="g5170"><g
id="g5172"
clip-path="url(#clipPath5176)"><text
transform="matrix(1,0,0,-1,650.88,277.1)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5180"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5178">硬件</tspan></text></g></g><g
id="g5182"><g
id="g5184"
clip-path="url(#clipPath5188)"><text
transform="matrix(1,0,0,-1,650.88,248.18)"
style="font-variant:normal;font-weight:normal;font-size:24.024px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5192"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan5190">执行</tspan></text></g></g><g
id="g5194"><g
id="g5196"
clip-path="url(#clipPath5200)"><text
transform="matrix(1,0,0,-1,182.09,331.66)"
style="font-variant:normal;font-weight:normal;font-size:32.064px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text5204"><tspan
x="0 32.040001 64.080002 96.120003"
y="0"
sodipodi:role="line"
id="tspan5202">前端定义</tspan></text></g></g></g></svg>

After

Width:  |  Height:  |  Size: 13 KiB

View File

@@ -3,109 +3,109 @@
<svg
version="1.1"
id="svg12628"
id="svg2"
xml:space="preserve"
width="1044.8153"
height="270.35999"
viewBox="0 0 1044.8153 270.35999"
sodipodi:docname="static.svg"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
width="800.31769"
height="275.66666"
viewBox="0 0 800.31768 275.66666"
sodipodi:docname="ch04-graph_19.svg"
inkscape:version="1.1.2 (b8e25be833, 2022-02-05)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs12632"><clipPath
id="defs6"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12642"><path
id="clipPath16"><path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path12640" /></clipPath><clipPath
id="path14" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12654"><path
id="clipPath28"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12652" /></clipPath><clipPath
id="path26" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12668"><path
id="clipPath42"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12666" /></clipPath><clipPath
id="path40" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12682"><path
id="clipPath56"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12680" /></clipPath><clipPath
id="path54" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12698"><path
id="clipPath72"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12696" /></clipPath><clipPath
id="path70" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12714"><path
id="clipPath88"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12712" /></clipPath><clipPath
id="path86" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12734"><path
id="clipPath106"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12732" /></clipPath><clipPath
id="path104" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12746"><path
id="clipPath118"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12744" /></clipPath><clipPath
id="path116" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12758"><path
id="clipPath130"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12756" /></clipPath><clipPath
id="path128" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12776"><path
id="clipPath146"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12774" /></clipPath><clipPath
id="path144" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12788"><path
id="clipPath158"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12786" /></clipPath><clipPath
id="path156" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12800"><path
id="clipPath170"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12798" /></clipPath><clipPath
id="path168" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12818"><path
id="clipPath188"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12816" /></clipPath><clipPath
id="path186" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12830"><path
id="clipPath200"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12828" /></clipPath><clipPath
id="path198" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12842"><path
id="clipPath212"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12840" /></clipPath><clipPath
id="path210" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12860"><path
id="clipPath228"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12858" /></clipPath><clipPath
id="path226" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12872"><path
id="clipPath240"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12870" /></clipPath><clipPath
id="path238" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12884"><path
id="clipPath252"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12882" /></clipPath></defs><sodipodi:namedview
id="namedview12630"
id="path250" /></clipPath></defs><sodipodi:namedview
id="namedview4"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
@@ -117,226 +117,238 @@
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:zoom="1.321875"
inkscape:cx="556.78487"
inkscape:cy="170.59102"
inkscape:zoom="1.2067845"
inkscape:cx="409.76662"
inkscape:cy="149.15671"
inkscape:window-width="2560"
inkscape:window-height="1361"
inkscape:window-x="-9"
inkscape:window-y="-9"
inkscape:window-height="1377"
inkscape:window-x="-8"
inkscape:window-y="-8"
inkscape:window-maximized="1"
inkscape:current-layer="g12634" /><g
id="g12634"
inkscape:current-layer="g8" /><g
id="g8"
inkscape:groupmode="layer"
inkscape:label="static"
transform="matrix(1.3333333,0,0,-1.3333333,-82.864623,530.67999)"><path
d="m 76.977,299.76 44.523,-20.85 -0.96,-2.03 -44.517,20.84 z m 44.453,-18.33 4.69,-5.92 -7.55,-0.19 z"
inkscape:label="ch04-graph_19"
transform="matrix(1.3333333,0,0,-1.3333333,-81.082284,530.67999)"><path
d="m 90.417,299.76 44.523,-20.85 -0.96,-2.03 -44.517,20.84 z m 44.453,-18.33 4.69,-5.92 -7.55,-0.19 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path12646" /><g
id="g12648"><g
id="g12650"
clip-path="url(#clipPath12654)"><text
transform="matrix(1,0,0,-1,159.26,278.26)"
id="path20" /><g
id="g22"><g
id="g24"
clip-path="url(#clipPath28)"><text
transform="matrix(1,0,0,-1,172.75,278.26)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:20.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12658"><tspan
id="text32"><tspan
x="0"
y="0"
id="tspan12656">Y</tspan></text></g></g><path
d="m 81.578,233.01 34.612,23.81 -1.28,1.86 -34.608,-23.81 z m 34.952,21.32 3.65,6.61 -7.47,-1.05 z"
id="tspan30">Y</tspan></text></g></g><path
d="m 95.018,233.01 34.612,23.81 -1.28,1.86 -34.608,-23.81 z m 34.952,21.32 3.65,6.61 -7.47,-1.05 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path12660" /><g
id="g12662"><g
id="g12664"
clip-path="url(#clipPath12668)"><text
transform="matrix(1,0,0,-1,63.168,292.25)"
id="path34" /><g
id="g36"><g
id="g38"
clip-path="url(#clipPath42)"><text
transform="matrix(1,0,0,-1,76.68,292.25)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12672"><tspan
id="text46"><tspan
x="0"
y="0"
id="tspan12670">W</tspan></text></g></g><path
d="m 151.26,269.99 27.18,-0.01 v -2.24 h -27.18 z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
id="tspan44">W</tspan></text></g></g><path
d="m 164.7,269.99 h 27.18 v -2.25 H 164.7 Z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path12674" /><g
id="g12676"><g
id="g12678"
clip-path="url(#clipPath12682)"><text
transform="matrix(1,0,0,-1,63.168,227.47)"
id="path48" /><g
id="g50"><g
id="g52"
clip-path="url(#clipPath56)"><text
transform="matrix(1,0,0,-1,76.68,227.47)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12686"><tspan
id="text60"><tspan
x="0"
y="0"
id="tspan12684">A</tspan></text></g></g><path
d="m 125.1,268.86 c 0,7.09 5.86,12.84 13.08,12.84 7.22,0 13.08,-5.75 13.08,-12.84 0,-7.09 -5.86,-12.84 -13.08,-12.84 -7.22,0 -13.08,5.75 -13.08,12.84 z"
id="tspan58">A</tspan></text></g></g><path
d="m 138.54,268.86 c 0,7.09 5.86,12.84 13.08,12.84 7.22,0 13.08,-5.75 13.08,-12.84 0,-7.09 -5.86,-12.84 -13.08,-12.84 -7.22,0 -13.08,5.75 -13.08,12.84 z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path62" /><path
d="m 138.54,268.86 c 0,7.09 5.86,12.84 13.08,12.84 7.22,0 13.08,-5.75 13.08,-12.84 0,-7.09 -5.86,-12.84 -13.08,-12.84 -7.22,0 -13.08,5.75 -13.08,12.84 z"
style="fill:none;stroke:#000000;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12690" /><g
id="g12692"
transform="translate(-1.1347518,-4.5390076)"><g
id="g12694"
clip-path="url(#clipPath12698)"><text
transform="matrix(1,0,0,-1,130.13,257.09)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12702"><tspan
id="path64" /><g
id="g66"><g
id="g68"
clip-path="url(#clipPath72)"><text
transform="matrix(1,0,0,-1,145.06,258.19)"
style="font-variant:normal;font-weight:normal;font-size:32.064px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text76"><tspan
x="0"
y="0"
id="tspan12700">*</tspan></text></g></g><path
d="m 183.3,269.7 c 0,11.07 8.97,20.04 20.04,20.04 11.07,0 20.04,-8.97 20.04,-20.04 0,-11.07 -8.97,-20.04 -20.04,-20.04 -11.07,0 -20.04,8.97 -20.04,20.04 z"
id="tspan74">*</tspan></text></g></g><path
d="m 196.74,269.7 c 0,11.07 9,20.04 20.1,20.04 11.1,0 20.1,-8.97 20.1,-20.04 0,-11.07 -9,-20.04 -20.1,-20.04 -11.1,0 -20.1,8.97 -20.1,20.04 z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path78" /><path
d="m 196.74,269.7 c 0,11.07 9,20.04 20.1,20.04 11.1,0 20.1,-8.97 20.1,-20.04 0,-11.07 -9,-20.04 -20.1,-20.04 -11.1,0 -20.1,8.97 -20.1,20.04 z"
style="fill:none;stroke:#000000;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12706" /><g
id="g12708"><g
id="g12710"
clip-path="url(#clipPath12714)"><text
transform="matrix(1,0,0,-1,187.1,264.62)"
id="path80" /><g
id="g82"><g
id="g84"
clip-path="url(#clipPath88)"><text
transform="matrix(1,0,0,-1,200.59,264.62)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12718"><tspan
id="text92"><tspan
x="0 9.3646803 15.59844 24.12072"
y="0"
sodipodi:role="line"
id="tspan12716">ReLU</tspan></text></g></g><path
d="m 223.38,269.99 27.18,-0.01 v -2.24 h -27.18 z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
id="tspan90">ReLU</tspan></text></g></g><path
d="m 236.94,269.99 h 27.18 v -2.25 h -27.18 z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path12720" /><path
d="m 278.16,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path12722" /><path
d="m 278.16,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12724" /><path
d="m 357.9,196.74 h 87.84 v 147.6 H 357.9 Z"
style="fill:none;stroke:#2f528f;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12726" /><g
id="g12728"><g
id="g12730"
clip-path="url(#clipPath12734)"><text
transform="matrix(1,0,0,-1,369.77,296.23)"
style="font-variant:normal;font-weight:normal;font-size:32.064px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12738"><tspan
x="0 32.040001"
id="path94" /><path
d="m 497.34,319.08 c 0,13.02 10.56,23.58 23.58,23.58 v 0 c 13.02,0 23.58,-10.56 23.58,-23.58 V 218.64 c 0,-13.02 -10.56,-23.58 -23.58,-23.58 v 0 c -13.02,0 -23.58,10.56 -23.58,23.58 z"
style="fill:#b4c7e7;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path96" /><path
d="m 497.34,319.08 c 0,13.02 10.56,23.58 23.58,23.58 v 0 c 13.02,0 23.58,-10.56 23.58,-23.58 V 218.64 c 0,-13.02 -10.56,-23.58 -23.58,-23.58 v 0 c -13.02,0 -23.58,10.56 -23.58,23.58 z"
style="fill:none;stroke:#000000;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path98" /><g
id="g100"><g
id="g102"
clip-path="url(#clipPath106)"><text
transform="matrix(1,0,0,-1,504.84,297.19)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text110"><tspan
x="0"
y="0"
id="tspan108">图</tspan></text></g></g><g
id="g112"><g
id="g114"
clip-path="url(#clipPath118)"><text
transform="matrix(1,0,0,-1,504.84,258.79)"
style="font-variant:normal;font-weight:normal;font-size:32.064px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text122"><tspan
x="0"
y="0"
id="tspan120">优</tspan></text></g></g><g
id="g124"><g
id="g126"
clip-path="url(#clipPath130)"><text
transform="matrix(1,0,0,-1,504.84,220.37)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text134"><tspan
x="0"
y="0"
id="tspan132">化</tspan></text></g></g><path
d="m 613.14,319.08 c 0,13.02 10.56,23.58 23.58,23.58 v 0 c 13.02,0 23.58,-10.56 23.58,-23.58 V 218.64 c 0,-13.02 -10.56,-23.58 -23.58,-23.58 v 0 c -13.02,0 -23.58,10.56 -23.58,23.58 z"
style="fill:#b4c7e7;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path136" /><path
d="m 613.14,319.08 c 0,13.02 10.56,23.58 23.58,23.58 v 0 c 13.02,0 23.58,-10.56 23.58,-23.58 V 218.64 c 0,-13.02 -10.56,-23.58 -23.58,-23.58 v 0 c -13.02,0 -23.58,10.56 -23.58,23.58 z"
style="fill:none;stroke:#000000;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path138" /><g
id="g140"><g
id="g142"
clip-path="url(#clipPath146)"><text
transform="matrix(1,0,0,-1,620.76,277.94)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text150"><tspan
x="0"
y="0"
id="tspan148">执</tspan></text></g></g><g
id="g152"><g
id="g154"
clip-path="url(#clipPath158)"><text
transform="matrix(1,0,0,-1,620.76,239.52)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text162"><tspan
x="0"
y="0"
id="tspan160">行</tspan></text></g></g><g
id="g164"><g
id="g166"
clip-path="url(#clipPath170)"><text
transform="matrix(1,0,0,-1,125.09,342.77)"
style="font-variant:normal;font-weight:normal;font-size:20.04px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text174"><tspan
x="0 20.040001 40.080002 60.119999"
y="0"
sodipodi:role="line"
id="tspan12736">静态</tspan></text></g></g><g
id="g12740"><g
id="g12742"
clip-path="url(#clipPath12746)"><text
transform="matrix(1,0,0,-1,369.77,257.81)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12750"><tspan
x="0 32.040001"
y="0"
sodipodi:role="line"
id="tspan12748">计算</tspan></text></g></g><g
id="g12752"><g
id="g12754"
clip-path="url(#clipPath12758)"><text
transform="matrix(1,0,0,-1,385.85,219.41)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12762"><tspan
x="0"
y="0"
id="tspan12760">图</tspan></text></g></g><path
d="m 469.44,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path12764" /><path
d="m 469.44,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12766" /><path
d="m 558.06,301.26 c 0,24.26 19.66,43.92 43.92,43.92 v 0 c 24.26,0 43.92,-19.66 43.92,-43.92 V 241.5 c 0,-24.26 -19.66,-43.92 -43.92,-43.92 v 0 c -24.26,0 -43.92,19.66 -43.92,43.92 z"
style="fill:none;stroke:#2f528f;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12768" /><g
id="g12770"><g
id="g12772"
clip-path="url(#clipPath12776)"><text
transform="matrix(1,0,0,-1,585.91,297.02)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12780"><tspan
x="0"
y="0"
id="tspan12778">图</tspan></text></g></g><g
id="g12782"><g
id="g12784"
clip-path="url(#clipPath12788)"><text
transform="matrix(1,0,0,-1,585.91,258.62)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12792"><tspan
x="0"
y="0"
id="tspan12790">优</tspan></text></g></g><g
id="g12794"><g
id="g12796"
clip-path="url(#clipPath12800)"><text
transform="matrix(1,0,0,-1,585.91,220.22)"
style="font-variant:normal;font-weight:normal;font-size:32.064px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12804"><tspan
x="0"
y="0"
id="tspan12802">化</tspan></text></g></g><path
d="m 671.16,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path12806" /><path
d="m 671.16,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12808" /><path
d="m 756.42,300.42 c 0,24.26 19.66,43.92 43.92,43.92 v 0 c 24.26,0 43.92,-19.66 43.92,-43.92 v -59.76 c 0,-24.26 -19.66,-43.92 -43.92,-43.92 v 0 c -24.26,0 -43.92,19.66 -43.92,43.92 z"
style="fill:none;stroke:#2f528f;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12810" /><g
id="g12812"><g
id="g12814"
clip-path="url(#clipPath12818)"><text
transform="matrix(1,0,0,-1,784.3,276.84)"
style="font-variant:normal;font-weight:normal;font-size:32.064px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12822"><tspan
x="0"
y="0"
id="tspan12820">执</tspan></text></g></g><g
id="g12824"><g
id="g12826"
clip-path="url(#clipPath12830)"><text
transform="matrix(1,0,0,-1,784.3,238.42)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12834"><tspan
x="0"
y="0"
id="tspan12832">行</tspan></text></g></g><g
id="g12836"><g
id="g12838"
clip-path="url(#clipPath12842)"><text
transform="matrix(1,0,0,-1,95.976,336.1)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12846"><tspan
x="0 32.040001 64.080002 96.120003"
y="0"
sodipodi:role="line"
id="tspan12844">前端定义</tspan></text></g></g><g
id="g12850"><path
id="tspan172">前端定义</tspan></text></g></g><path
d="m 328.5,351.3 h 146.76 v 45.96 H 328.5 Z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path176" /><g
id="g178"><path
d="m 328.5,351.3 h 146.76 v 45.96 H 328.5 Z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:4.5, 1.5;stroke-dashoffset:0;stroke-opacity:1"
id="path12852" /></g><g
id="g12854"><g
id="g12856"
clip-path="url(#clipPath12860)"><text
transform="matrix(1,0,0,-1,341.71,367.08)"
style="font-variant:normal;font-weight:normal;font-size:20.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12864"><tspan
style="fill:none;stroke:#ffffff;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:4.5, 1.5;stroke-dashoffset:0;stroke-opacity:1"
id="path180" /></g><g
id="g182"><g
id="g184"
clip-path="url(#clipPath188)"><text
transform="matrix(1,0,0,-1,341.71,367.68)"
style="font-variant:normal;font-weight:normal;font-size:20.04px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text192"><tspan
x="0 20.040001 40.080002 60.119999 80.160004 100.2"
y="0"
sodipodi:role="line"
id="tspan12862">特殊数据结构</tspan></text></g></g><g
id="g12866"><g
id="g12868"
clip-path="url(#clipPath12872)"><text
transform="matrix(1,0,0,-1,287.3,233.18)"
style="font-variant:normal;font-weight:normal;font-size:20.064px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12876"><tspan
id="tspan190">特殊数据结构</tspan></text></g></g><g
id="g194"><g
id="g196"
clip-path="url(#clipPath200)"><text
transform="matrix(1,0,0,-1,299.78,233.78)"
style="font-variant:normal;font-weight:normal;font-size:20.04px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text204"><tspan
x="0 20.063999"
y="0"
sodipodi:role="line"
id="tspan202">重构</tspan></text></g></g><g
id="g206"><g
id="g208"
clip-path="url(#clipPath212)"><text
transform="matrix(1,0,0,-1,300.79,285.12)"
style="font-variant:normal;font-weight:normal;font-size:20.04px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text216"><tspan
x="0 20.040001"
y="0"
sodipodi:role="line"
id="tspan12874">重构</tspan></text></g></g><g
id="g12878"><g
id="g12880"
clip-path="url(#clipPath12884)"><text
transform="matrix(1,0,0,-1,287.3,284.52)"
style="font-variant:normal;font-weight:normal;font-size:20.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12888"><tspan
x="0 20.040001"
id="tspan214">分析</tspan></text></g></g><path
d="m 367.56,342.04 c 0,2.23 1.81,4.04 4.04,4.04 h 63.8 c 2.23,0 4.04,-1.81 4.04,-4.04 V 195.8 c 0,-2.23 -1.81,-4.04 -4.04,-4.04 h -63.8 c -2.23,0 -4.04,1.81 -4.04,4.04 z"
style="fill:#b3e0b4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path218" /><path
d="m 367.56,342.04 c 0,2.23 1.81,4.04 4.04,4.04 h 63.8 c 2.23,0 4.04,-1.81 4.04,-4.04 V 195.8 c 0,-2.23 -1.81,-4.04 -4.04,-4.04 h -63.8 c -2.23,0 -4.04,1.81 -4.04,4.04 z"
style="fill:none;stroke:#404040;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path220" /><g
id="g222"><g
id="g224"
clip-path="url(#clipPath228)"><text
transform="matrix(1,0,0,-1,379.44,289.63)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text232"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan12886">分析</tspan></text></g></g></g></svg>
id="tspan230">静态</tspan></text></g></g><g
id="g234"><g
id="g236"
clip-path="url(#clipPath240)"><text
transform="matrix(1,0,0,-1,379.44,260.83)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text244"><tspan
x="0 24"
y="0"
sodipodi:role="line"
id="tspan242">计算</tspan></text></g></g><g
id="g246"><g
id="g248"
clip-path="url(#clipPath252)"><text
transform="matrix(1,0,0,-1,391.44,232.01)"
style="font-variant:normal;font-weight:normal;font-size:24px;font-family:DengXian;-inkscape-font-specification:DengXian;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text256"><tspan
x="0"
y="0"
id="tspan254">图</tspan></text></g></g><g
id="g258"><path
d="m 61.32,321 c 0,3.64 2.956,6.6 6.601,6.6 H 267.84 c 3.64,0 6.6,-2.96 6.6,-6.6 V 216.84 c 0,-3.64 -2.96,-6.6 -6.6,-6.6 H 67.921 c -3.645,0 -6.601,2.96 -6.601,6.6 z"
style="fill:none;stroke:#4472c4;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:3, 1;stroke-dashoffset:0;stroke-opacity:1"
id="path260" /></g><path
d="m 274.5,269.61 h 88.06 v -1.5 H 274.5 Z m 87.06,2.25 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path262" /><path
d="m 439.5,269.61 h 49.02 v -1.5 H 439.5 Z m 48.02,2.25 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path264" /><path
d="m 548.34,268.09 50.19,0.13 v 1.5 l -50.19,-0.13 z m 49.2,-2.13 5.99,3.02 -6.01,2.98 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path266" /></g></svg>

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 18 KiB

342
img/ch03/static1.svg Normal file
View File

@@ -0,0 +1,342 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
version="1.1"
id="svg12628"
xml:space="preserve"
width="1044.8153"
height="270.35999"
viewBox="0 0 1044.8153 270.35999"
sodipodi:docname="static.svg"
inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs12632"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12642"><path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path12640" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12654"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12652" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12668"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12666" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12682"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12680" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12698"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12696" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12714"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12712" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12734"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12732" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12746"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12744" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12758"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12756" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12776"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12774" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12788"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12786" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12800"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12798" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12818"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12816" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12830"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12828" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12842"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12840" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12860"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12858" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12872"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12870" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath12884"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path12882" /></clipPath></defs><sodipodi:namedview
id="namedview12630"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
showgrid="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:zoom="1.321875"
inkscape:cx="556.78487"
inkscape:cy="170.59102"
inkscape:window-width="2560"
inkscape:window-height="1361"
inkscape:window-x="-9"
inkscape:window-y="-9"
inkscape:window-maximized="1"
inkscape:current-layer="g12634" /><g
id="g12634"
inkscape:groupmode="layer"
inkscape:label="static"
transform="matrix(1.3333333,0,0,-1.3333333,-82.864623,530.67999)"><path
d="m 76.977,299.76 44.523,-20.85 -0.96,-2.03 -44.517,20.84 z m 44.453,-18.33 4.69,-5.92 -7.55,-0.19 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path12646" /><g
id="g12648"><g
id="g12650"
clip-path="url(#clipPath12654)"><text
transform="matrix(1,0,0,-1,159.26,278.26)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:20.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12658"><tspan
x="0"
y="0"
id="tspan12656">Y</tspan></text></g></g><path
d="m 81.578,233.01 34.612,23.81 -1.28,1.86 -34.608,-23.81 z m 34.952,21.32 3.65,6.61 -7.47,-1.05 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path12660" /><g
id="g12662"><g
id="g12664"
clip-path="url(#clipPath12668)"><text
transform="matrix(1,0,0,-1,63.168,292.25)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12672"><tspan
x="0"
y="0"
id="tspan12670">W</tspan></text></g></g><path
d="m 151.26,269.99 27.18,-0.01 v -2.24 h -27.18 z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path12674" /><g
id="g12676"><g
id="g12678"
clip-path="url(#clipPath12682)"><text
transform="matrix(1,0,0,-1,63.168,227.47)"
style="font-style:italic;font-variant:normal;font-weight:bold;font-size:18px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPS-BoldItalicMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12686"><tspan
x="0"
y="0"
id="tspan12684">A</tspan></text></g></g><path
d="m 125.1,268.86 c 0,7.09 5.86,12.84 13.08,12.84 7.22,0 13.08,-5.75 13.08,-12.84 0,-7.09 -5.86,-12.84 -13.08,-12.84 -7.22,0 -13.08,5.75 -13.08,12.84 z"
style="fill:none;stroke:#000000;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12690" /><g
id="g12692"
transform="translate(-1.1347518,-4.5390076)"><g
id="g12694"
clip-path="url(#clipPath12698)"><text
transform="matrix(1,0,0,-1,130.13,257.09)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12702"><tspan
x="0"
y="0"
id="tspan12700">*</tspan></text></g></g><path
d="m 183.3,269.7 c 0,11.07 8.97,20.04 20.04,20.04 11.07,0 20.04,-8.97 20.04,-20.04 0,-11.07 -8.97,-20.04 -20.04,-20.04 -11.07,0 -20.04,8.97 -20.04,20.04 z"
style="fill:none;stroke:#000000;stroke-width:2.25;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12706" /><g
id="g12708"><g
id="g12710"
clip-path="url(#clipPath12714)"><text
transform="matrix(1,0,0,-1,187.1,264.62)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'Times New Roman';-inkscape-font-specification:TimesNewRomanPSMT;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12718"><tspan
x="0 9.3646803 15.59844 24.12072"
y="0"
sodipodi:role="line"
id="tspan12716">ReLU</tspan></text></g></g><path
d="m 223.38,269.99 27.18,-0.01 v -2.24 h -27.18 z m 26.05,2.25 6.75,-3.38 -6.75,-3.37 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path12720" /><path
d="m 278.16,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path12722" /><path
d="m 278.16,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12724" /><path
d="m 357.9,196.74 h 87.84 v 147.6 H 357.9 Z"
style="fill:none;stroke:#2f528f;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12726" /><g
id="g12728"><g
id="g12730"
clip-path="url(#clipPath12734)"><text
transform="matrix(1,0,0,-1,369.77,296.23)"
style="font-variant:normal;font-weight:normal;font-size:32.064px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12738"><tspan
x="0 32.040001"
y="0"
sodipodi:role="line"
id="tspan12736">静态</tspan></text></g></g><g
id="g12740"><g
id="g12742"
clip-path="url(#clipPath12746)"><text
transform="matrix(1,0,0,-1,369.77,257.81)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12750"><tspan
x="0 32.040001"
y="0"
sodipodi:role="line"
id="tspan12748">计算</tspan></text></g></g><g
id="g12752"><g
id="g12754"
clip-path="url(#clipPath12758)"><text
transform="matrix(1,0,0,-1,385.85,219.41)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12762"><tspan
x="0"
y="0"
id="tspan12760">图</tspan></text></g></g><path
d="m 469.44,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path12764" /><path
d="m 469.44,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12766" /><path
d="m 558.06,301.26 c 0,24.26 19.66,43.92 43.92,43.92 v 0 c 24.26,0 43.92,-19.66 43.92,-43.92 V 241.5 c 0,-24.26 -19.66,-43.92 -43.92,-43.92 v 0 c -24.26,0 -43.92,19.66 -43.92,43.92 z"
style="fill:none;stroke:#2f528f;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12768" /><g
id="g12770"><g
id="g12772"
clip-path="url(#clipPath12776)"><text
transform="matrix(1,0,0,-1,585.91,297.02)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12780"><tspan
x="0"
y="0"
id="tspan12778">图</tspan></text></g></g><g
id="g12782"><g
id="g12784"
clip-path="url(#clipPath12788)"><text
transform="matrix(1,0,0,-1,585.91,258.62)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12792"><tspan
x="0"
y="0"
id="tspan12790">优</tspan></text></g></g><g
id="g12794"><g
id="g12796"
clip-path="url(#clipPath12800)"><text
transform="matrix(1,0,0,-1,585.91,220.22)"
style="font-variant:normal;font-weight:normal;font-size:32.064px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12804"><tspan
x="0"
y="0"
id="tspan12802">化</tspan></text></g></g><path
d="m 671.16,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:#4472c4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path12806" /><path
d="m 671.16,273.78 h 55.08 v 4.86 l 9.72,-9.72 -9.72,-9.72 v 4.86 h -55.08 z"
style="fill:none;stroke:#2f528f;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12808" /><path
d="m 756.42,300.42 c 0,24.26 19.66,43.92 43.92,43.92 v 0 c 24.26,0 43.92,-19.66 43.92,-43.92 v -59.76 c 0,-24.26 -19.66,-43.92 -43.92,-43.92 v 0 c -24.26,0 -43.92,19.66 -43.92,43.92 z"
style="fill:none;stroke:#2f528f;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path12810" /><g
id="g12812"><g
id="g12814"
clip-path="url(#clipPath12818)"><text
transform="matrix(1,0,0,-1,784.3,276.84)"
style="font-variant:normal;font-weight:normal;font-size:32.064px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12822"><tspan
x="0"
y="0"
id="tspan12820">执</tspan></text></g></g><g
id="g12824"><g
id="g12826"
clip-path="url(#clipPath12830)"><text
transform="matrix(1,0,0,-1,784.3,238.42)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12834"><tspan
x="0"
y="0"
id="tspan12832">行</tspan></text></g></g><g
id="g12836"><g
id="g12838"
clip-path="url(#clipPath12842)"><text
transform="matrix(1,0,0,-1,95.976,336.1)"
style="font-variant:normal;font-weight:normal;font-size:32.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12846"><tspan
x="0 32.040001 64.080002 96.120003"
y="0"
sodipodi:role="line"
id="tspan12844">前端定义</tspan></text></g></g><g
id="g12850"><path
d="m 328.5,351.3 h 146.76 v 45.96 H 328.5 Z"
style="fill:none;stroke:#2f528f;stroke-width:1.5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:4.5, 1.5;stroke-dashoffset:0;stroke-opacity:1"
id="path12852" /></g><g
id="g12854"><g
id="g12856"
clip-path="url(#clipPath12860)"><text
transform="matrix(1,0,0,-1,341.71,367.08)"
style="font-variant:normal;font-weight:normal;font-size:20.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12864"><tspan
x="0 20.040001 40.080002 60.119999 80.160004 100.2"
y="0"
sodipodi:role="line"
id="tspan12862">特殊数据结构</tspan></text></g></g><g
id="g12866"><g
id="g12868"
clip-path="url(#clipPath12872)"><text
transform="matrix(1,0,0,-1,287.3,233.18)"
style="font-variant:normal;font-weight:normal;font-size:20.064px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12876"><tspan
x="0 20.040001"
y="0"
sodipodi:role="line"
id="tspan12874">重构</tspan></text></g></g><g
id="g12878"><g
id="g12880"
clip-path="url(#clipPath12884)"><text
transform="matrix(1,0,0,-1,287.3,284.52)"
style="font-variant:normal;font-weight:normal;font-size:20.04px;font-family:'Microsoft YaHei';-inkscape-font-specification:MicrosoftYaHei;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text12888"><tspan
x="0 20.040001"
y="0"
sodipodi:role="line"
id="tspan12886">分析</tspan></text></g></g></g></svg>

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 52 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

View File

@@ -1,321 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
version="1.1"
id="svg765"
xml:space="preserve"
width="573.44"
height="259.83206"
viewBox="0 0 573.44 259.83206"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs769"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath779"><path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path777" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath793"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path791" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath805"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path803" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath821"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path819" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath837"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path835" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath853"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path851" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath869"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path867" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath885"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path883" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath897"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path895" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath913"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path911" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath929"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path927" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath941"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path939" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath957"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path955" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath969"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path967" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath981"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path979" /></clipPath></defs><g
id="g771"
transform="matrix(1.3333333,0,0,-1.3333333,-279.35999,533.43999)"><g
id="g773"><g
id="g775"
clip-path="url(#clipPath779)" /></g><path
d="m 249.72,333.76 c 0,8.59 6.97,15.56 15.56,15.56 h 62.24 c 8.59,0 15.56,-6.97 15.56,-15.56 V 271.4 c 0,-8.59 -6.97,-15.56 -15.56,-15.56 h -62.24 c -8.59,0 -15.56,6.97 -15.56,15.56 z"
style="fill:#a5c3f4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path783" /><path
d="m 249.72,333.76 c 0,8.59 6.97,15.56 15.56,15.56 h 62.24 c 8.59,0 15.56,-6.97 15.56,-15.56 V 271.4 c 0,-8.59 -6.97,-15.56 -15.56,-15.56 h -62.24 c -8.59,0 -15.56,6.97 -15.56,15.56 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path785" /><g
id="g787"><g
id="g789"
clip-path="url(#clipPath793)"><text
transform="matrix(1,0,0,-1,268.61,305.66)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text797"><tspan
x="0 4.8000002 10.776 17.148001 21.84 28.164 32.375999 37.883999 40.644001 47.004002"
y="0"
id="tspan795">TensorFlow</tspan></text></g></g><g
id="g799"><g
id="g801"
clip-path="url(#clipPath805)"><text
transform="matrix(1,0,0,-1,281.45,291.26)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text809"><tspan
x="0 7.5871439 11.518992 17.278488 23.627159"
y="0"
id="tspan807">Graph</tspan></text></g></g><path
d="m 419.04,377.82 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:#a5c3f4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path811" /><path
d="m 419.04,377.82 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path813" /><g
id="g815"><g
id="g817"
clip-path="url(#clipPath821)"><text
transform="matrix(1,0,0,-1,436.1,365.93)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text825"><tspan
x="0 6.2280002 11.268 18.216 20.988001 28.427999 33.228001"
y="0"
id="tspan823">XLA HLO</tspan></text></g></g><path
d="m 419.04,344.1 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:#a5c3f4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path827" /><path
d="m 419.04,344.1 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path829" /><g
id="g831"><g
id="g833"
clip-path="url(#clipPath837)"><text
transform="matrix(1,0,0,-1,433.1,332.18)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text841"><tspan
x="0 4.8000002 10.776 17.148001 21.84 28.164 32.375999 35.015999 41.375999"
y="0"
id="tspan839">Tensor RT</tspan></text></g></g><path
d="m 419.64,310.38 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:#a5c3f4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path843" /><path
d="m 419.64,310.38 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path845" /><g
id="g847"><g
id="g849"
clip-path="url(#clipPath853)"><text
transform="matrix(1,0,0,-1,439.15,298.46)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text857"><tspan
x="0 6.348 13.92 17.868 23.615999 29.976"
y="0"
id="tspan855">nGraph</tspan></text></g></g><path
d="m 419.64,276.66 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:#bfbfbf;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path859" /><path
d="m 419.64,276.66 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path861" /><g
id="g863"><g
id="g865"
clip-path="url(#clipPath869)"><text
transform="matrix(1,0,0,-1,436.99,264.72)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text873"><tspan
x="0 6.3600001 12.684 16.799999 22.775999 25.440001 35.748001"
y="0"
id="tspan871">Core ML</tspan></text></g></g><path
d="m 407.04,242.94 c 0,2.15 1.75,3.9 3.9,3.9 h 92.76 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -92.76 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:#a5c3f4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path875" /><path
d="m 407.04,242.94 c 0,2.15 1.75,3.9 3.9,3.9 h 92.76 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -92.76 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path877" /><g
id="g879"><g
id="g881"
clip-path="url(#clipPath885)"><text
transform="matrix(1,0,0,-1,419.33,230.98)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text889"><tspan
x="0 4.8000002 10.776 17.148001 21.84 28.164 32.375999 37.883999 40.644001 47.004002"
y="0"
id="tspan887">TensorFlow</tspan></text></g></g><g
id="g891"><g
id="g893"
clip-path="url(#clipPath897)"><text
transform="matrix(1,0,0,-1,477.65,230.98)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text901"><tspan
x="0 5.04 7.8000002 11.76"
y="0"
id="tspan899">Lite</tspan></text></g></g><path
d="m 563.88,395.7 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:#94c57e;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path903" /><path
d="m 563.88,395.7 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path905" /><g
id="g907"><g
id="g909"
clip-path="url(#clipPath913)"><text
transform="matrix(1,0,0,-1,582.36,383.78)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text917"><tspan
x="0 5.0500798 9.2344322 16.05204 26.380655 28.905697 31.935743"
y="0"
id="tspan915">LLVM IR</tspan></text></g></g><path
d="m 563.88,364.52 c 0,2.14 1.74,3.88 3.88,3.88 h 67.48 c 2.14,0 3.88,-1.74 3.88,-3.88 V 349 c 0,-2.14 -1.74,-3.88 -3.88,-3.88 h -67.48 c -2.14,0 -3.88,1.74 -3.88,3.88 z"
style="fill:#94c57e;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path919" /><path
d="m 563.88,364.52 c 0,2.14 1.74,3.88 3.88,3.88 h 67.48 c 2.14,0 3.88,-1.74 3.88,-3.88 V 349 c 0,-2.14 -1.74,-3.88 -3.88,-3.88 h -67.48 c -2.14,0 -3.88,1.74 -3.88,3.88 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path921" /><g
id="g923"><g
id="g925"
clip-path="url(#clipPath929)"><text
transform="matrix(1,0,0,-1,585.48,352.63)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text933"><tspan
x="0 5.8439999 12.108 19.812 22.656 25.68"
y="0"
id="tspan931">TPU IR</tspan></text></g></g><g
id="g935"><g
id="g937"
clip-path="url(#clipPath941)"><text
transform="matrix(1,0,0,-1,566.95,325.94)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text945"><tspan
x="0 5.5079999 11.508 16.788 22.764 26.747999 32.495998 35.256001 37.787998 44.112 48.216 54.563999 60.540001 64.524002"
y="0"
id="tspan943">Several others</tspan></text></g></g><path
d="m 563.88,247.5 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:#bfbfbf;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path947" /><path
d="m 563.88,247.5 c 0,2.15 1.75,3.9 3.9,3.9 h 67.44 c 2.15,0 3.9,-1.75 3.9,-3.9 v -15.6 c 0,-2.15 -1.75,-3.9 -3.9,-3.9 h -67.44 c -2.15,0 -3.9,1.75 -3.9,3.9 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path949" /><g
id="g951"><g
id="g953"
clip-path="url(#clipPath957)"><text
transform="matrix(1,0,0,-1,585.6,235.51)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text961"><tspan
x="0 7.7880001 15.576 22.524 28.764"
y="0"
id="tspan959">NNAPI</tspan></text></g></g><g
id="g963"><g
id="g965"
clip-path="url(#clipPath969)"><text
transform="matrix(1,0,0,-1,575.88,207.62)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text973"><tspan
x="0 10.308 16.056 22.188 27.624001 30.108 36.431999 40.535999 46.883999 52.860001 56.844002"
y="0"
id="tspan971">Many others</tspan></text></g></g><g
id="g975"><g
id="g977"
clip-path="url(#clipPath981)"><text
transform="matrix(1,0,0,-1,278.52,367.87)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text985"><tspan
x="0 7.572 11.52 17.268 23.628 29.976 32.736 38.712002"
y="0"
id="tspan983">Grappler</tspan></text></g></g><path
d="m 344.29,326.84 70.66,40.33 -0.5,0.87 -70.66,-40.34 z m 71.03,37.66 3.72,5.58 -6.7,-0.37 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path987" /><path
d="m 343.22,313.83 71.09,20.65 -0.28,0.96 -71.09,-20.65 z m 70.83,17.97 4.92,4.56 -6.6,1.21 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path989" /><path
d="m 343.08,303.14 h 71.54 v -1 h -71.54 z m 70.54,2.5 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path991" /><path
d="m 342.14,291.36 72.86,-20.69 -0.27,-0.96 -72.87,20.69 z m 72.58,-18.01 4.96,-4.52 -6.6,-1.25 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path993" /><path
d="m 343.37,280.25 59.79,-41.89 -0.57,-0.82 -59.8,41.89 z m 60.41,-39.27 3.19,-5.9 -6.63,0.99 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path995" /><path
d="m 209.52,321.26 h 35.22 v -1 h -35.22 z m 34.22,2.5 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path997" /><path
d="m 209.52,303.14 h 35.22 v -1 h -35.22 z m 34.22,2.5 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path999" /><path
d="m 209.52,285.62 h 35.22 v -1 h -35.22 z m 34.22,2.5 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1001" /><path
d="m 306.81,349.92 -2.67,2.43 h 1.22 c -0.85,4.29 -3.8,7.29 -7.18,7.29 h 2.43 c 3.38,0 6.33,-3 7.18,-7.29 H 309 Z"
style="fill:#5b9bd5;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path1003" /><path
d="m 299.39,359.51 c -3.58,-0.78 -6.2,-4.84 -6.2,-9.59 h -2.43 c 0,5.37 3.32,9.72 7.42,9.72 0.4,0 0.81,-0.04 1.21,-0.13 z"
style="fill:#497dab;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path1005" /><path
d="m 299.39,359.51 c -3.58,-0.78 -6.2,-4.84 -6.2,-9.59 h -2.43 c 0,5.37 3.32,9.72 7.42,9.72 h 2.43 c 3.38,0 6.33,-3 7.18,-7.29 H 309 l -2.19,-2.43 -2.67,2.43 h 1.22 c -0.85,4.29 -3.8,7.29 -7.18,7.29"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path1007" /><path
d="m 494.4,369.52 64.73,16.59 -0.25,0.97 -64.72,-16.59 z m 64.38,13.92 5.07,4.4 -6.56,1.42 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1009" /><path
d="m 494.37,370.57 64.66,-12.36 -0.19,-0.98 -64.65,12.36 z m 64.15,-9.71 5.33,-4.08 -6.46,-1.82 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1011" /><path
d="m 494.51,370.52 65.14,-34.16 -0.46,-0.89 -65.14,34.17 z m 65.42,-31.48 3.92,-5.45 -6.71,0.13 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1013" /><path
d="m 507.64,234.6 51.29,4.14 -0.08,1 -51.29,-4.14 z m 50.49,1.57 5.74,3.47 -6.22,2.51 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1015" /><path
d="m 507.79,235.54 51.65,-21.43 -0.38,-0.93 -51.65,21.44 z m 51.69,-18.74 4.39,-5.07 -6.69,-0.47 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1017" /></g></svg>

Before

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

View File

@@ -1,380 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
version="1.1"
id="svg25"
xml:space="preserve"
width="902.39996"
height="387.03998"
viewBox="0 0 902.39996 387.03998"
sodipodi:docname="MindIR.svg"
inkscape:version="1.1.1 (c3084ef, 2021-09-22)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs29"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath39"><path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path37" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath53"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path51" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath69"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path67" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath85"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path83" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath101"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path99" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath117"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path115" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath133"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path131" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath149"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path147" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath165"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path163" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath181"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path179" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath197"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path195" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath213"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path211" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath229"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path227" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath245"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path243" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath261"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path259" /></clipPath></defs><sodipodi:namedview
id="namedview27"
pagecolor="#ffffff"
bordercolor="#cccccc"
borderopacity="1"
inkscape:pageshadow="0"
inkscape:pageopacity="1"
inkscape:pagecheckerboard="0"
showgrid="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:zoom="0.8375"
inkscape:cx="458.50746"
inkscape:cy="275.8209"
inkscape:window-width="1792"
inkscape:window-height="1120"
inkscape:window-x="0"
inkscape:window-y="0"
inkscape:window-maximized="0"
inkscape:current-layer="g31" /><g
id="g31"
inkscape:groupmode="layer"
inkscape:label="9"
transform="matrix(1.3333333,0,0,-1.3333333,-181.92,635.83998)"><path
d="m 422.16,472.08 c 0,2.39 1.93,4.32 4.32,4.32 h 66.6 c 2.39,0 4.32,-1.93 4.32,-4.32 V 454.8 c 0,-2.39 -1.93,-4.32 -4.32,-4.32 h -66.6 c -2.39,0 -4.32,1.93 -4.32,4.32 z"
style="fill:#a5c3f4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path43" /><path
d="m 422.16,472.08 c 0,2.39 1.93,4.32 4.32,4.32 h 66.6 c 2.39,0 4.32,-1.93 4.32,-4.32 V 454.8 c 0,-2.39 -1.93,-4.32 -4.32,-4.32 h -66.6 c -2.39,0 -4.32,1.93 -4.32,4.32 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path45" /><g
id="g47"><g
id="g49"
clip-path="url(#clipPath53)"><text
transform="matrix(1,0,0,-1,437.98,459.36)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text57"><tspan
x="0 6.948 13.2 16.908001 24.695999 31.02 37.403999"
y="0"
sodipodi:role="line"
id="tspan55">AnfNode</tspan></text></g></g><path
d="m 323.16,386.74 c 0,2.6 2.1,4.7 4.7,4.7 h 65.84 c 2.6,0 4.7,-2.1 4.7,-4.7 v -18.8 c 0,-2.6 -2.1,-4.7 -4.7,-4.7 h -65.84 c -2.6,0 -4.7,2.1 -4.7,4.7 z"
style="fill:#a5c3f4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path59" /><path
d="m 323.16,386.74 c 0,2.6 2.1,4.7 4.7,4.7 h 65.84 c 2.6,0 4.7,-2.1 4.7,-4.7 v -18.8 c 0,-2.6 -2.1,-4.7 -4.7,-4.7 h -65.84 c -2.6,0 -4.7,2.1 -4.7,4.7 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path61" /><g
id="g63"><g
id="g65"
clip-path="url(#clipPath69)"><text
transform="matrix(1,0,0,-1,344.09,373.22)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text73"><tspan
x="0 6.9720001 14.784 21.156 27.528"
y="0"
sodipodi:role="line"
id="tspan71">ANode</tspan></text></g></g><path
d="m 512.28,386.68 c 0,2.63 2.13,4.76 4.76,4.76 h 65.72 c 2.63,0 4.76,-2.13 4.76,-4.76 v -19.04 c 0,-2.63 -2.13,-4.76 -4.76,-4.76 h -65.72 c -2.63,0 -4.76,2.13 -4.76,4.76 z"
style="fill:#a5c3f4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path75" /><path
d="m 512.28,386.68 c 0,2.63 2.13,4.76 4.76,4.76 h 65.72 c 2.63,0 4.76,-2.13 4.76,-4.76 v -19.04 c 0,-2.63 -2.13,-4.76 -4.76,-4.76 h -65.72 c -2.63,0 -4.76,2.13 -4.76,4.76 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path77" /><g
id="g79"><g
id="g81"
clip-path="url(#clipPath85)"><text
transform="matrix(1,0,0,-1,533.45,373.08)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text89"><tspan
x="0 6.3606958 14.1282 20.512943 26.861616"
y="0"
sodipodi:role="line"
id="tspan87">CNode</tspan></text></g></g><path
d="m 136.92,302.44 c 0,2.56 2.08,4.64 4.64,4.64 h 86 c 2.56,0 4.64,-2.08 4.64,-4.64 v -18.56 c 0,-2.56 -2.08,-4.64 -4.64,-4.64 h -86 c -2.56,0 -4.64,2.08 -4.64,4.64 z"
style="fill:#a5c3f4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path91" /><path
d="m 136.92,302.44 c 0,2.56 2.08,4.64 4.64,4.64 h 86 c 2.56,0 4.64,-2.08 4.64,-4.64 v -18.56 c 0,-2.56 -2.08,-4.64 -4.64,-4.64 h -86 c -2.56,0 -4.64,2.08 -4.64,4.64 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path93" /><g
id="g95"><g
id="g97"
clip-path="url(#clipPath101)"><text
transform="matrix(1,0,0,-1,145.75,289.06)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text105"><tspan
x="0 6 11.748 15.72 21.468 31.056 36.959999 40.919998 46.896 51.108002 58.896 65.220001 71.603996"
y="0"
sodipodi:role="line"
id="tspan103">ParameterNode</tspan></text></g></g><path
d="m 422.16,302.66 c 0,2.44 1.98,4.42 4.42,4.42 h 66.4 c 2.44,0 4.42,-1.98 4.42,-4.42 v -17.68 c 0,-2.44 -1.98,-4.42 -4.42,-4.42 h -66.4 c -2.44,0 -4.42,1.98 -4.42,4.42 z"
style="fill:#a5c3f4;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path107" /><path
d="m 422.16,302.66 c 0,2.44 1.98,4.42 4.42,4.42 h 66.4 c 2.44,0 4.42,-1.98 4.42,-4.42 v -17.68 c 0,-2.44 -1.98,-4.42 -4.42,-4.42 h -66.4 c -2.44,0 -4.42,1.98 -4.42,4.42 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path109" /><g
id="g111"><g
id="g113"
clip-path="url(#clipPath117)"><text
transform="matrix(1,0,0,-1,433.01,289.7)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text121"><tspan
x="0 6.1199999 11.868 14.628 20.988001 26.964001 34.776001 41.099998 47.484001"
y="0"
sodipodi:role="line"
id="tspan119">ValueNode</tspan></text></g></g><path
d="m 136.92,187.08 h 95.28 v 22.08 h -95.28 z"
style="fill:#7cc2f2;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path123" /><path
d="m 136.92,187.08 h 95.28 v 22.08 h -95.28 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path125" /><g
id="g127"><g
id="g129"
clip-path="url(#clipPath133)"><text
transform="matrix(1,0,0,-1,159,193.99)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text137"><tspan
x="0 6 11.748 15.72 21.468 31.056 36.959999 40.919998 46.896"
y="0"
sodipodi:role="line"
id="tspan135">Parameter</tspan></text></g></g><path
d="m 269.64,187.68 h 54.24 v 21.96 h -54.24 z"
style="fill:#7cc2f2;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path139" /><path
d="m 269.64,187.68 h 54.24 v 21.96 h -54.24 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path141" /><g
id="g143"><g
id="g145"
clip-path="url(#clipPath149)"><text
transform="matrix(1,0,0,-1,282.31,194.5)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text153"><tspan
x="0 5.5190158 10.436832 16.196327 18.961847 24.721344"
y="0"
sodipodi:role="line"
id="tspan151">Scalar</tspan></text></g></g><path
d="m 330.36,187.68 h 54.12 v 21.96 h -54.12 z"
style="fill:#7cc2f2;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path155" /><path
d="m 330.36,187.68 h 54.12 v 21.96 h -54.12 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path157" /><g
id="g159"><g
id="g161"
clip-path="url(#clipPath165)"><text
transform="matrix(1,0,0,-1,339.62,194.5)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text169"><tspan
x="0 7.7675042 13.527 23.134176 29.146175"
y="0"
sodipodi:role="line"
id="tspan167">Named</tspan></text></g></g><path
d="m 390.96,187.08 h 54.12 v 23.04 h -54.12 z"
style="fill:#7cc2f2;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path171" /><path
d="m 390.96,187.08 h 54.12 v 23.04 h -54.12 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path173" /><g
id="g175"><g
id="g177"
clip-path="url(#clipPath181)"><text
transform="matrix(1,0,0,-1,401.83,194.5)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text185"><tspan
x="0 4.797576 10.785528 17.146223 21.847609 28.184256"
y="0"
sodipodi:role="line"
id="tspan183">Tensor</tspan></text></g></g><path
d="m 451.68,187.8 h 54.12 v 23.04 h -54.12 z"
style="fill:#7cc2f2;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path187" /><path
d="m 451.68,187.8 h 54.12 v 23.04 h -54.12 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path189" /><g
id="g191"><g
id="g193"
clip-path="url(#clipPath197)"><text
transform="matrix(1,0,0,-1,467.18,195.14)"
style="font-variant:normal;font-weight:normal;font-size:12.024px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text201"><tspan
x="0 5.2785358 10.677312 17.025984"
y="0"
sodipodi:role="line"
id="tspan199">Type</tspan></text></g></g><path
d="m 512.28,188.16 h 54.12 v 22.92 h -54.12 z"
style="fill:#7cc2f2;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path203" /><path
d="m 512.28,188.16 h 54.12 v 22.92 h -54.12 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path205" /><g
id="g207"><g
id="g209"
clip-path="url(#clipPath213)"><text
transform="matrix(1,0,0,-1,524.35,195.46)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text217"><tspan
x="0 5.5079999 11.868 17.615999 23.976"
y="0"
sodipodi:role="line"
id="tspan215">Shape</tspan></text></g></g><path
d="m 572.88,188.16 h 60.84 v 22.92 h -60.84 z"
style="fill:#7cc2f2;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path219" /><path
d="m 572.88,188.16 h 60.84 v 22.92 h -60.84 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path221" /><g
id="g223"><g
id="g225"
clip-path="url(#clipPath229)"><text
transform="matrix(1,0,0,-1,581.52,195.46)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text233"><tspan
x="0 6.204 10.428 13.188 22.775999 25.535999 29.615999 32.375999 37.655998"
y="0"
sodipodi:role="line"
id="tspan231">Primitive</tspan></text></g></g><path
d="m 640.2,188.16 h 94.08 v 22.92 H 640.2 Z"
style="fill:#7cc2f2;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path235" /><path
d="m 640.2,188.16 h 94.08 v 22.92 H 640.2 Z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path237" /><g
id="g239"><g
id="g241"
clip-path="url(#clipPath245)"><text
transform="matrix(1,0,0,-1,647.74,195.46)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text249"><tspan
x="0 10.308 16.188 20.148001 25.896 31.403999 37.776001 44.124001 49.164001 56.736 60.683998 66.431999 72.683998"
y="0"
sodipodi:role="line"
id="tspan247">MetaFuncGraph</tspan></text></g></g><path
d="m 740.76,188.16 h 72 v 22.92 h -72 z"
style="fill:#7cc2f2;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path251" /><path
d="m 740.76,188.16 h 72 v 22.92 h -72 z"
style="fill:none;stroke:#41719c;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path253" /><g
id="g255"><g
id="g257"
clip-path="url(#clipPath261)"><text
transform="matrix(1,0,0,-1,750.12,195.46)"
style="font-variant:normal;font-weight:normal;font-size:12px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text265"><tspan
x="0 5.5079999 11.868 18.216 23.256001 30.827999 34.776001 40.523998 46.883999"
y="0"
sodipodi:role="line"
id="tspan263">FuncGraph</tspan></text></g></g><path
d="m 459.5,450.91 -94.62,-56.47 0.51,-0.85 94.62,56.46 z m -95.04,-53.81 -3.62,-5.65 6.69,0.5 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path267" /><path
d="m 459.99,450.9 85.98,-56.29 -0.54,-0.84 -85.98,56.29 z m 86.52,-53.65 3.37,-5.8 -6.66,0.78 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path269" /><path
d="m 360.68,363.72 -171.51,-54.6 0.31,-0.95 171.5,54.59 z m -171.31,-51.91 -4.81,-4.68 6.63,-1.04 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path271" /><path
d="m 361.09,363.67 94.57,-53.64 -0.5,-0.87 -94.57,53.65 z m 94.93,-50.97 3.74,-5.57 -6.7,0.35 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path273" /><path
d="m 185.06,279.24 v -65.05 h -1 v 65.05 z m 2.5,-64.05 -3,-6 -3,6 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path275" /><path
d="m 459.53,281.02 -158.38,-68.87 0.39,-0.92 158.39,68.87 z m -158.46,-66.18 -4.31,-5.14 6.7,-0.36 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path277" /><path
d="m 459.4,280.97 -98.21,-68.02 0.56,-0.82 98.22,68.02 z m -98.82,-65.39 -3.22,-5.88 6.64,0.95 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path279" /><path
d="m 460.2,280.69 17.66,-64.9 -0.96,-0.27 -17.66,64.91 z m 19.81,-63.28 -1.32,-6.58 -4.47,5 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path281" /><path
d="m 460.05,280.94 75.85,-66.12 -0.66,-0.76 -75.85,66.12 z m 76.73,-63.58 2.56,-6.21 -6.5,1.69 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path283" /><path
d="m 459.94,281.01 139.08,-67.23 -0.43,-0.9 -139.09,67.23 z m 139.27,-64.54 4.09,-5.31 -6.7,-0.09 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path285" /><path
d="m 459.87,281.04 222.71,-67.95 -0.29,-0.95 -222.72,67.94 z m 222.49,-65.26 4.86,-4.62 -6.61,-1.12 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path287" /><path
d="m 459.83,281.05 312.13,-68.34 -0.22,-0.97 -312.13,68.33 z m 311.68,-65.68 5.22,-4.21 -6.5,-1.65 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path289" /><path
d="m 459.32,280.81 -39.12,-66.07 0.86,-0.51 39.12,66.08 z m -40.76,-63.94 -0.48,-6.69 5.64,3.64 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path291" /></g></svg>

Before

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

View File

@@ -1,364 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
version="1.1"
id="svg915"
xml:space="preserve"
width="993.91998"
height="272.47998"
viewBox="0 0 993.91998 272.47998"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs919"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath929"><path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path927" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath943"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path941" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath955"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path953" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath971"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path969" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath983"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path981" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath999"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path997" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1011"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1009" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1023"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1021" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1039"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1037" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1055"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1053" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1071"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1069" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1087"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1085" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1099"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1097" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1115"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1113" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1127"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1125" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1143"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1141" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1155"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1153" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1167"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1165" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1195"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1193" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath1207"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path1205" /></clipPath></defs><g
id="g921"
transform="matrix(1.3333333,0,0,-1.3333333,-127.84,518.39999)"><path
d="m 96.36,356.4 h 102.96 v 31.92 H 96.36 Z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path933" /><path
d="m 96.36,356.4 h 102.96 v 31.92 H 96.36 Z"
style="fill:none;stroke:#000000;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path935" /><g
id="g937"><g
id="g939"
clip-path="url(#clipPath943)"><text
transform="matrix(1,0,0,-1,109.3,367.39)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text947"><tspan
x="0 14.04 28.08 42.119999 56.16"
y="0"
id="tspan945">源程序语言</tspan></text></g></g><g
id="g949"><g
id="g951"
clip-path="url(#clipPath955)"><text
transform="matrix(1,0,0,-1,179.52,367.39)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text959"><tspan
x="0"
y="0"
id="tspan957">1</tspan></text></g></g><path
d="m 96.36,283.92 h 102.96 v 31.8 H 96.36 Z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path961" /><path
d="m 96.36,283.92 h 102.96 v 31.8 H 96.36 Z"
style="fill:none;stroke:#000000;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path963" /><g
id="g965"><g
id="g967"
clip-path="url(#clipPath971)"><text
transform="matrix(1,0,0,-1,109.3,294.86)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text975"><tspan
x="0 14.04 28.08 42.119999 56.16"
y="0"
id="tspan973">源程序语言</tspan></text></g></g><g
id="g977"><g
id="g979"
clip-path="url(#clipPath983)"><text
transform="matrix(1,0,0,-1,179.52,294.86)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text987"><tspan
x="0"
y="0"
id="tspan985">2</tspan></text></g></g><path
d="m 96.36,184.92 h 102.96 v 31.8 H 96.36 Z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path989" /><path
d="m 96.36,184.92 h 102.96 v 31.8 H 96.36 Z"
style="fill:none;stroke:#000000;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path991" /><g
id="g993"><g
id="g995"
clip-path="url(#clipPath999)"><text
transform="matrix(1,0,0,-1,106.78,195.82)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1003"><tspan
x="0 14.04 28.08 42.119999 56.16"
y="0"
id="tspan1001">源程序语言</tspan></text></g></g><g
id="g1005"><g
id="g1007"
clip-path="url(#clipPath1011)"><text
transform="matrix(1,0,0,-1,176.98,195.82)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1015"><tspan
x="0"
y="0"
id="tspan1013">M</tspan></text></g></g><g
id="g1017"><g
id="g1019"
clip-path="url(#clipPath1023)"><text
transform="matrix(1,0,0,-1,143.04,246.96)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1027"><tspan
x="0"
y="0"
id="tspan1025">…</tspan></text></g></g><path
d="m 277.92,252.12 h 96.24 v 31.8 h -96.24 z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path1029" /><path
d="m 277.92,252.12 h 96.24 v 31.8 h -96.24 z"
style="fill:none;stroke:#000000;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path1031" /><g
id="g1033"><g
id="g1035"
clip-path="url(#clipPath1039)"><text
transform="matrix(1,0,0,-1,312.05,263.04)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1043"><tspan
x="0 14.04"
y="0"
id="tspan1041">前端</tspan></text></g></g><path
d="m 417.12,251.16 h 96.24 v 31.8 h -96.24 z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path1045" /><path
d="m 417.12,251.16 h 96.24 v 31.8 h -96.24 z"
style="fill:none;stroke:#000000;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path1047" /><g
id="g1049"><g
id="g1051"
clip-path="url(#clipPath1055)"><text
transform="matrix(1,0,0,-1,444.19,262.08)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1059"><tspan
x="0 14.04 28.08"
y="0"
id="tspan1057">优化器</tspan></text></g></g><path
d="m 557.16,251.16 h 96.24 v 31.8 h -96.24 z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path1061" /><path
d="m 557.16,251.16 h 96.24 v 31.8 h -96.24 z"
style="fill:none;stroke:#000000;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path1063" /><g
id="g1065"><g
id="g1067"
clip-path="url(#clipPath1071)"><text
transform="matrix(1,0,0,-1,591.26,262.08)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1075"><tspan
x="0 14.04"
y="0"
id="tspan1073">后端</tspan></text></g></g><path
d="m 737.88,356.4 h 102.96 v 31.92 H 737.88 Z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path1077" /><path
d="m 737.88,356.4 h 102.96 v 31.92 H 737.88 Z"
style="fill:none;stroke:#000000;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path1079" /><g
id="g1081"><g
id="g1083"
clip-path="url(#clipPath1087)"><text
transform="matrix(1,0,0,-1,757.78,367.39)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1091"><tspan
x="0 14.04 28.08 42.119999"
y="0"
id="tspan1089">目标机器</tspan></text></g></g><g
id="g1093"><g
id="g1095"
clip-path="url(#clipPath1099)"><text
transform="matrix(1,0,0,-1,813.94,367.39)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1103"><tspan
x="0"
y="0"
id="tspan1101">1</tspan></text></g></g><path
d="m 737.88,284.16 h 102.96 v 31.92 H 737.88 Z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path1105" /><path
d="m 737.88,284.16 h 102.96 v 31.92 H 737.88 Z"
style="fill:none;stroke:#000000;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path1107" /><g
id="g1109"><g
id="g1111"
clip-path="url(#clipPath1115)"><text
transform="matrix(1,0,0,-1,757.78,295.13)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1119"><tspan
x="0 14.04 28.08 42.119999"
y="0"
id="tspan1117">目标机器</tspan></text></g></g><g
id="g1121"><g
id="g1123"
clip-path="url(#clipPath1127)"><text
transform="matrix(1,0,0,-1,813.94,295.13)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1131"><tspan
x="0"
y="0"
id="tspan1129">2</tspan></text></g></g><path
d="m 737.88,184.92 h 102.96 v 31.8 H 737.88 Z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path1133" /><path
d="m 737.88,184.92 h 102.96 v 31.8 H 737.88 Z"
style="fill:none;stroke:#000000;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path1135" /><g
id="g1137"><g
id="g1139"
clip-path="url(#clipPath1143)"><text
transform="matrix(1,0,0,-1,756.82,195.82)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1147"><tspan
x="0 14.04 28.08 42.119999"
y="0"
id="tspan1145">目标机器</tspan></text></g></g><g
id="g1149"><g
id="g1151"
clip-path="url(#clipPath1155)"><text
transform="matrix(1,0,0,-1,812.98,195.82)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1159"><tspan
x="0"
y="0"
id="tspan1157">N</tspan></text></g></g><g
id="g1161"><g
id="g1163"
clip-path="url(#clipPath1167)"><text
transform="matrix(1,0,0,-1,784.56,241.99)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1171"><tspan
x="0"
y="0"
id="tspan1169">…</tspan></text></g></g><path
d="m 199.32,300.38 h 39.76 v -32.34 l -0.5,0.5 h 34.27 v -1 h -34.77 v 32.34 l 0.5,-0.5 h -39.26 z m 72.53,-29.34 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1173" /><path
d="m 374.17,268.46 37.93,-0.84 -0.02,-1 -37.93,0.84 z m 36.98,1.68 5.94,-3.13 -6.07,-2.87 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1175" /><path
d="m 513.36,267.62 h 38.69 v -1 h -38.69 z m 37.69,2.5 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1177" /><path
d="m 653.4,266.58 h 37.63 v 33.54 l -0.5,-0.5 h 42.31 v 1 h -42.81 v -33.54 l 0.5,0.5 H 653.4 Z m 78.44,30.54 6,3 -6,3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1179" /><path
d="m 653.4,259.34 h 23.83 v -58.5 l -0.5,0.5 h 56.16 v -1 h -56.66 v 58.5 l 0.5,-0.5 H 653.4 Z m 78.49,-55.5 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1181" /><path
d="m 199.32,372.86 h 52.15 v -95.13 l -0.5,0.5 h 21.92 v -1 h -22.42 v 95.13 l 0.5,-0.5 h -51.65 z m 72.57,-92.13 6,-3 -6,-3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1183" /><path
d="m 199.32,200.31 h 52.85 v 59.49 l -0.5,-0.5 h 21.18 v 1 h -21.68 v -59.49 l 0.5,0.5 h -52.35 z m 72.53,56.49 6,3 -6,3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1185" /><path
d="m 653.4,275.91 h 21.37 v 92.49 l -0.5,-0.5 h 58.06 v 1 h -58.56 v -92.49 l 0.5,0.5 H 653.4 Z m 77.93,89.49 6,3 -6,3 z"
style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path1187" /><g
id="g1189"><g
id="g1191"
clip-path="url(#clipPath1195)"><text
transform="matrix(1,0,0,-1,390.12,275.09)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1199"><tspan
x="0 3.4800279"
y="0"
id="tspan1197">IR</tspan></text></g></g><g
id="g1201"><g
id="g1203"
clip-path="url(#clipPath1207)"><text
transform="matrix(1,0,0,-1,529.73,273.79)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text1211"><tspan
x="0 3.47998"
y="0"
id="tspan1209">IR</tspan></text></g></g></g></svg>

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

View File

@@ -1,744 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
version="1.1"
id="svg25"
xml:space="preserve"
width="871.03998"
height="274.07776"
viewBox="0 0 871.03998 274.07776"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"><defs
id="defs29"><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath39"><path
d="M 0,1.2207e-4 H 960 V 540.00012 H 0 Z"
clip-rule="evenodd"
id="path37" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath53"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path51" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath65"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path63" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath77"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path75" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath89"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path87" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath101"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path99" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath121"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path119" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath133"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path131" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath145"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path143" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath157"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path155" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath169"><path
d="m 562.56,350.52 h 65.64 v 117.6 h -65.64 z"
clip-rule="evenodd"
id="path167" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath181"><path
d="m 562.56,350.52 h 65.64 v 117.6 h -65.64 z"
clip-rule="evenodd"
id="path179" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath193"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path191" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath205"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path203" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath217"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path215" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath229"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path227" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath241"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path239" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath253"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path251" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath265"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path263" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath277"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path275" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath289"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path287" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath301"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path299" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath313"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path311" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath325"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path323" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath337"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path335" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath349"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path347" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath361"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path359" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath373"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path371" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath385"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path383" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath401"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path399" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath413"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path411" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath425"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path423" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath437"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path435" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath449"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path447" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath461"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path459" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath473"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path471" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath485"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path483" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath497"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path495" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath509"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path507" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath521"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path519" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath533"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path531" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath545"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path543" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath557"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path555" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath569"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path567" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath581"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path579" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath593"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path591" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath605"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path603" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath617"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path615" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath629"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path627" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath641"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path639" /></clipPath><clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath653"><path
d="M 1.4305e-5,0 H 960.00001 V 540 H 1.4305e-5 Z"
clip-rule="evenodd"
id="path651" /></clipPath></defs><g
id="g31"
transform="matrix(1.3333333,0,0,-1.3333333,-182.08,565.27999)"><path
d="m 137.04,401.08 c 0,12.3 9.98,22.28 22.28,22.28 h 89.12 c 12.3,0 22.28,-9.98 22.28,-22.28 V 297.32 c 0,-12.3 -9.98,-22.28 -22.28,-22.28 h -89.12 c -12.3,0 -22.28,9.98 -22.28,22.28 z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path43" /><path
d="m 137.04,401.08 c 0,12.3 9.98,22.28 22.28,22.28 h 89.12 c 12.3,0 22.28,-9.98 22.28,-22.28 V 297.32 c 0,-12.3 -9.98,-22.28 -22.28,-22.28 h -89.12 c -12.3,0 -22.28,9.98 -22.28,22.28 z"
style="fill:none;stroke:#000000;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path45" /><g
id="g47"><g
id="g49"
clip-path="url(#clipPath53)"><text
transform="matrix(1,0,0,-1,167.28,386.38)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text57"><tspan
x="0 9.4499998 18.936001 25.974001 35.478001 39.653999"
y="0"
id="tspan55">push 5</tspan></text></g></g><g
id="g59"><g
id="g61"
clip-path="url(#clipPath65)"><text
transform="matrix(1,0,0,-1,167.28,364.78)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text69"><tspan
x="0 9.4499998 18.936001 25.974001 35.478001 39.653999"
y="0"
id="tspan67">push b</tspan></text></g></g><g
id="g71"><g
id="g73"
clip-path="url(#clipPath77)"><text
transform="matrix(1,0,0,-1,167.28,343.18)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text81"><tspan
x="0 14.382 23.832001 27.972 34.001999 38.034 47.484001 51.624001"
y="0"
id="tspan79">multiply</tspan></text></g></g><g
id="g83"><g
id="g85"
clip-path="url(#clipPath89)"><text
transform="matrix(1,0,0,-1,167.28,321.58)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text93"><tspan
x="0 9.4625998 18.9252 26.026655 35.489258 39.688847"
y="0"
id="tspan91">push a</tspan></text></g></g><g
id="g95"><g
id="g97"
clip-path="url(#clipPath101)"><text
transform="matrix(1,0,0,-1,167.28,299.95)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text105"><tspan
x="0 7.0380001 16.542 25.902 32.742001 38.771999 44.622002 53.243999 60.858002"
y="0"
id="tspan103">substract</tspan></text></g></g><path
d="M 388.54,421.84 V 274.53"
style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path107" /><path
d="M 628.19,421.84 V 274.53"
style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path109" /><path
d="M 388.04,421.34 H 628.69"
style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path111" /><path
d="M 388.04,275.03 H 628.69"
style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path113" /><g
id="g115"><g
id="g117"
clip-path="url(#clipPath121)"><text
transform="matrix(1,0,0,-1,398.69,404.4)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text125"><tspan
x="0 14.04"
y="0"
id="tspan123">目标</tspan></text></g></g><g
id="g127"><g
id="g129"
clip-path="url(#clipPath133)"><text
transform="matrix(1,0,0,-1,445.73,404.4)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text137"><tspan
x="0 14.04 28.08"
y="0"
id="tspan135">运算符</tspan></text></g></g><g
id="g139"><g
id="g141"
clip-path="url(#clipPath145)"><text
transform="matrix(1,0,0,-1,505.01,404.4)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text149"><tspan
x="0 14.04 28.08"
y="0"
id="tspan147">操作数</tspan></text></g></g><g
id="g151"><g
id="g153"
clip-path="url(#clipPath157)"><text
transform="matrix(1,0,0,-1,547.13,404.4)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text161"><tspan
x="0"
y="0"
id="tspan159">1</tspan></text></g></g><g
id="g163"><g
id="g165"
clip-path="url(#clipPath169)"><text
transform="matrix(1,0,0,-1,570.86,404.4)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text173"><tspan
x="0 14.04 28.08"
y="0"
id="tspan171">操作数</tspan></text></g></g><g
id="g175"><g
id="g177"
clip-path="url(#clipPath181)"><text
transform="matrix(1,0,0,-1,613.01,404.4)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text185"><tspan
x="0"
y="0"
id="tspan183">2</tspan></text></g></g><g
id="g187"><g
id="g189"
clip-path="url(#clipPath193)"><text
transform="matrix(1,0,0,-1,406.85,380.23)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text197"><tspan
x="0 4.6799998"
y="0"
id="tspan195">t1</tspan></text></g></g><g
id="g199"><g
id="g201"
clip-path="url(#clipPath205)"><text
transform="matrix(1,0,0,-1,460.37,380.23)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text209"><tspan
x="0"
y="0"
id="tspan207">←</tspan></text></g></g><g
id="g211"><g
id="g213"
clip-path="url(#clipPath217)"><text
transform="matrix(1,0,0,-1,526.01,380.23)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text221"><tspan
x="0"
y="0"
id="tspan219">5</tspan></text></g></g><g
id="g223"><g
id="g225"
clip-path="url(#clipPath229)"><text
transform="matrix(1,0,0,-1,406.85,355.85)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text233"><tspan
x="0 4.6799998"
y="0"
id="tspan231">t2</tspan></text></g></g><g
id="g235"><g
id="g237"
clip-path="url(#clipPath241)"><text
transform="matrix(1,0,0,-1,460.37,355.85)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text245"><tspan
x="0"
y="0"
id="tspan243">←</tspan></text></g></g><g
id="g247"><g
id="g249"
clip-path="url(#clipPath253)"><text
transform="matrix(1,0,0,-1,525.89,355.85)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text257"><tspan
x="0"
y="0"
id="tspan255">b</tspan></text></g></g><g
id="g259"><g
id="g261"
clip-path="url(#clipPath265)"><text
transform="matrix(1,0,0,-1,406.85,331.46)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text269"><tspan
x="0 4.6800399"
y="0"
id="tspan267">t3</tspan></text></g></g><g
id="g271"><g
id="g273"
clip-path="url(#clipPath277)"><text
transform="matrix(1,0,0,-1,459.77,331.22)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text281"><tspan
x="0"
y="0"
id="tspan279">×</tspan></text></g></g><g
id="g283"><g
id="g285"
clip-path="url(#clipPath289)"><text
transform="matrix(1,0,0,-1,523.73,331.46)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text293"><tspan
x="0 4.6800399"
y="0"
id="tspan291">t1</tspan></text></g></g><g
id="g295"><g
id="g297"
clip-path="url(#clipPath301)"><text
transform="matrix(1,0,0,-1,589.61,331.46)"
style="font-variant:normal;font-weight:normal;font-size:14.064px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text305"><tspan
x="0 4.6800399"
y="0"
id="tspan303">t2</tspan></text></g></g><g
id="g307"><g
id="g309"
clip-path="url(#clipPath313)"><text
transform="matrix(1,0,0,-1,406.85,307.06)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text317"><tspan
x="0 4.6799998"
y="0"
id="tspan315">t4</tspan></text></g></g><g
id="g319"><g
id="g321"
clip-path="url(#clipPath325)"><text
transform="matrix(1,0,0,-1,460.37,307.06)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text329"><tspan
x="0"
y="0"
id="tspan327">←</tspan></text></g></g><g
id="g331"><g
id="g333"
clip-path="url(#clipPath337)"><text
transform="matrix(1,0,0,-1,526.25,307.06)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text341"><tspan
x="0"
y="0"
id="tspan339">a</tspan></text></g></g><g
id="g343"><g
id="g345"
clip-path="url(#clipPath349)"><text
transform="matrix(1,0,0,-1,406.85,282.67)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text353"><tspan
x="0 4.6799998"
y="0"
id="tspan351">t5</tspan></text></g></g><g
id="g355"><g
id="g357"
clip-path="url(#clipPath361)"><text
transform="matrix(1,0,0,-1,464.57,282.67)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text365"><tspan
x="0"
y="0"
id="tspan363">-</tspan></text></g></g><g
id="g367"><g
id="g369"
clip-path="url(#clipPath373)"><text
transform="matrix(1,0,0,-1,523.73,282.67)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text377"><tspan
x="0 4.6799998"
y="0"
id="tspan375">t4</tspan></text></g></g><g
id="g379"><g
id="g381"
clip-path="url(#clipPath385)"><text
transform="matrix(1,0,0,-1,589.61,282.67)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text389"><tspan
x="0 4.6799998"
y="0"
id="tspan387">t3</tspan></text></g></g><path
d="m 650.52,400.34 c 0,12.78 10.36,23.14 23.14,23.14 h 92.56 c 12.78,0 23.14,-10.36 23.14,-23.14 V 298.18 c 0,-12.78 -10.36,-23.14 -23.14,-23.14 h -92.56 c -12.78,0 -23.14,10.36 -23.14,23.14 z"
style="fill:#ffffff;fill-opacity:1;fill-rule:evenodd;stroke:none"
id="path391" /><path
d="m 650.52,400.34 c 0,12.78 10.36,23.14 23.14,23.14 h 92.56 c 12.78,0 23.14,-10.36 23.14,-23.14 V 298.18 c 0,-12.78 -10.36,-23.14 -23.14,-23.14 h -92.56 c -12.78,0 -23.14,10.36 -23.14,23.14 z"
style="fill:none;stroke:#000000;stroke-width:0.96;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:8;stroke-dasharray:none;stroke-opacity:1"
id="path393" /><g
id="g395"><g
id="g397"
clip-path="url(#clipPath401)"><text
transform="matrix(1,0,0,-1,676.94,386.04)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text405"><tspan
x="0 6.0300002 15.156"
y="0"
id="tspan403">t1 </tspan></text></g></g><g
id="g407"><g
id="g409"
clip-path="url(#clipPath413)"><text
transform="matrix(1,0,0,-1,696.26,386.04)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text417"><tspan
x="0"
y="0"
id="tspan415">←</tspan></text></g></g><g
id="g419"><g
id="g421"
clip-path="url(#clipPath425)"><text
transform="matrix(1,0,0,-1,716.54,386.04)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text429"><tspan
x="0"
y="0"
id="tspan427">5</tspan></text></g></g><g
id="g431"><g
id="g433"
clip-path="url(#clipPath437)"><text
transform="matrix(1,0,0,-1,676.94,364.8)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text441"><tspan
x="0 6.0300002 15.156"
y="0"
id="tspan439">t2 </tspan></text></g></g><g
id="g443"><g
id="g445"
clip-path="url(#clipPath449)"><text
transform="matrix(1,0,0,-1,696.26,364.8)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text453"><tspan
x="0"
y="0"
id="tspan451">←</tspan></text></g></g><g
id="g455"><g
id="g457"
clip-path="url(#clipPath461)"><text
transform="matrix(1,0,0,-1,716.54,364.8)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text465"><tspan
x="0"
y="0"
id="tspan463">b</tspan></text></g></g><g
id="g467"><g
id="g469"
clip-path="url(#clipPath473)"><text
transform="matrix(1,0,0,-1,676.94,342.84)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text477"><tspan
x="0 6.0300002 15.156"
y="0"
id="tspan475">t3 </tspan></text></g></g><g
id="g479"><g
id="g481"
clip-path="url(#clipPath485)"><text
transform="matrix(1,0,0,-1,696.26,342.84)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text489"><tspan
x="0"
y="0"
id="tspan487">←</tspan></text></g></g><g
id="g491"><g
id="g493"
clip-path="url(#clipPath497)"><text
transform="matrix(1,0,0,-1,716.54,342.84)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text501"><tspan
x="0 6"
y="0"
id="tspan499">t1</tspan></text></g></g><g
id="g503"><g
id="g505"
clip-path="url(#clipPath509)"><text
transform="matrix(1,0,0,-1,731.66,342.84)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text513"><tspan
x="0"
y="0"
id="tspan511">×</tspan></text></g></g><g
id="g515"><g
id="g517"
clip-path="url(#clipPath521)"><text
transform="matrix(1,0,0,-1,749.66,342.84)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text525"><tspan
x="0 6"
y="0"
id="tspan523">t2</tspan></text></g></g><g
id="g527"><g
id="g529"
clip-path="url(#clipPath533)"><text
transform="matrix(1,0,0,-1,676.94,321.6)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text537"><tspan
x="0 6.0380402 15.122136"
y="0"
id="tspan535">t4 </tspan></text></g></g><g
id="g539"><g
id="g541"
clip-path="url(#clipPath545)"><text
transform="matrix(1,0,0,-1,696.26,321.6)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text549"><tspan
x="0"
y="0"
id="tspan547">←</tspan></text></g></g><g
id="g551"><g
id="g553"
clip-path="url(#clipPath557)"><text
transform="matrix(1,0,0,-1,716.54,321.6)"
style="font-variant:normal;font-weight:normal;font-size:18.024px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text561"><tspan
x="0"
y="0"
id="tspan559">a</tspan></text></g></g><g
id="g563"><g
id="g565"
clip-path="url(#clipPath569)"><text
transform="matrix(1,0,0,-1,676.94,299.98)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text573"><tspan
x="0 6.0300002 15.156"
y="0"
id="tspan571">t5 </tspan></text></g></g><g
id="g575"><g
id="g577"
clip-path="url(#clipPath581)"><text
transform="matrix(1,0,0,-1,696.26,299.98)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text585"><tspan
x="0"
y="0"
id="tspan583">←</tspan></text></g></g><g
id="g587"><g
id="g589"
clip-path="url(#clipPath593)"><text
transform="matrix(1,0,0,-1,716.54,299.98)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text597"><tspan
x="0 6.0300002 15.156"
y="0"
id="tspan595">t4 </tspan></text></g></g><g
id="g599"><g
id="g601"
clip-path="url(#clipPath605)"><text
transform="matrix(1,0,0,-1,735.86,299.98)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text609"><tspan
x="0"
y="0"
id="tspan607">–</tspan></text></g></g><g
id="g611"><g
id="g613"
clip-path="url(#clipPath617)"><text
transform="matrix(1,0,0,-1,748.94,299.98)"
style="font-variant:normal;font-weight:normal;font-size:18px;font-family:Calibri;-inkscape-font-specification:Calibri;writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text621"><tspan
x="0 6"
y="0"
id="tspan619">t3</tspan></text></g></g><g
id="g623"><g
id="g625"
clip-path="url(#clipPath629)"><text
transform="matrix(1,0,0,-1,171.38,219.43)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text633"><tspan
x="0 14.04"
y="0"
id="tspan631">堆栈</tspan></text></g></g><g
id="g635"><g
id="g637"
clip-path="url(#clipPath641)"><text
transform="matrix(1,0,0,-1,199.46,219.43)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text645"><tspan
x="0 14.04 28.08"
y="0"
id="tspan643">机代码</tspan></text></g></g><g
id="g647"><g
id="g649"
clip-path="url(#clipPath653)"><text
transform="matrix(1,0,0,-1,570.7,219.43)"
style="font-variant:normal;font-weight:normal;font-size:14.04px;font-family:'宋体';-inkscape-font-specification:'宋体';writing-mode:lr-tb;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="text657"><tspan
x="0 14.04 28.08 42.119999 56.16"
y="0"
id="tspan655">三地址代码</tspan></text></g></g></g></svg>

Before

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 222 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 183 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 221 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 260 KiB

BIN
img/ch13/ROS2_arch.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 147 KiB

BIN
img/ch13/idm.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 636 KiB

BIN
img/ch13/orbslam3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 254 KiB

BIN
img/ch13/rl_ad.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 121 KiB

BIN
img/ch13/ros2_actions.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 180 KiB

BIN
img/ch13/ros2_graph.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 112 KiB

BIN
img/ch13/ros2_services.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 70 KiB

BIN
img/ch13/ros2_topics.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 72 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 167 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

View File

@@ -24,6 +24,7 @@ chapter_recommender_system/index
chapter_federated_learning/index
chapter_reinforcement_learning/index
chapter_explainable_AI/index
chapter_rl_sys/index
```
@@ -32,4 +33,4 @@ chapter_explainable_AI/index
appendix_machine_learning_introduction/index
chapter_references/index
```
```

Binary file not shown.

View File

@@ -0,0 +1,12 @@
## 书籍图片制作模板
为了保证图书中图片尽量统一,我们输出了图形的基础模板,包括色系、线条、箭头、框图等流程图常用的模块。
大家可以根据自己绘制流程图的需求,选择合适的组件进行绘制。为了方便大家作图,我们以PPT的形式提供给大家,不需要开发者掌握单独的作图工具。
使用的简单流程如下:
1、梳理流程图的逻辑。
2、使用PPT中的模板进行绘制。
3、通过PPT导出图片,建议为png格式。
4、将导出后的图片放到相应img目录相应的章节,在文档中进行引用。

View File

@@ -36,7 +36,9 @@
第13章 - 可解释性AI系统:[@HaoyangLee](https://github.com/HaoyangLee)
附录:机器学习介绍:[@zsdonghao](https://github.com/zsdonghao)
第14章 - 机器人学习系统:[@HaoyangLee](https://github.com/HaoyangLee)
附录:机器学习介绍:[@Jack](https://github.com/Jiankai-Sun)
## 加入我们

View File

@@ -1,7 +1,7 @@
## 环境安装
机器学习系统书籍部署在Github是依赖于d2lbook工具实现的。因此我们首先要安装d2lbook。
```bash
git clone git@github.com:d2l-ai/d2l-book.git
git clone https://github.com/openmlsys/d2l-book.git
cd d2l-book
python setup.py install
```
@@ -12,7 +12,7 @@ python setup.py install
## 编译HTML版本
在编译前先下载[openmlsys-zh](https://github.com/openmlsys/openmlsys-zh) 所有的编译命令都在改文件目录内执行。
```bash
git clone git@github.com:openmlsys/openmlsys-zh.git
git clone https://github.com/openmlsys/openmlsys-zh.git
cd openmlsys-zh
```
使用d2lbook工具编译HTML。

668
mlsys.bib
View File

@@ -439,6 +439,15 @@ series = {ADKDD'14}
note = {\url{http://www.nvidia.com/object/volta-architecture-whitepaper.html}}
}
@inproceedings{2021Ascend,
title={Ascend: a Scalable and Unified Architecture for Ubiquitous Deep Neural Network Computing : Industry Track Paper},
author={Liao, Heng and Tu, Jiajin and Xia, Jing and Liu, Hu and Zhou, Xiping and Yuan, Honghui and Hu, Yuxing},
booktitle={2021 IEEE International Symposium on High-Performance Computer Architecture (HPCA)},
year={2021},
pages = {789–801},
doi = {10.1109/HPCA51647.2021.00071},
}
@article{2018Modeling,
title={Modeling Deep Learning Accelerator Enabled GPUs},
author={Raihan, M. A. and Goli, N. and Aamodt, T.},
@@ -739,6 +748,89 @@ location = {Halifax, NS, Canada},
series = {ADKDD'17}
}
@inproceedings{fedavg,
author = {Brendan McMahan and
Eider Moore and
Daniel Ramage and
Seth Hampson and
Blaise Ag{\"{u}}era y Arcas},
title = {Communication-Efficient Learning of Deep Networks from Decentralized
Data},
booktitle = {Proceedings of the 20th International Conference on Artificial Intelligence
and Statistics, {AISTATS} 2017, 20-22 April 2017, Fort Lauderdale,
FL, {USA}},
series = {Proceedings of Machine Learning Research},
volume = {54},
pages = {1273--1282},
publisher = {{PMLR}},
year = {2017},
url = {http://proceedings.mlr.press/v54/mcmahan17a.html},
}
@inproceedings{scaffold,
title={Scaffold: Stochastic controlled averaging for federated learning},
author={Karimireddy, Sai Praneeth and Kale, Satyen and Mohri, Mehryar and Reddi, Sashank and Stich, Sebastian and Suresh, Ananda Theertha},
booktitle={International Conference on Machine Learning},
pages={5132--5143},
year={2020},
organization={PMLR}
}
@article{FedDF,
title={Ensemble distillation for robust model fusion in federated learning},
author={Lin, Tao and Kong, Lingjing and Stich, Sebastian U and Jaggi, Martin},
journal={Advances in Neural Information Processing Systems},
volume={33},
pages={2351--2363},
year={2020}
}
@inproceedings{PATE,
author = {Nicolas Papernot and
Mart{\'{\i}}n Abadi and
{\'{U}}lfar Erlingsson and
Ian J. Goodfellow and
Kunal Talwar},
title = {Semi-supervised Knowledge Transfer for Deep Learning from Private
Training Data},
booktitle = {5th International Conference on Learning Representations, {ICLR} 2017,
Toulon, France, April 24-26, 2017, Conference Track Proceedings},
publisher = {OpenReview.net},
year = {2017},
}
@inproceedings{FedProx,
title={Federated optimization in heterogeneous networks},
author={Li, Tian and Sahu, Anit Kumar and Zaheer, Manzil and Sanjabi, Maziar and Talwalkar, Ameet and Smith, Virginia},
booktitle={Proceedings of Machine Learning and Systems},
volume={2},
pages={429--450},
year={2020}
}
@inproceedings{FedBE,
author = {Hong{-}You Chen and
Wei{-}Lun Chao},
title = {FedBE: Making Bayesian Model Ensemble Applicable to Federated Learning},
booktitle = {9th International Conference on Learning Representations, {ICLR} 2021,
Virtual Event, Austria, May 3-7, 2021},
year = {2021},
}
@article{FedAvg_Momentum,
author = {Tzu{-}Ming Harry Hsu and
Hang Qi and
Matthew Brown},
title = {Measuring the Effects of Non-Identical Data Distribution for Federated
Visual Classification},
journal = {CoRR},
volume = {abs/1909.06335},
year = {2019},
url = {http://arxiv.org/abs/1909.06335},
eprinttype = {arXiv},
eprint = {1909.06335},
}
@inproceedings{ijcai2017-239,
author = {Huifeng Guo and Ruiming TANG and Yunming Ye and Zhenguo Li and Xiuqiang He},
title = {DeepFM: A Factorization-Machine based Neural Network for CTR Prediction},
@@ -835,4 +927,578 @@ series = {PPoPP '21}
doi = "10.18653/v1/2021.naacl-industry.15",
pages = "113--120",
abstract = "Transformer and its variants have achieved great success in natural language processing. Since Transformer models are huge in size, serving these models is a challenge for real industrial applications. In this paper, we propose , a highly efficient inference library for models in the Transformer family. includes a series of GPU optimization techniques to both streamline the computation of Transformer layers and reduce memory footprint. supports models trained using PyTorch and Tensorflow. Experimental results on standard machine translation benchmarks show that achieves up to 14x speedup compared with TensorFlow and 1.4x speedup compared with , a concurrent CUDA implementation. The code will be released publicly after the review.",
}
}
@article{jiang2022signds,
title={SignDS-FL: Local Differentially Private Federated Learning with Sign-based Dimension Selection},
author={Jiang, Xue and Zhou, Xuebing and Grossklags, Jens},
journal={ACM Transactions on Intelligent Systems and Technology (TIST)},
year={2022},
publisher = {Association for Computing Machinery},
address = {New York, USA}
}
@article{dwork2014algorithmic,
title={The algorithmic foundations of differential privacy},
author={Dwork, Cynthia and Roth, Aaron},
journal={Foundations and Trends in Theoretical Computer Science},
volume={9},
number={3--4},
pages={211--407},
year={2014},
}
@inproceedings{mcsherry2007mechanism,
title={Mechanism design via differential privacy},
author={McSherry, Frank and Talwar, Kunal},
booktitle={IEEE Symposium on Foundations of Computer Science},
pages={94--103},
year={2007},
}
@inproceedings{quigley2009ros,
title={ROS: an open-source Robot Operating System},
author={Quigley, Morgan and Conley, Ken and Gerkey, Brian and Faust, Josh and Foote, Tully and Leibs, Jeremy and Wheeler, Rob and Ng, Andrew Y and others},
booktitle={ICRA workshop on open source software},
volume={3},
number={3.2},
pages={5},
year={2009},
organization={Kobe, Japan}
}
@inproceedings{maruyama2016exploring,
title={Exploring the performance of ROS2},
author={Maruyama, Yuya and Kato, Shinpei and Azumi, Takuya},
booktitle={Proceedings of the 13th ACM SIGBED International Conference on Embedded Software (EMSOFT)},
pages={1--10},
year={2016}
}
@inproceedings{ding2019camnet,
title={CamNet: Coarse-to-fine retrieval for camera re-localization},
author={Ding, Mingyu and Wang, Zhe and Sun, Jiankai and Shi, Jianping and Luo, Ping},
booktitle={Proceedings of the IEEE/CVF International Conference on Computer Vision},
pages={2871--2880},
year={2019}
}
@inproceedings{yi2020segvoxelnet,
title={Segvoxelnet: Exploring semantic context and depth-aware features for 3d vehicle detection from point cloud},
author={Yi, Hongwei and Shi, Shaoshuai and Ding, Mingyu and Sun, Jiankai and Xu, Kui and Zhou, Hui and Wang, Zhe and Li, Sheng and Wang, Guoping},
booktitle={2020 IEEE International Conference on Robotics and Automation (ICRA)},
pages={2274--2280},
year={2020},
organization={IEEE}
}
@ARTICLE{9712373, author={Sun, Jiankai and Huang, De-An and Lu, Bo and Liu, Yun-Hui and Zhou, Bolei and Garg, Animesh}, journal={IEEE Robotics and Automation Letters}, title={PlaTe: Visually-Grounded Planning With Transformers in Procedural Tasks}, year={2022}, volume={7}, number={2}, pages={4924-4930}, doi={10.1109/LRA.2022.3150855}}
@inproceedings{li2018undeepvo,
title={Undeepvo: Monocular visual odometry through unsupervised deep learning},
author={Li, Ruihao and Wang, Sen and Long, Zhiqiang and Gu, Dongbing},
booktitle={2018 IEEE international conference on robotics and automation (ICRA)},
pages={7286--7291},
year={2018},
organization={IEEE}
}
@inproceedings{quintero2021motion,
title={Motion planning via bayesian learning in the dark},
author={Quintero-Pena, Carlos and Chamzas, Constantinos and Unhelkar, Vaibhav and Kavraki, Lydia E},
booktitle={ICRA: Workshop on Machine Learning for Motion Planning},
year={2021}
}
@MISC{ML4KP,
author = {Edgar Granados and Aravind Sivaramakrishnan and Troy McMahon and Zakary Littlefield and Kostas E. Bekris},
title = {Machine Learning for Kinodynamic Planning (ML4KP)},
howpublished = {\url{https://github.com/PRX-Kinodynamic/ML4KP}},
year = {2021--2021}
}
@article{kadubandimotion,
title={Motion Planner Guided Visuomotor Policy Learning},
author={Kadubandi, Venkata Pradeep and Salhotra, Gautam and Sukhatme, Gaurav S and Englert, Peter}
}
@article{jangdeep,
title={Deep Neural Network-based Fast Motion Planning Framework for Quadrupedal Robot},
author={Jang, Jinhyeok and Shin, Heechan and Yoon, Minsung and Hong, Seungwoo and Park, Hae-Won and Yoon, Sung-Eui}
}
@article{aradi2020survey,
title={Survey of deep reinforcement learning for motion planning of autonomous vehicles},
author={Aradi, Szil{\'a}rd},
journal={IEEE Transactions on Intelligent Transportation Systems},
year={2020},
publisher={IEEE}
}
@article{vianna2021neural,
title={Neural Network Based Model Predictive Control for an Autonomous Vehicle},
author={Vianna, Maria Luiza Costa and Goubault, Eric and Putot, Sylvie},
journal={arXiv preprint arXiv:2107.14573},
year={2021}
}
@article{tartanvo2020corl,
title = {TartanVO: A Generalizable Learning-based VO},
author = {Wang, Wenshan and Hu, Yaoyu and Scherer, Sebastian},
booktitle = {Conference on Robot Learning (CoRL)},
year = {2020}
}
@article{qiu2021egocentric,
title={Egocentric Human Trajectory Forecasting with a Wearable Camera and Multi-Modal Fusion},
author={Qiu, Jianing and Chen, Lipeng and Gu, Xiao and Lo, Frank P-W and Tsai, Ya-Yen and Sun, Jiankai and Liu, Jiaqi and Lo, Benny},
journal={arXiv preprint arXiv:2111.00993},
year={2021}
}
@InProceedings{pmlr-v155-huang21a,
title = {Learning a Decision Module by Imitating Driver’s Control Behaviors},
author = {Huang, Junning and Xie, Sirui and Sun, Jiankai and Ma, Qiurui and Liu, Chunxiao and Lin, Dahua and Zhou, Bolei},
booktitle = {Proceedings of the 2020 Conference on Robot Learning},
pages = {1--10},
year = {2021},
editor = {Kober, Jens and Ramos, Fabio and Tomlin, Claire},
volume = {155},
series = {Proceedings of Machine Learning Research},
month = {16--18 Nov},
publisher = {PMLR},
pdf = {https://proceedings.mlr.press/v155/huang21a/huang21a.pdf},
url = {https://proceedings.mlr.press/v155/huang21a.html},
abstract = {Autonomous driving systems have a pipeline of perception, decision, planning, and control. The decision module processes information from the perception module and directs the execution of downstream planning and control modules. On the other hand, the recent success of deep learning suggests that this pipeline could be replaced by end-to-end neural control policies, however, safety cannot be well guaranteed for the data-driven neural networks. In this work, we propose a hybrid framework to learn neural decisions in the classical modular pipeline through end-to-end imitation learning. This hybrid framework can preserve the merits of the classical pipeline such as the strict enforcement of physical and logical constraints while learning complex driving decisions from data. To circumvent the ambiguous annotation of human driving decisions, our method learns high-level driving decisions by imitating low-level control behaviors. We show in the simulation experiments that our modular driving agent can generalize its driving decision and control to various complex scenarios where the rule-based programs fail. It can also generate smoother and safer driving trajectories than end-to-end neural policies. Demo and code are available at https://decisionforce.github.io/modulardecision/.}
}
@InProceedings{pmlr-v155-sun21a,
title = {Neuro-Symbolic Program Search for Autonomous Driving Decision Module Design},
author = {Sun, Jiankai and Sun, Hao and Han, Tian and Zhou, Bolei},
booktitle = {Proceedings of the 2020 Conference on Robot Learning},
pages = {21--30},
year = {2021},
editor = {Kober, Jens and Ramos, Fabio and Tomlin, Claire},
volume = {155},
series = {Proceedings of Machine Learning Research},
month = {16--18 Nov},
publisher = {PMLR},
pdf = {https://proceedings.mlr.press/v155/sun21a/sun21a.pdf},
url = {https://proceedings.mlr.press/v155/sun21a.html},
abstract = {As a promising topic in cognitive robotics, neuro-symbolic modeling integrates symbolic reasoning and neural representation altogether. However, previous neuro-symbolic models usually wire their structures and the connections manually, making the underlying parameters sub-optimal. In this work, we propose the Neuro-Symbolic Program Search (NSPS) to improve the autonomous driving system design. NSPS is a novel automated search method that synthesizes the Neuro-Symbolic Programs. It can produce robust and expressive Neuro-Symbolic Programs and automatically tune the hyper-parameters. We validate NSPS in the CARLA driving simulation environment. The resulting Neuro-Symbolic Decision Programs successfully handle multiple traffic scenarios. Compared with previous neural-network-based driving and rule-based methods, our neuro-symbolic driving pipeline achieves more stable and safer behaviors in complex driving scenarios while maintaining an interpretable symbolic decision-making process.}
}
@ARTICLE{9491826, author={Lu, Sidi and Shi, Weisong}, journal={IEEE Internet Computing}, title={The Emergence of Vehicle Computing}, year={2021}, volume={25}, number={3}, pages={18-22}, doi={10.1109/MIC.2021.3066076}}
@article{benekohal1988carsim,
title={CARSIM: Car-following model for simulation of traffic in normal and stop-and-go conditions},
author={Benekohal, Rahim F and Treiterer, Joseph},
journal={Transportation research record},
volume={1194},
pages={99--111},
year={1988},
publisher={SAGE Publishing}
}
@book{buehler2009darpa,
title={The DARPA urban challenge: autonomous vehicles in city traffic},
author={Buehler, Martin and Iagnemma, Karl and Singh, Sanjiv},
volume={56},
year={2009},
publisher={springer}
}
@InProceedings{pmlr-v100-bansal20a,
title = {Combining Optimal Control and Learning for Visual Navigation in Novel Environments},
author = {Bansal, Somil and Tolani, Varun and Gupta, Saurabh and Malik, Jitendra and Tomlin, Claire},
booktitle = {Proceedings of the Conference on Robot Learning},
pages = {420--429},
year = {2020},
editor = {Kaelbling, Leslie Pack and Kragic, Danica and Sugiura, Komei},
volume = {100},
series = {Proceedings of Machine Learning Research},
month = {30 Oct--01 Nov},
publisher = {PMLR},
pdf = {http://proceedings.mlr.press/v100/bansal20a/bansal20a.pdf},
url = {https://proceedings.mlr.press/v100/bansal20a.html},
abstract = {Model-based control is a popular paradigm for robot navigation because it can leverage a known dynamics model to efficiently plan robust robot trajectories. However, it is challenging to use model-based methods in settings where the environment is a priori unknown and can only be observed partially through onboard sensors on the robot. In this work, we address this short-coming by coupling model-based control with learning-based perception. The learning-based perception module produces a series of waypoints that guide the robot to the goal via a collision-free path. These waypoints are used by a model-based planner to generate a smooth and dynamically feasible trajectory that is executed on the physical system using feedback control. Our experiments in simulated real-world cluttered environments and on an actual ground vehicle demonstrate that the proposed approach can reach goal locations more reliably and efficiently in novel environments as compared to purely geometric mapping-based or end-to-end learning-based alternatives. Our approach does not rely on detailed explicit 3D maps of the environment, works well with low frame rates, and generalizes well from simulation to the real world. Videos describing our approach and experiments are available on the project website4.}
}
@article{levine2018learning,
title={Learning hand-eye coordination for robotic grasping with deep learning and large-scale data collection},
author={Levine, Sergey and Pastor, Peter and Krizhevsky, Alex and Ibarz, Julian and Quillen, Deirdre},
journal={The International journal of robotics research},
volume={37},
number={4-5},
pages={421--436},
year={2018},
publisher={SAGE Publications Sage UK: London, England}
}
@incollection{peters2016robot,
title={Robot learning},
author={Peters, Jan and Lee, Daniel D and Kober, Jens and Nguyen-Tuong, Duy and Bagnell, J Andrew and Schaal, Stefan},
booktitle={Springer Handbook of Robotics},
pages={357--398},
year={2016},
publisher={Springer}
}
@article{saxena2014robobrain,
title={Robobrain: Large-scale knowledge engine for robots},
author={Saxena, Ashutosh and Jain, Ashesh and Sener, Ozan and Jami, Aditya and Misra, Dipendra K and Koppula, Hema S},
journal={arXiv preprint arXiv:1412.0691},
year={2014}
}
@inproceedings{zhu2017target,
title={Target-driven visual navigation in indoor scenes using deep reinforcement learning},
author={Zhu, Yuke and Mottaghi, Roozbeh and Kolve, Eric and Lim, Joseph J and Gupta, Abhinav and Fei-Fei, Li and Farhadi, Ali},
booktitle={2017 IEEE international conference on robotics and automation (ICRA)},
pages={3357--3364},
year={2017},
organization={IEEE}
}
@ARTICLE{9123682, author={Pan, Bowen and Sun, Jiankai and Leung, Ho Yin Tiga and Andonian, Alex and Zhou, Bolei}, journal={IEEE Robotics and Automation Letters}, title={Cross-View Semantic Segmentation for Sensing Surroundings}, year={2020}, volume={5}, number={3}, pages={4867-4873}, doi={10.1109/LRA.2020.3004325}}
@article{tang2018ba,
title={Ba-net: Dense bundle adjustment network},
author={Tang, Chengzhou and Tan, Ping},
journal={arXiv preprint arXiv:1806.04807},
year={2018}
}
@inproceedings{tanaka2021learning,
title={Learning To Bundle-Adjust: A Graph Network Approach to Faster Optimization of Bundle Adjustment for Vehicular SLAM},
author={Tanaka, Tetsuya and Sasagawa, Yukihiro and Okatani, Takayuki},
booktitle={Proceedings of the IEEE/CVF International Conference on Computer Vision},
pages={6250--6259},
year={2021}
}
@inproceedings{tobin2017domain,
title={Domain randomization for transferring deep neural networks from simulation to the real world},
author={Tobin, Josh and Fong, Rachel and Ray, Alex and Schneider, Jonas and Zaremba, Wojciech and Abbeel, Pieter},
booktitle={2017 IEEE/RSJ international conference on intelligent robots and systems (IROS)},
pages={23--30},
year={2017},
organization={IEEE}
}
@inproceedings{finn2017deep,
title={Deep visual foresight for planning robot motion},
author={Finn, Chelsea and Levine, Sergey},
booktitle={2017 IEEE International Conference on Robotics and Automation (ICRA)},
pages={2786--2793},
year={2017},
organization={IEEE}
}
@article{duan2017one,
title={One-shot imitation learning},
author={Duan, Yan and Andrychowicz, Marcin and Stadie, Bradly and Jonathan Ho, OpenAI and Schneider, Jonas and Sutskever, Ilya and Abbeel, Pieter and Zaremba, Wojciech},
journal={Advances in neural information processing systems},
volume={30},
year={2017}
}
@book{koubaa2017robot,
title={Robot Operating System (ROS).},
author={Koub{\^a}a, Anis and others},
volume={1},
year={2017},
publisher={Springer}
}
@article{coleman2014reducing,
title={Reducing the barrier to entry of complex robotic software: a moveit! case study},
author={Coleman, David and Sucan, Ioan and Chitta, Sachin and Correll, Nikolaus},
journal={arXiv preprint arXiv:1404.3785},
year={2014}
}
@inproceedings{salzmann2020trajectron++,
title={Trajectron++: Dynamically-feasible trajectory forecasting with heterogeneous data},
author={Salzmann, Tim and Ivanovic, Boris and Chakravarty, Punarjay and Pavone, Marco},
booktitle={European Conference on Computer Vision},
pages={683--700},
year={2020},
organization={Springer}
}
@inproceedings{gog2021pylot,
title={Pylot: A modular platform for exploring latency-accuracy tradeoffs in autonomous vehicles},
author={Gog, Ionel and Kalra, Sukrit and Schafhalter, Peter and Wright, Matthew A and Gonzalez, Joseph E and Stoica, Ion},
booktitle={2021 IEEE International Conference on Robotics and Automation (ICRA)},
pages={8806--8813},
year={2021},
organization={IEEE}
}
@inproceedings{Dosovitskiy17,
title = { {CARLA}: {An} Open Urban Driving Simulator},
author = {Alexey Dosovitskiy and German Ros and Felipe Codevilla and Antonio Lopez and Vladlen Koltun},
booktitle = {Proceedings of the 1st Annual Conference on Robot Learning},
pages = {1--16},
year = {2017}
}
@inproceedings{10.1145/3492321.3519576,
author = {Gog, Ionel and Kalra, Sukrit and Schafhalter, Peter and Gonzalez, Joseph E. and Stoica, Ion},
title = {D3: A Dynamic Deadline-Driven Approach for Building Autonomous Vehicles},
year = {2022},
isbn = {9781450391627},
publisher = {Association for Computing Machinery},
address = {New York, NY, USA},
url = {https://doi.org/10.1145/3492321.3519576},
doi = {10.1145/3492321.3519576},
abstract = {Autonomous vehicles (AVs) must drive across a variety of challenging environments that impose continuously-varying deadlines and runtime-accuracy tradeoffs on their software pipelines. A deadline-driven execution of such AV pipelines requires a new class of systems that enable the computation to maximize accuracy under dynamically-varying deadlines. Designing these systems presents interesting challenges that arise from combining ease-of-development of AV pipelines with deadline specification and enforcement mechanisms.Our work addresses these challenges through D3 (Dynamic Deadline-Driven), a novel execution model that centralizes the deadline management, and allows applications to adjust their computation by modeling missed deadlines as exceptions. Further, we design and implement ERDOS, an open-source realization of D3 for AV pipelines that exposes finegrained execution events to applications, and provides mechanisms to speculatively execute computation and enforce deadlines between an arbitrary set of events. Finally, we address the crucial lack of AV benchmarks through our state-of-the-art open-source AV pipeline, Pylot, that works seamlessly across simulators and real AVs. We evaluate the efficacy of D3 and ERDOS by driving Pylot across challenging driving scenarios spanning 50km, and observe a 68% reduction in collisions as compared to prior execution models.},
booktitle = {Proceedings of the Seventeenth European Conference on Computer Systems},
pages = {453–471},
numpages = {19},
location = {Rennes, France},
series = {EuroSys '22}
}
@article{li2021metadrive,
author = {Li, Quanyi and Peng, Zhenghao and Xue, Zhenghai and Zhang, Qihang and Zhou, Bolei},
journal = {ArXiv preprint},
title = {Metadrive: Composing diverse driving scenarios for generalizable reinforcement learning},
url = {https://arxiv.org/abs/2109.12674},
volume = {abs/2109.12674},
year = {2021}
}
@article{peng2021learning,
author = {Peng, Zhenghao and Li, Quanyi and Hui, Ka Ming and Liu, Chunxiao and Zhou, Bolei},
journal = {Advances in Neural Information Processing Systems},
title = {Learning to Simulate Self-Driven Particles System with Coordinated Policy Optimization},
volume = {34},
year = {2021}
}
@inproceedings{peng2021safe,
author = {Peng, Zhenghao and Li, Quanyi and Liu, Chunxiao and Zhou, Bolei},
booktitle = {5th Annual Conference on Robot Learning},
title = {Safe Driving via Expert Guided Policy Optimization},
year = {2021}
}
@ARTICLE{8421746, author={Qin, Tong and Li, Peiliang and Shen, Shaojie}, journal={IEEE Transactions on Robotics}, title={VINS-Mono: A Robust and Versatile Monocular Visual-Inertial State Estimator}, year={2018}, volume={34}, number={4}, pages={1004-1020}, doi={10.1109/TRO.2018.2853729}}
@article{campos2021orb,
title={Orb-slam3: An accurate open-source library for visual, visual--inertial, and multimap slam},
author={Campos, Carlos and Elvira, Richard and Rodr{\'\i}guez, Juan J G{\'o}mez and Montiel, Jos{\'e} MM and Tard{\'o}s, Juan D},
journal={IEEE Transactions on Robotics},
volume={37},
number={6},
pages={1874--1890},
year={2021},
publisher={IEEE}
}
@inproceedings{li2021efficient,
author = {Li, Quanyi and Peng, Zhenghao and Zhou, Bolei},
booktitle = {International Conference on Learning Representations},
title = {Efficient Learning of Safe Driving Policy via Human-AI Copilot Optimization},
year = {2021}
}
@article{chaplot2020learning,
title={Learning to explore using active neural slam},
author={Chaplot, Devendra Singh and Gandhi, Dhiraj and Gupta, Saurabh and Gupta, Abhinav and Salakhutdinov, Ruslan},
journal={arXiv preprint arXiv:2004.05155},
year={2020}
}
@article{teed2021droid,
title={Droid-slam: Deep visual slam for monocular, stereo, and rgb-d cameras},
author={Teed, Zachary and Deng, Jia},
journal={Advances in Neural Information Processing Systems},
volume={34},
year={2021}
}
@article{brunke2021safe,
title={Safe learning in robotics: From learning-based control to safe reinforcement learning},
author={Brunke, Lukas and Greeff, Melissa and Hall, Adam W and Yuan, Zhaocong and Zhou, Siqi and Panerati, Jacopo and Schoellig, Angela P},
journal={Annual Review of Control, Robotics, and Autonomous Systems},
volume={5},
year={2021},
publisher={Annual Reviews}
}
@InProceedings{pmlr-v144-gama21a,
title = {Graph Neural Networks for Distributed Linear-Quadratic Control},
author = {Gama, Fernando and Sojoudi, Somayeh},
booktitle = {Proceedings of the 3rd Conference on Learning for Dynamics and Control},
pages = {111--124},
year = {2021},
editor = {Jadbabaie, Ali and Lygeros, John and Pappas, George J. and A.&nbsp;Parrilo, Pablo and Recht, Benjamin and Tomlin, Claire J. and Zeilinger, Melanie N.},
volume = {144},
series = {Proceedings of Machine Learning Research},
month = {07 -- 08 June},
publisher = {PMLR},
pdf = {http://proceedings.mlr.press/v144/gama21a/gama21a.pdf},
url = {https://proceedings.mlr.press/v144/gama21a.html},
abstract = {The linear-quadratic controller is one of the fundamental problems in control theory. The optimal solution is a linear controller that requires access to the state of the entire system at any given time. When considering a network system, this renders the optimal controller a centralized one. The interconnected nature of a network system often demands a distributed controller, where different components of the system are controlled based only on local information. Unlike the classical centralized case, obtaining the optimal distributed controller is usually an intractable problem. Thus, we adopt a graph neural network (GNN) as a parametrization of distributed controllers. GNNs are naturally local and have distributed architectures, making them well suited for learning nonlinear distributed controllers. By casting the linear-quadratic problem as a self-supervised learning problem, we are able to find the best GNN-based distributed controller. We also derive sufficient conditions for the resulting closed-loop system to be stable. We run extensive simulations to study the performance of GNN-based distributed controllers and showcase that they are a computationally efficient parametrization with scalability and transferability capabilities.}
}
@InProceedings{pmlr-v144-mehrjou21a,
title = {Neural Lyapunov Redesign},
author = {Mehrjou, Arash and Ghavamzadeh, Mohammad and Sch\"olkopf, Bernhard},
booktitle = {Proceedings of the 3rd Conference on Learning for Dynamics and Control},
pages = {459--470},
year = {2021},
editor = {Jadbabaie, Ali and Lygeros, John and Pappas, George J. and A.&nbsp;Parrilo, Pablo and Recht, Benjamin and Tomlin, Claire J. and Zeilinger, Melanie N.},
volume = {144},
series = {Proceedings of Machine Learning Research},
month = {07 -- 08 June},
publisher = {PMLR},
pdf = {http://proceedings.mlr.press/v144/mehrjou21a/mehrjou21a.pdf},
url = {https://proceedings.mlr.press/v144/mehrjou21a.html},
abstract = {Learning controllers merely based on a performance metric has been proven effective in many physical and non-physical tasks in both control theory and reinforcement learning. However, in practice, the controller must guarantee some notion of safety to ensure that it does not harm either the agent or the environment. Stability is a crucial notion of safety, whose violation can certainly cause unsafe behaviors. Lyapunov functions are effective tools to assess stability in nonlinear dynamical systems. In this paper, we combine an improving Lyapunov function with automatic controller synthesis in an iterative fashion to obtain control policies with large safe regions. We propose a two-player collaborative algorithm that alternates between estimating a Lyapunov function and deriving a controller that gradually enlarges the stability region of the closed-loop system. We provide theoretical results on the class of systems that can be treated with the proposed algorithm and empirically evaluate the effectiveness of our method using an exemplary dynamical system.}
}
@InProceedings{pmlr-v144-zhang21b,
title = {{LEOC}: A Principled Method in Integrating Reinforcement Learning and Classical Control Theory},
author = {Zhang, Naifu and Capel, Nicholas},
booktitle = {Proceedings of the 3rd Conference on Learning for Dynamics and Control},
pages = {689--701},
year = {2021},
editor = {Jadbabaie, Ali and Lygeros, John and Pappas, George J. and A.&nbsp;Parrilo, Pablo and Recht, Benjamin and Tomlin, Claire J. and Zeilinger, Melanie N.},
volume = {144},
series = {Proceedings of Machine Learning Research},
month = {07 -- 08 June},
publisher = {PMLR},
pdf = {http://proceedings.mlr.press/v144/zhang21b/zhang21b.pdf},
url = {https://proceedings.mlr.press/v144/zhang21b.html},
abstract = {There have been attempts in reinforcement learning to exploit a priori knowledge about the structure of the system. This paper proposes a hybrid reinforcement learning controller which dynamically interpolates a model-based linear controller and an arbitrary differentiable policy. The linear controller is designed based on local linearised model knowledge, and stabilises the system in a neighbourhood about an operating point. The coefficients of interpolation between the two controllers are determined by a scaled distance function measuring the distance between the current state and the operating point. The overall hybrid controller is proven to maintain the stability guarantee around the neighborhood of the operating point and still possess the universal function approximation property of the arbitrary non-linear policy. Learning has been done on both model-based (PILCO) and model-free (DDPG) frameworks. Simulation experiments performed in OpenAI gym demonstrate stability and robustness of the proposed hybrid controller. This paper thus introduces a principled method allowing for the direct importing of control methodology into reinforcement learning.}
}
@InProceedings{pmlr-v144-rafailov21a,
title = {Offline Reinforcement Learning from Images with Latent Space Models},
author = {Rafailov, Rafael and Yu, Tianhe and Rajeswaran, Aravind and Finn, Chelsea},
booktitle = {Proceedings of the 3rd Conference on Learning for Dynamics and Control},
pages = {1154--1168},
year = {2021},
editor = {Jadbabaie, Ali and Lygeros, John and Pappas, George J. and A.&nbsp;Parrilo, Pablo and Recht, Benjamin and Tomlin, Claire J. and Zeilinger, Melanie N.},
volume = {144},
series = {Proceedings of Machine Learning Research},
month = {07 -- 08 June},
publisher = {PMLR},
pdf = {http://proceedings.mlr.press/v144/rafailov21a/rafailov21a.pdf},
url = {https://proceedings.mlr.press/v144/rafailov21a.html},
abstract = {Offline reinforcement learning (RL) refers to the task of learning policies from a static dataset of environment interactions. Offline RL enables extensive utilization and re-use of historical datasets, while also alleviating safety concerns associated with online exploration, thereby expanding the real-world applicability of RL. Most prior work in offline RL has focused on tasks with compact state representations. However, the ability to learn directly from rich observation spaces like images is critical for real-world applications like robotics. In this work, we build on recent advances in model-based algorithms for offline RL, and extend them to high-dimensional visual observation spaces. Model-based offline RL algorithms have achieved state of the art results in state based tasks and are minimax optimal. However, they rely crucially on the ability to quantify uncertainty in the model predictions. This is particularly challenging with image observations. To overcome this challenge, we propose to learn a latent-state dynamics model, and represent the uncertainty in the latent space. Our approach is both tractable in practice and corresponds to maximizing a lower bound of the ELBO in the unknown POMDP. Through experiments on a range of challenging image-based locomotion and robotic manipulation tasks, we find that our algorithm significantly outperforms previous offline model-free RL methods as well as state-of-the-art online visual model-based RL methods. Moreover, we also find that our approach excels on an image-based drawer closing task on a real robot using a pre-existing dataset. All results including videos can be found online at \url{https://sites.google.com/view/lompo/}.}
}
@inproceedings{chen2020transferable,
title={Transferable active grasping and real embodied dataset},
author={Chen, Xiangyu and Ye, Zelin and Sun, Jiankai and Fan, Yuda and Hu, Fang and Wang, Chenxi and Lu, Cewu},
booktitle={2020 IEEE International Conference on Robotics and Automation (ICRA)},
pages={3611--3618},
year={2020},
organization={IEEE}
}
@article{sun2021adversarial,
title={Adversarial inverse reinforcement learning with self-attention dynamics model},
author={Sun, Jiankai and Yu, Lantao and Dong, Pinqian and Lu, Bo and Zhou, Bolei},
journal={IEEE Robotics and Automation Letters},
volume={6},
number={2},
pages={1880--1886},
year={2021},
publisher={IEEE}
}
@article{huang2018navigationnet,
title={NavigationNet: A large-scale interactive indoor navigation dataset},
author={Huang, He and Shen, Yujing and Sun, Jiankai and Lu, Cewu},
journal={arXiv preprint arXiv:1808.08374},
year={2018}
}
@inproceedings{xu2019depth,
title={Depth completion from sparse lidar data with depth-normal constraints},
author={Xu, Yan and Zhu, Xinge and Shi, Jianping and Zhang, Guofeng and Bao, Hujun and Li, Hongsheng},
booktitle={Proceedings of the IEEE/CVF International Conference on Computer Vision},
pages={2811--2820},
year={2019}
}
@inproceedings{zhu2020ssn,
title={Ssn: Shape signature networks for multi-class object detection from point clouds},
author={Zhu, Xinge and Ma, Yuexin and Wang, Tai and Xu, Yan and Shi, Jianping and Lin, Dahua},
booktitle={European Conference on Computer Vision},
pages={581--597},
year={2020},
organization={Springer}
}
@inproceedings{huang2019prior,
title={Prior guided dropout for robust visual localization in dynamic environments},
author={Huang, Zhaoyang and Xu, Yan and Shi, Jianping and Zhou, Xiaowei and Bao, Hujun and Zhang, Guofeng},
booktitle={Proceedings of the IEEE/CVF International Conference on Computer Vision},
pages={2791--2800},
year={2019}
}
@article{xu2020selfvoxelo,
title={Selfvoxelo: Self-supervised lidar odometry with voxel-based deep neural networks},
author={Xu, Yan and Huang, Zhaoyang and Lin, Kwan-Yee and Zhu, Xinge and Shi, Jianping and Bao, Hujun and Zhang, Guofeng and Li, Hongsheng},
journal={arXiv preprint arXiv:2010.09343},
year={2020}
}
@article{huang2021life,
title={LIFE: Lighting Invariant Flow Estimation},
author={Huang, Zhaoyang and Pan, Xiaokun and Xu, Runsen and Xu, Yan and Zhang, Guofeng and Li, Hongsheng and others},
journal={arXiv preprint arXiv:2104.03097},
year={2021}
}
@inproceedings{huang2021vs,
title={VS-Net: Voting with Segmentation for Visual Localization},
author={Huang, Zhaoyang and Zhou, Han and Li, Yijin and Yang, Bangbang and Xu, Yan and Zhou, Xiaowei and Bao, Hujun and Zhang, Guofeng and Li, Hongsheng},
booktitle={Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition},
pages={6101--6111},
year={2021}
}
@article{yang2021pdnet,
title={PDNet: Towards Better One-stage Object Detection with Prediction Decoupling},
author={Yang, Li and Xu, Yan and Wang, Shaoru and Yuan, Chunfeng and Zhang, Ziqi and Li, Bing and Hu, Weiming},
journal={arXiv preprint arXiv:2104.13876},
year={2021}
}
@article{xu2022robust,
title={Robust Self-supervised LiDAR Odometry via Representative Structure Discovery and 3D Inherent Error Modeling},
author={Xu, Yan and Lin, Junyi and Shi, Jianping and Zhang, Guofeng and Wang, Xiaogang and Li, Hongsheng},
journal={IEEE Robotics and Automation Letters},
year={2022},
publisher={IEEE}
}
@article{xu2022rnnpose,
title={RNNPose: Recurrent 6-DoF Object Pose Refinement with Robust Correspondence Field Estimation and Pose Optimization},
author={Xu, Yan and Lin, Junyi and Zhang, Guofeng and Wang, Xiaogang and Li, Hongsheng},
journal={arXiv preprint arXiv:2203.12870},
year={2022}
}
@inproceedings{Sun2022SelfSupervisedTA,
title={Self-Supervised Traffic Advisors: Distributed, Multi-view Traffic Prediction for Smart Cities},
author={Jiankai Sun and Shreyas Kousik and David Fridovich-Keil and Mac Schwager},
year={2022}
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.4 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

BIN
static/logo-with-text.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.4 KiB

After

Width:  |  Height:  |  Size: 50 KiB