ReID:Harmonious Attention Network for Peson Re-Identification 解读

2023-11-18

最近阅读了CVPR2018的这篇论文 Harmonious Attention Network for Peson Re-Identification,论文还是比较容易理解的,下面就简单的解读一下,纯属个人观点,有不同意见的欢迎评论与我探讨~


Problem

  • Existing person re-identification(re-id) methods either assume the availability of well-aligned person bounding box images as model input or rely on constrained attention selection mechanisms to calibrate misaligned images.
  • 现有的re-id方法一般假设人物的bounding box是well-aligned的,或者依赖于constrained attention selection mechanisms去矫正bounding box使它们对齐。
  • They are therefore sub-optimal for re-id matching in arbitrarily aligned person images potentially with large human pose variations and unconstrained auto-detection errors.
  • 因此作者认为它们在re-id matching问题中是局部最优的,潜在的包含大量的human pose variations 和 auto detection errors。
    • Auto-detection: misalignment with background cluster, occlusion, missing body parts
    • Auto Detection会由于混乱背景或者身体部分缺失而出错
  • A small number of attention deep learning models for re-id have been recently developed for reducing the negative effect from poor detection and human pose change
  • 然后就有人尝试attention selection deep learning model in re-id
  • Nevertheless, these deep methods implicitly assume the availability of large labelled training data by simply adopting existing deep architectures with
    high complexity in model design. Additionally, they often consider only coarse region-level attention whilst ignoring the fine-grained pixel-level saliency.
  • 尽管如此,这些deep model复杂度较高,需要的training data较大,并且它们重视region-level attention而忽略了fine-grained pixel-level saliency.
  • Hence, these techniques are ineffective when only a small set of labelled
    data is available for model training whilst also facing noisy person images of arbitrary misalignment and background clutter.
  • 因此,这些方法在训练集较小的时候效率不高,而且还会面临由misalignment和background clutter引起的混乱的图片场景。

总的来说,这篇论文解决的是ReID传统问题。

Motivation

  • Existing works:

    • simply adopting a standard deep CNN network typically with a large number of model parameters and high computational cost in model deployment
    • Consider only coarse region-level attention whilst ignoring the fine-grained pixel-level saliency
  • Our works:

    • We design a lightweight yet deep CNN architecture by devising a holistic attention mechanism for locating the most discriminative pixels and regions in order to identify optimal visual patterns for re-id.
    • The proposed HA-CNN model is designed particularly to address the weakness of existing deep methods as above by formulating a joint learning scheme for modelling both soft and hard attention in a singe re-id deep model.
  • 问题一:现存的方法大多采用传统的CNN,这样带来的影响是:参数过多,计算的代价过大

所以作者提出了HA-CNN网络,该网络是一个lightweight (参数少) 同时又保证了deep(足够深)的特性。

  • 问题二: 现存的方法中,虽然考虑到了hard region-level attention,但pix-level attention 却被忽略了

所以作者提出的HA-CNN网络采用了联合学习hard and soft attention 的scheme,充分考虑hard and soft attention。

Contribution

  • (I) We formulate a novel idea of jointly learning multi-granularity attention selection and feature representation for optimizing person re-id in deep learning.
  • 贡献一:提出了Jointly learning of attention selection 与 feature representation (global && local feature)
  • (II) We propose a Harmonious Attention Convolution Neural Network (HA-CNN) to simultaneously learn hard region-level and soft pixel-level attention within arbitrary person bounding boxes along with re-id feature representations for maximizing the correlated complementary information between attention selection and feature discrimination。
  • 贡献二: 提出了HA-CNN 模型
  • (III) We introduce a cross-attention interaction learning scheme for further enhancing the compatibility between attention selection and feature representation given re-id discriminative constraints.
  • 贡献三:引入了cross-attention interaction

我个人觉得这三点归结起来就是提出了一个较为novel 的 architecture — HA-CNN.下面就详细讲述这个网络。

HA-CNN

HA-CNN

我个人总结了该网络的四个特点:
1. LightWeight (less parameters)
2. Joint learning of global and local features;
3. Joint learning of soft and hard attention;
4. Cross-attention interaction learning scheme between attention selection and feature representation.

该网络是一个多分支网络,包括获取global features 的 global branch 与 获取local features 的 local branches。每个branch的基本单位都是Inception-A/B(某种结构,还有其它结构如ResNet,VGG,AlexNet,你可以看成一个工具箱,能用就行了)。

Global branch 由3个Inception A(深色)与3个Inceprtion B(浅色)构成,还包含3个Harmonious Attention(红色),1个Global average pooing(绿色),1个Fully-Connected Layer(灰色), 最后获得一个512-dim global features。

Local branches 有多条(T branches),每条由3个Inception B(浅色) 和 1个 Global average pooling构成,最后每条分支的输出汇总到一起,通过一个 Fully-Connected Layer以获得512-dim local features.

补充: Global branch 只有一条,Local branches有T条,每条Local branch处理一个region。每一个bounding box可以有T个regions。

然后Global feature 与 Local feature 连接起来获得1024-dim feature,即是HA-CNN的输出。

图中的虚线与红色箭头,将在后面结合HA解释。这里先铺垫一下:Global features 是从 whole image 提取的, Local features 是从 来自于bounding box 的 regions,而这些regions是由HA提供的。即虚线是HA将Regions 发送到前面的结点,然后红线是将这些regions分配到各个Local branches。

讲清楚了这个网络的结构,便能解释它的第一个特点— LightWeight
1. 采用分支网络,参数量的计算由乘法降为加法;
2. Global branch 与 Local branches 共享第一层Conv的参数;
3. Local branches 共享d1, d2, d3的参数。

该网络同时学习Global and Local Features,所以体现了它的第二个特点 — Joint learning of global and local features

补充一下图上参数的注解:
1. di d i 表示filter的数目,也就是channel的数目;
2. 第一层卷积 { 32,33,2} { 32 , 3 ∗ 3 , 2 } 表示32个filters,3*3 卷积核, 2 步长。

在深入了解HA结构之前,我们需要了解一下Attention机制。

什么是Attention?我觉得就是一个衡量信息价值的权重,以确定搜索范围。比如我现在要在一张图片上搜索某个人的脸部,那么这张图像上价值权重最高的部分便是包含脸部的regions,这些regions就是我们的attention,也就是我们的搜索范围。再举个例子,我现在有个包含10个单词的句子,我每个单词赋予一个权重,作为每个单词在这个句子中的价值衡量,权重越大,价值越高。自然,我的Attention就是一个10-dim vector,这也是它的本质。

Attention主要包含两类:Hard attention 与 Soft attention。简单的来说,Hard attention 关注的是 region级别的,Soft attention 关注的是 pixel 级别的。 举个例子:现在有一张聚会的合影,合影背景有各种吃剩的食物,瓶子等。但是你依然能很快的从中发现你认识的人(假如有你认识的人)。这就是一个Hard attention。即你能在非常混乱的背景下找到你认识的人,而没有受到太大干扰。这种确实很适合解决misaligned image。然后再举个阅读理解的例子:先阅读问题,提取出关键字(token),然后回文中查找。你寻找的这些token便是soft attention的体现。

Stack overflow上一段比较形象的解释 Attention

这里写图片描述

HA结构包含四个框:red、yellow、green、black。red 框 代表 soft attention learning, black 框代表 hard attention learning, red框内的green 框代表soft spatial attention, red 框内的yellow 框代表soft channel attention。

下面解释各个框,结合公式可能会好理解一点。

首先来看red 框。(1) green 框的输出 与 yellow 框的输出 进行 multiply op,得到的结果(2) 通过一层卷积层,再 (3) 经过一个Sigmoid获得red框的输出(we use the sigmoid operation to normalise the full soft attention into the range between 0.5 and 1)。公式(1) 描述的是步骤(1).
这里写图片描述
补充: 将 yellow 框与 green 框 的输出 作multiply op 以获得 soft attention,然后经过一层卷积,这层卷积有利于这两种soft attention 的 combination。最后经过sigmoid层,让输出每一分量保持在0.5~1范围。

接着看green 框。(1) HA的输入传入Reduce层(Global cross-channel averaging pooling layer), (2)得到的结果经过一层卷积层,(3)再经过一层Resize层(双线性插值), 最后(4)再经过一层卷积得到 soft spatial attention。公式(2) 描述的是步骤(1)的Reduce层,其实本质上就是一个channels的平均。

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

ReID:Harmonious Attention Network for Peson Re-Identification 解读 的相关文章

随机推荐

  • 最小错误率的贝叶斯决策和最小风险贝叶斯决策的关系?

    1 基于最小错误率的贝叶斯决策 共w1 wn种决策 本质上就是最大后验概率P wi X 的贝叶斯决策 公式一 P wi X P X wi P wi nj 1 P X wj P wj i 1 n j 1 n 2 最小风险的贝叶斯决策 共a1
  • 【MySQL数据库笔记 - 进阶篇】(二)索引

    个人博客 https blog csdn net Newin2020 spm 1011 2415 3001 5343 专栏地址 https blog csdn net Newin2020 article details 127933422
  • centos 7 jenkins安装

    开发十年 就只剩下这套Java开发体系了 gt gt gt 1 添加yum repos 安装 官方文档 https www jenkins io doc book installing linux red hat centos gt sud
  • MongoDB数据库

    MongoDB 一 简介 1 1 Mongodb 是什么 MongoDB 是一个基于分布式文件存储的数据库 官方地址 https www mongodb com 1 2 数据库是什么 数据库 DataBase 是按照数据结构来组织 存储和管
  • Postman使用技巧-环境变量使用

    目录 一 下载安装Postman 二 添加环境与环境变量 三 环境变量使用方法 1 路径中使用变量 2 body中使用变量 3 调用接口前设置变量 4 调用接口后设置变量 一 下载安装Postman 下载安装过程不做赘述 本文章以9 3 1
  • SPWM逆变的原理分析与仿真

    1 单相半桥SPWM逆变电路 1 1 拓扑 下图是单相半桥SPWM逆变电路 含有两个开关管 桥臂中点和直流侧电容中点之间连接负载 输出电压 端口电压 是幅值为0 5Vdc的脉冲波形 1 2 输出电压分析 单相半桥电路的输出电压的主要频率成分
  • 关于QsciScintilla的快捷键设置原理

    经过调试跟踪发现 设置的组合键 修饰键可以是ctrl shift alt的组合 但是第二个键 只能是键值小于0x7f的 从qnamespace文件可知 该按键范围 Key Space Key AsciiTilde 期间包括了各种字母 那么如
  • Unity之自发光Emission效果

    小白欢迎评论 共同探讨 共同进步 写的博文零碎可能比较多 基本是学到啥了写啥 希望可以帮到各位童鞋 同时感谢我看过的各个论坛 博主 同事们的帮助 Unity之自发光Emission效果 很多人都会奇怪 为什么我选了自发光的颜色 强度也调整的
  • Android X86 解决ARM兼容的问题

    最近在Parallels Desktop上安装了64位的Android 9 x86 64 但是很多App只支持arm64 不支持Intel的x86 下面是解决办法 设置中 安卓x86设置 把三个全选上 端口映射5555到Android的55
  • 基于音频和文本的多模态语音情感识别(一篇极好的论文,值得一看哦!)

    基于音频和文本的多模态语音情感识别 语音情感识别是一项具有挑战性的任务 在构建性能良好的分类器时 广泛依赖于使用音频功能的模型 本文提出了一种新的深度双循环编码器模型 该模型同时利用文本数据和音频信号来更好地理解语音数据 由于情感对话是由声
  • EA 的类型/EA 智能交易的介绍(自动化交易/程序化交易/量化交易)

    EA 的类型 EA 智能交易的介绍 自动化交易 程序化交易 量化交易 EA 的类型 1 趋势类 最常见也是最成熟的类型 趋势类 最为主流的 EA 类型 一般根据各种指标和策略来进行出入场操作 2 网格类 网络类的特征 就是单子很多 而且浮亏
  • python引入同一目录下的py文件

    存在一个目录bert base 其中有两个文件 admin py和dealcode py 如果要在admin py中引用dealcode py 则在admin py文件中加一行 from bert base dealcode import
  • 老话新谈之缓存一致性

    前言 缓存一致性常见的更新策略也比较多 如先更新数据库再更新缓存 先删缓存再更新数据库等等 我在理解的时候有些混乱 所以这个文章提供了一些理解上的技巧去理解缓存一致性 为什么会有缓存一致性的问题 缓存与数据库是两套中间件 存在网络抖动之类的
  • java springBoot实现QQ机器人,定时发送信息,自动回复功能

    文末有源码链接 1 准备一个空白springBoot项目 自行百度创建 2 引入simple robot依赖
  • CUJ:标准库:Allocator能做什么?

    http dev csdn net Develop article 17 17946 shtm CUJ 标准库 Allocator能做什么 选择自 taodm 的 Blog http www cuj com experts 1812 aus
  • Qt QModbusTcpServer类

    1 概述 QModbusTcpServer类表示使用TCP服务器与Modbus客户端进行通信的Modbus服务器 Header include
  • 《动手学深度学习 Pytorch版》 3.6 softmax回归的从零开始实现

    import torch from IPython import display from d2l import torch as d2l batch size 256 batch size 设为256 train iter test it
  • PyQt5的tools目录下找不到designer解决方法

    问题描述 用pip安装 pyqt5 和 pyqt5 tools 后 在配置pycharm的external tools的时候找不到designer exe 尝试方法 重装sip pyqt5 以及pyqt5 tools 没有用 安装不同版本的
  • uniApp和微信小程序好看的我的页面(有源码)

    uniApp和微信小程序好看的我的页面 有源码 1 先睹为快 未登录状态 以登录 uniapp源码
  • ReID:Harmonious Attention Network for Peson Re-Identification 解读

    最近阅读了CVPR2018的这篇论文 Harmonious Attention Network for Peson Re Identification 论文还是比较容易理解的 下面就简单的解读一下 纯属个人观点 有不同意见的欢迎评论与我探讨