神经网络不确定性综述(Part I)——A survey of uncertainty in deep neural networks

相关链接:

神经网络不确定性综述(Part I)——A survey of uncertainty in deep neural networks-CSDN博客

神经网络不确定性综述(Part II)——Uncertainty estimation_Single deterministic methods-CSDN博客

神经网络不确定性综述(Part III)——Uncertainty estimation_Bayesian neural networks-CSDN博客

神经网络不确定性综述(Part IV)——Uncertainty estimation_Ensemble methods&Test-time augmentation-CSDN博客

神经网络不确定性综述(Part V)——Uncertainty measures and quality-CSDN博客


0. 概述

随着神经网络技术在现实世界中的应用不断广泛,神经网络预测置信度变得越来越重要,尤其是在医学图像分析与自动驾驶等高风险领域。然而,最基本的神经网络并不包含置信度估计的过程,并且通常面临着over-confidence或者under-confidence的问题。针对此问题,研究人员开始关注于量化神经网络预测中存在的uncertainty,由此定义了不同类型、不同来源的uncertainty以及量化uncertainty的技术。

本篇文章尝试对神经网络中的不确定性估计方法进行总结和归纳,将uncertainty的来源分为reducible model uncertainty以及irreducible data uncertainty两种类别,介绍了基于确定性神经网络(deterministic neural networks)、贝叶斯神经网络(Bayesian neural networks)、神经网络集成(ensemble of neural networks)以及测试时数据增强(test-time data augmentation)等不确定性建模方法。


1. Introduction

深度神经网络(Deep Neural Networks, DNN)在mission- and safety-critical real world applications上存在局限,具体表现为:

  • DNN inference model的表达能力(expressiveness)和透明度(transparency)不足,导致它们产生的预测结果难以信服——可解释性差;
  • DNN无法区分in-domain与out-of-domain的样本,对domain shifts十分敏感——泛化性差;
  • 无法提供可靠的不确定性估计,并且趋向于产生over-confident predictions——过度自信;
  • 对adversarial attacks的敏感性导致DNN很容易遭到攻击而被破坏——系统稳定性差。

造成以上现象出现的主要来源有两种,一种是数据本身引入的不确定性,即data uncertainty;另一种是神经网络学到的知识不足所造成的不确定性,即model uncertainty。为了克服DNN的这些局限性,uncertainty estimation就至关重要。有了不确定性估计,人类专家就可以通过查看模型预测结果所对应的不确定性,忽略那些不确定性很高的结果。

不确定性估计不仅对于高风险领域的安全决策有帮助,在数据源高度不均匀(inhomogeneous)以及标注数据较少的领域也十分关键,并且对于以不确定性作为学习技术关键部分的领域例如active learning及reinforcement learning同样至关重要。

近年来,研究者在DNN的不确定性估计方面展现了与日俱增的兴趣。估计预测不确定性(predictive uncertainty)最常用的方法是分别对由模型引起的不确定性(认知不确定性/模型不确定性,epistemic or model uncertainty)和由数据引起的不确定性(任意不确定性/数据不确定性,aleatoric or data uncertainty)进行建模。其中模型不确定性是可以降低的,而数据不确定性则无法降低。

目前,对于这两种不确定性最常见的建模方法包括:

  1. Bayesian inference
  2. Ensemble approaches
  3. Test-time augmentation
  4. Single deterministic networks containing explicit components to represent the model and the data uncertainty.

然而,在高风险领域仅仅对predictive uncertainty进行估计还远远不够,还需要进一步确认估计得到的uncertainty是否可靠。为此,研究人员研究了DNN的校准特性(the degree of reliability,可靠性程度),并提出了重新校准(re-calibration)方法,以获得可靠的(well-calibrated,校准良好的)不确定性估计。

下面几个章节将具体介绍不确定性的来源、类型、DNN中不确定性估计的方法、评估不确定性估计质量的度量方法、calibrate DNN的方法、被频繁使用的evaluation datasets与benchmarks、不确定估计在现实世界的应用以及该领域现有的挑战与未来展望。

2. Uncertainty in deep neural networks

一个神经网络就是一个被模型参数 \theta 所参数化的非线性函数 f_\theta,这个函数会将可测的输入集 \mathbb{X}

映射到另一个可测的输出集 \mathbb{Y} 上,即:f_\theta:\mathbb{X}\rightarrow\mathbb{Y},f_\theta(x)=y.

在supervised setting下,进一步地,对于有限训练集 \mathcal{D}\subseteq\mathbb{D}=\mathbb{X}\times\mathbb{Y},其中包含 N 个图像-标签对,即

\mathcal{D}=(\mathcal{X},\mathcal{Y})=\{​{x_n,y_n}\}_{n=1}^N\subseteq\mathbb{D}.

此时对于新的数据样本x^\ast\in\mathbb{X},在 \mathcal{D} 上训练得到的神经网络可以预测其对应的target,

f_\theta(x^\ast)=y^\ast.

现在,我们考虑从环境中的原始信息(raw information)最终神经网络产生的带有uncertainty的prediction的整个过程中包含的四个不同的步骤:

  1. the data acquisition process——在环境中出现的一些information (e.g. a bird’s singing)以及对这些信息的measured observation (e.g. an audio record).
  2. the DNN building process——网络的设计和训练
  3. the applied inference model——inference阶段使用的model
  4. the prediction’s uncertainty model——对神经网络and/or数据产生的uncertainty的建模

事实上,这四个步骤包含了几个潜在的uncertainty/error来源,并进一步影响神经网络的最终预测。作者认为造成神经网络prediction中uncertainty的最重要的五个因素是:

  1. 真实世界的多变性variability
  2. 测量系统固有的误差
  3. DNN架构规范(architecture specification)中的误差,例如每一层节点数量、激活函数等
  4. DNN训练过程中的误差
  5. 由unknown data产生的误差y|\omega\sim p_{y|\omega}

接下来,我们将具体介绍以上四个步骤/五个错误来源从而产生不确定性的具体细节。

2.1 Data acquisition

对于监督学习而言,data acquisition描述了measurements x以及target variables y 的生成过程,从而在某个space \Omega上表示真实世界的situation \omega.

In the real world, a realization of \omega could for example be a bird, x a picture of this bird, and y a label stating ‘bird’. During the measurement, random noise can occur and information may get lost. We model this randomness in x by

x|\omega\sim p_{x|\omega}

Equivalently, the corresponding target variable y is derived, where the description is either based on another measurement or is the result of a labeling process*. For both cases, the description can be affected by noise and errors and we state it as

y|\omega\sim p_{y|\omega}

*NOTE:  In many cases one can model the labeling process as a mapping from \mathbb{X} to \mathbb{Y},e.g. for speech recognition or various computer vision tasks. For other tasks, such as earth observation, this is not always the case. Data is often labeled based on high-resolution data while low-resolution data is utilized for the prediction task.

A neural network is trained on a finite dataset of realizations of x|\omega_i and y|\omega_i based on N real world situations \omega_1,\ldots,\omega_N,

\mathcal{D}={x_i,y_i}_{i=1}^N

当我们收集数据并利用其对神经网络进行训练时,有2个因素会使神经网络产生uncertainty。

第一个因素源自于真实世界复杂可变的situations。例如,一株植物在雨后和干旱两个场景下所呈现出的外观是不同的。我们只能在采集数据时尽可能地覆盖而无法穷举所有情形,这导致神经网络在面临distribution shifts时表现不佳。

Factor I: Variability in real-world situations

Most real-world environments are highly variable and almost constantly affected by changes. These changes affect parameters such as temperature, illumination, clutter, and physical objects’ size and shape. Changes in the environment can also affect the expression of objects, such as plants after rain look very different from plants after a drought. When real-world situations change compared to the training set, this is called a distribution shift. Neural networks are sensitive to distribution shifts, which can lead to significant changes in the performance of a neural network.

第二个因素是测量系统(measurement system)本身,它直接影响了sample与其相应target的相关性。The measurement system generates information x_i and y_i that describe \omega_i. 这意味着高度不同的现实世界场景却拥有相似的measurement或者targets。比如,对于city和forest两种situation而言,测量系统测量得到的温度temperature很可能比较相近( x 相近);另外,label noise也可能导致它们的targets相近,比如将二者都标注为forest( y 相近)。

Factor II: Error and noise in measurement systems

The measurements themselves can be a source of uncertainty on the neural network’s prediction. This can be caused by limited information in the measurements, such as the image resolution. Moreover, it can be caused by noise, for example, sensor noise, by motion, or mechanical stress leading to imprecise measures. Furthermore, false labeling is also a source of uncertainty that can be seen as an error or noise in the measurement system. It is referenced as label noise and affects the model by reducing the confidence on the true class prediction during training. Depending on the intensity, this type of noise and errors can be used to regularize the training process and to improve robustness and generalization.

2.2 Deep neural network design and training

神经网络的设计包括显式建模(explicit modeling)以及随机的训练过程。由设计和训练神经网络引发的对问题结构的假设称为归纳偏置(inductive bias)。具体而言,归纳偏置可理解为建模者在建模阶段根据先验知识所采取的策略。比如,对于网络的structure而言,涉及网络参数量、层数、激活函数的选择等;对于网络的training process而言,涉及优化算法、正则化、数据增强等。这些策略的选择直接影响了模型最终的性能,而网络的structure带来了神经网络预测具有不确定性的第三个因素。

Factor III: Errors in the model structure

The structure of a neural network has a direct effect on its performance and therefore also on the uncertainty of its prediction. For instance, the number of parameters affects the memorization capacity, which can lead to under- or over-fitting on the training data. Regarding uncertainty in neural networks, it is known that deeper networks tend to be overconfident in their soft-max output, meaning that they predict too much probability on the class with the highest probability score.

对于给定的网络结构 s 以及训练数据集 \mathcal{D},神经网络的训练是一个随机的过程,因此所产生的网络 f_\theta 基于随机变量 \theta|D,s\sim p_{\theta|D,s}。网络训练过程中的随机性有很多,比如随机决策,比如数据顺序、随机初始化、随即正则化如augmentation或dropout,这使得网络的loss是高度非线性的,从而导致不同的局部最优解 \theta^\ast,从而产生不同的模型;此外,batch size、learning rate以及epoch等超参数也会影响训练结果,产生不同的模型。神经网络的这种对训练过程的敏感性产生了第四个不确定性因素。

Factor IV: Errors in the training procedure

The training process of a neural network includes many parameters that have to be defined (batch size, optimizer, learning rate, stopping criteria, regularization, etc.), and also stochastic decisions within the training process (batch generation and weight initialization) take place. All these decisions affect the local optima and it is therefore very unlikely that two training processes deliver the same model parameterization. A training dataset that suffers from imbalance or low coverage of single regions in the data distribution also introduces uncertainties on the network’s learned parameters, as already described in the data acquisition. This might be softened by applying augmentation to increase the variety or by balancing the impact of single classes or regions on the loss function.

由于训练过程是基于给定的训练数据集 \mathcal{D} 的,因此data acquisition process中的error(比如label noises)也会导致training process中的error

2.3 Inference

Inference描述了神经网络对新数据样本 x^\ast 的输出 y^\ast 的预测。在这种情况下,网络的训练是针对于特定的任务的。因此,不符合该任务输入的样本会产生error,因此也是uncertainty的来源之一。

Factor V: Errors caused by unknown data

Especially in classification tasks, a neural network that is trained on samples derived from a world \mathcal{W}_1 can also be capable of processing samples derived from a completely different world \mathcal{W}_2. This is for example the case when a network trained on images of cats and dogs receives a sample showing a bird. Here, the source of uncertainty does not lie in the data acquisition process, since we assume a world to contain only feasible inputs for a prediction task. Even though the practical result might be equal to too much noise on a sensor or complete failure of a sensor, the data considered here represents a valid sample, but for a different task or domain.

这种误差并不是data acquisition process所造成的,而是由未知数据产生的。

2.4 Predictive uncertainty model

神经网络预测中包含的不确定性可以分为三类:

  • data uncertainty [also statistical or aleatoric uncertainty]
  • model uncertainty [also systemic or epistemic uncertainty]
  • distributional uncertainty (caused by examples from a region not covered by the training data)

2.4.1 Model and data uncertainty

The model uncertainty源于模型的缺陷。这些缺陷可能是模型本身结构有问题,也可能是在训练进程中引入错误、或者由于unknown data/训练集对真实世界覆盖能力差 (bad coverage)而导致得到的模型缺乏足够的knowledge。

The data uncertainty指的是源于数据本身的缺陷,其根本原因在于information loss,使得无法完美地表示真实世界,样本不包含足够的信息以100%的certainty识别某个类别。

信息损失本身也体现在两个方面,一方面是source (data),比如低分辨率图像会丢失表示真实世界的信息;另一方面是target (label),比如在labelling process中出现的错误。

现在让我们回顾一下五种造成uncertain prediction的因素:

  • Factor I 真实世界的多样性/多变性
  • Factor II 测量系统的缺陷
  • Factor III 模型结构的缺陷
  • Factor IV 模型随机训练过程中的错误
  • Factor V 未知数据的干扰

可以看到,只有Factor II属于不可消除的aleatoric uncertainty,因为它造成了数据本身的缺陷即insufficient data,从而导致预测变得不可靠。其余的Factor全部属于epistemic uncertainty,是可以消除的。

理论上model uncertainty可以通过改进model architecture、learning process或者training dataset来降低,而data uncertainty无法被消除。因此,对于real-world applications而言,如果一个模型能够remove or quantify the model uncertainty and give a correct prediction of the data uncertainty将至关重要。(此处有supervision的含义在里面)

在众多方法中,Bayesian framework提供了一个实用的工具来推理深度学习中的uncertainty。在贝叶斯框架中,model uncertainty被形式化为模型参数的概率分布,而data uncertainty被形式化为模型(参数为\theta)的output y^\ast的概率分布。

预测 y^\ast 的概率分布为

p(y^*|x^*,D)=\int p(\underbrace{y^*|x^*,\theta}_{\mathrm{Data}}\underbrace{p(\theta|D)}_{\mathrm{Model}}d\theta.

其中,p(\theta|D) 是模型参数的posterior,描述了给定训练集 D 后模型参数的不确定性。通常情况下,后验分布是intractable的,为了得到(近似)后验分布,ensemble approaches尝试学习不同的parameter settings并对结果做平均来近似后验分布;而Bayesian inference利用贝叶斯定理将其reformulate为

p(\theta|D)=\frac{p(D|\theta)p(\theta)}{p(D)}

其中 p(\theta) 不考虑任何information而仅仅考虑 \theta 因此被称为模型参数的先验分布prior,p(D|\theta) 代表 D 是模型(参数为 \theta)预测所产生输出分布的一个realization,称为likelihood。许多损失函数都是由似然函数驱动的,寻找最大化对数似然的损失函数的例子如交叉熵或均方误差。

然而,即使我们使用贝叶斯定理将后验分布reformulate为以上式子,p(y^\ast|x^\ast,D)仍然是intractable的。为了解决这个问题,一系列方法被逐渐提出,在Section 3会具体介绍。

2.4.2 Distributional uncertainty

The predictive uncertainty可以进一步地被划分为data、model以及distributional uncertainty三个部分,

p(y^*|x^*,D)=\int\int\underbrace{p(y^*|\mu)}_{\mathrm{Data}}\underbrace{p(\mu|x^*,\theta)}_{\text{Distributional}}\underbrace{p(\theta|D)}_{\mathrm{Model}}d\mu d\theta.

如何理解其中的distributional part?我们可以这样考虑,uncertainty意为不确定性,可以用一个分布进行刻画,比如model uncertainty可以由模型参数 \theta 的分布得到。同理,distributional uncertainty可以由distribution的分布得到,即,分布的分布;例如对于分类任务而言,p\left(\mu\middle| x^\ast,\theta\right)可能是Dirichlet distribution,指的是最终由soft-max给出的分类分布所服从的分布。再进一步,data uncertainty代表最终预测结果 y^\ast的分布(以 \mu 为参数)。

根据这种建模方式,distributional uncertainty表示由于input-data distribution发生改变所引入的不确定性;model uncertainty表示在model building and training process中引入的不确定性。model uncertainty会影响distributional uncertainty的估计,distributional uncertainty又会进一步影响data uncertainty的估计。

2.5 Uncertainty classification

On the basis of the input data domain, the predictive uncertainty can also be classified into 3 main classes:

  • In-domain uncertainty

In-domain uncertainty represents the uncertainty related to an input drawn from a data distribution assumed to be equal to the training data distribution. 域内不确定性源于深度神经网络lack of in-domain knowledge而无法解释域内样本,从modeler的角度看,其原因一方面是design errors (model uncertainty),另一方面是当前任务的复杂性 (data uncertainty)。因此,根据这两类来源,我们可以通过提高训练集的质量或者优化训练过程来减少in-domain uncertainty。

  • Domain-shift uncertainty

Domain-shift uncertainty denotes the uncertainty related to an input drawn from a shifted version of the training distribution. 域偏移不确定性源于训练数据集的insufficient coverage,其原因可能是数据集本身的收集不当,也可能是真实世界的多变性。从modeler的角度看,domain-shift uncertainty是源于external or environmental factors。这种uncertainty可以通过cover the shifted domain in the training dataset来减少。

  • Out-of-domain uncertainty

Out-of-domain uncertainty represents the uncertainty related to an input drawn from the subspace of unknown data. 未知数据的分布远不同于训练数据集的分布,比如将鸟输入到猫狗训练器。从modeler的角度看,out-of-domain uncertainty源于输入样本,即insufficient training data。

我们发现,上述三种uncertainty的根本都是因为训练数据集的insufficiency。再将视角回到model uncertainty与data uncertainty上,显然,模型不确定性的主要原因同样是insufficient training dataset,因此in-domain、domain shift、out-of-domain uncertainty都能产生model uncertainty;而相比之下,data uncertainty则更多与in-domain uncertainty相关,例如overlapping samples and systematic label noise,而这些误差均来自于域内数据的模糊/噪声。

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/bicheng/16047.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

Python实现xml解析并输出到Excel上

1.编写xml文件 2.使用Python的ElementTree模块来解析XML import xml.etree.ElementTree as ET from openpyxl import Workbook # 解析XML函数 def parse_xml(xml_file):tree ET.parse(xml_file)root tree.getroot() --打开根节点data []for user in root.findall(Users/Us…

1.手动LogisticRegression模型的训练和预测

通过这个示例,可以了解逻辑回归模型的基本原理和训练过程,同时可以通过修改和优化代码来进一步探索机器学习模型的训练和调优方法。 过程: 生成了一个模拟的二分类数据集:通过随机生成包含两个特征的数据data_x,并基于一定规则生…

秋招突击——算法打卡——5/25、5/26——寻找两个正序数组的中位数

题目描述 自我尝试 首先,就是两个有序的数组进行遍历,遍历到一半即可。然后求出均值,下述是我的代码。但这明显是有问题的,具体错误的代码如下。计算复杂度太高了,O(n),所以会超时&…

数据结构--《二叉树》

二叉树 1、什么是二叉树 二叉树(Binar Tree)是n(n>0)个结点的优先集合,该集合或者为空集(称为空二叉树),或者由一个根结点和两颗互不相交的、分别称为根结点的左子树和右子树的二叉树构成。 这里给张图,能更直观的感受二叉树&#xff1…

GDPU JavaWeb mvc模式

搭建一个mvc框架的小实例。 简易计算器 有一个名为inputNumber.jsp的页面提供一个表单,用户可以通过表单输入两个数和运算符号提交给Servlet控制器;由名为ComputerBean.java生成的JavaBean负责存储运算数、运算符号和运算结果,由名为handleCo…

简单好用的文本识别方法--付费的好用,免费的更有性价比-记笔记

文章目录 先说付费的进入真题,免费的来喏!PixPin微信 先说付费的 直达网址!!! 进入真题,免费的来喏! PixPin 商店里就有 使用示例: 可以看到:贴在桌面上的图片可以复制图片中的文字,真的很…

Springboot+Vue+ElementUI开发前后端分离的员工管理系统01--系统介绍

项目介绍 springboot_vue_emp是一个基于SpringbootVueElementUI实现的前后端分离的员工管理系统 功能涵盖: 系统管理:用户管理、角色管理、菜单管理、字典管理、部门管理出勤管理:请假管理、考勤统计、工资发放、工资统计、离职申请、个人资…

8.Redis之hash类型

1.hash类型的基本介绍 哈希表[之前学过的所有数据结构中,最最重要的] 1.日常开发中,出场频率非常高. 2.面试中,非常重要的考点, Redis 自身已经是键值对结构了Redis 自身的键值对就是通过 哈希 的方式来组织的 把 key 这一层组织完成之后, 到了 value 这一层~~ value 的其中…

最重要的时间表示,柯桥外贸俄语小班课

в第四格 1、与表示“钟点”的数词词组连用 例: в шесть часов утра 在早上六点 в пять тридцать 在五点半 2、与表示“星期”的名词连用 例: в пятницу 在周五 в следующий понедельник …

String类为什么设计成不可变的?

目录 缓存 安全性 线程安全 hashCode缓存 性能 其实这个问题我们可以通过缓存、安全性、线程安全和性能几个维度去解析。 缓存 字符串是Java最常用的数据结构,我们都知道字符串大量创建是非常耗费资源的,所以Java中就将String设计为带有缓存的功能…

【python】python tkinter 计算器GUI版本(模仿windows计算器 源码)【独一无二】

👉博__主👈:米码收割机 👉技__能👈:C/Python语言 👉公众号👈:测试开发自动化【获取源码商业合作】 👉荣__誉👈:阿里云博客专家博主、5…

17.分类问题

机器学习分类问题详解与实战 介绍 在机器学习中,分类问题是一类常见的监督学习任务,其目标是根据输入特征将数据样本划分为预先定义的类别之一。分类问题广泛应用于各个领域,如图像识别、自然语言处理、金融风险评估等。本文将详细介绍机器…

Spring Cloud 项目中使用 Swagger

Spring Cloud 项目中使用 Swagger 关于方案的选择 在 Spring Cloud 项目中使用 Swagger 有以下 4 种方式: 方式一 :在网关处引入 Swagger ,去聚合各个微服务的 Swagger。未来是访问网关的 Swagger 原生界面。 方式二 :在网关处引…

RedHat9 | DNS剖析-配置辅助DNS服务器

一、实验环境 1、辅助域名DNS服务器 DNS通过划分为若干个区域进行管理,每一个区域由1台或多台DNS服务器负责解析,如果仅仅采用1台DNS服务器,在DNS服务器出现故障后,用户将无法完成解析。 辅助DNS服务器的优点 容灾备份&#x…

区间预测 | Matlab实现DNN-KDE深度神经网络结合核密度估计多置信区间多变量回归区间预测

区间预测 | Matlab实现DNN-KDE深度神经网络结合核密度估计多置信区间多变量回归区间预测 目录 区间预测 | Matlab实现DNN-KDE深度神经网络结合核密度估计多置信区间多变量回归区间预测效果一览基本介绍程序设计参考资料 效果一览 基本介绍 1.Matlab实现DNN-KDE深度神经网络结合…

MySQL数据处理增删改

数据处理增删改DML 由于约束,以下操作都有可能执行失败(后面讲约束) 插入数据 INSERT 基础添加:VALUES 值的顺序必须和表中字段顺序相同 INSERT INTO class VALUES(1,王小,10); 向指定字段添加: 值的顺序和指定…

MT7628原厂Uboot修改交互串口

工作中,遇到用户用Skylab的SKW92A模组,在参考设计时,将UART接口预留错的情况,对于这种情况,需要将原厂SDK默认的交互串口UART0,改为UART1。在开发过程中,经常需要在Uboot阶段升级固件&#xff0…

【Linux部署】【pig前端部署】Linux安装- docker/docker-compose/nginx (使用docker优雅部署nginx)

🌸🌸 Linux安装- docker/docker-compose/nginx 优雅部署 🌸🌸 一、一键安装jdk yum install -y java-1.8.0-openjdk.x86_64验证 二、安装docker yum list docker-ce --showduplicates | sort -rsudo yum install -y yum-utils …

LabVIEW波纹补偿器无线监测系统

LabVIEW波纹补偿器无线监测系统 在石油化工、冶金及电力等行业中,波纹补偿器作为一种重要的补偿性元件,其安全稳定的运行对管道输送系统的可靠性至关重要。开发了一种基于LabVIEW的波纹补偿器无线监测系统,通过实时监测波纹补偿器的工作状态…

嵌入式单片机寄存器操作与实现方法

大家好,今天给大家分享一下,单片机中寄存器该如何操作与实现。 “芯片里面的寄存器访问方式一般是: 1.可使用地址访问,2.可使用指令访问,3.不可访问” 第一:挂载到内存地址总线上了的 挂载到内存地址总线上了的,可以使用分配到的地址访问 如下是STM32单片机存储器映像…