SlideShare a Scribd company logo
1 of 21
Download to read offline
DEEP LEARNING JP
[DL Papers]
http://deeplearning.jp/
VideoMix: Rethinking Data Augmentation for
Video Classification
Takumi Ohkuma, Nakayama Lab D1
1
書誌情報
• 題名:VideoMix: Rethinking Data Augmentation for Video Classification
• 出典:Arxiv (2020/12/07に投稿)
• 著者:Sangdoo Yun ら5名(韓国のNAVERの研究チーム)
• URL:https://arxiv.org/abs/2012.03457v1
スライド中の出典の明記されていない図表は、本論文の出典である
2
概要
• これまであまり研究されてこなかった動画向けData Augmentation手法に関する研究
• 画像用のData Augmentation手法であるCutMixを拡張し、動画認識に有効なData
Augmentation手法を提案
• 基本的にはAction Recognition (行動分類) に用いる手法であるが、 それ以外にも「Weakly
Supervised Temporal Action Localization」, 及び 「Action Detectionへの転移性能」で、既存
のData Augmentationを上回る精度を実現
3
論文の背景
• 深層学習を持ちいた画像認識では、過学習を防ぎ精度を上げるためにData Augmentation
(DA) が用いられる
• 画像認識に関するDAでは大きな研究成果が報告されている一方、動画認識に対する研究は
殆ど行われてこなかった
(画像に対するDAがそのまま用いられてきた)
• 動画には時間軸が存在する為、画像に対するDAでは見られない方向性への考察余地があり、
より動画にフィットしたDAを提案できる可能性
4
Data Augmentation
• Data Augmentation (DA) は、学習データに変換を加
えることでデータの多様性を増やして学習の精度を
上げる、言わずと知れた深層学習の必須事項
• DAには様々な種類があり、右図に示しているよう
な、左右反転・拡大・回転等が一般的に用いられる
• このようなDAを複数組み合わせるRandAugment [1]
等の手法も提案されており、本研究における比較手
法として用いられている。
大熊 (本スライド作成者) の修士論文より引用
5
Data Augmentation 2
• 本研究では、比較手法として以下のMixup [2], Cutout [3], CutMix [4]も用いている
• Mixupは異なるクラスの二つの画像のRGBの平均を取り、ラベルも平均化する
• Cutoutは画像の一部を欠損させる
• Cutmixは画像の一部を欠損させ、その部分に他のクラスの画像を張り付ける
ラベルは各画像の面積の割合に応じた値とする
[4] より引用
6
VideoMix
• 本論文ではVideoMixと呼ばれる行動分類向けDA手法を提案する
• VideoMixはCutMixの動画向けの拡張手法であり、一つの動画の縦・横に加え時間方向の一部
を欠損させ、その部分にほかの動画を埋め込む
アルゴリズム
1. 入力動画を𝑥 ∊ ℝ𝑇×𝑊×𝐻 (𝑇: フレーム数, 𝑊: 幅, 𝐻: 高さ)、𝑦をクラスラベル (1-hot) とする
2. 訓練データの中から2つの動画 (𝑥𝐴, 𝑦𝐴), (𝑥𝐵, 𝑦𝐵) をランダムにサンプリングする
3. バイナリマスク 𝐌 ∊ {0, 1}𝑇×𝑊×𝐻を定義し、
෤
𝑥 = 𝐌⨀𝑥𝐴 + 1 − 𝐌 ⨀𝑥𝐵, ෤
𝑦 = λ𝐌⨀𝑦𝐴 + 1 − λ𝐌 ⨀𝑦𝐵 とし (෤
𝑥, ෤
𝑦) 変換後のデータとする
ただし、 λ𝐌 =
1
𝑇𝑊𝐻
σ𝑡,𝑤,ℎ 𝐌𝑡,𝑤,ℎ とする(変換後の動画のうち、動画Aの占める体積に相当)
7
VideoMixの種類
VideoMixはCutMixの拡張であり、欠損領域は時間・縦・横に対して直方体とする
具体的には、 𝐌𝑡,𝑤,ℎ ≔ ቊ
1, if 𝑡1 < 𝑡 < 𝑡2, 𝑤1 < 𝑤 < 𝑤2, 𝑎𝑛𝑑 ℎ1 < ℎ < ℎ2
0, 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒
と定義する
𝑡1, 𝑡2, 𝑤1, 𝑤2, ℎ1, ℎ2の値はサンプリングにより決定する(後述)
更にサンプリングを行う次元の組み合わせによって以下の3種類のVideoMixを定義する
1、Spatial VideoMix (w, hに関してサンプリングを行い、(𝑡1, 𝑡2) = (0, T) とする)
2、Temporal VideoMix (tに関してサンプリングを行い、 (𝑤1, 𝑤2, ℎ1, ℎ2) = (0, W, 0, H) とする)
3、Spaito-temporal VideoMix (t, w, hすべてに関してサンプリングを行う)
8
サンプリング方法
• 𝑡, 𝑤, ℎの任意の文字を𝑧, それに対応する𝑇, 𝑊, 𝐻を𝑍と表したとき、以下の手順で𝑧1, 𝑧2のサン
プリングが行われる
1. λをベータ分布𝐵(α, α)からサンプリングする
(本論文ではα = 1としており、この場合一様分布𝑈𝑛𝑖𝑓(0, 1)と等しくなる)
2. 𝑧𝑐を一様分布𝑈𝑛𝑖𝑓(0, 𝑍)からサンプリングする
3. サンプリングで得られたλ, 𝑧𝑐を用いて
𝑧1 = max 0, 𝑧𝑐 −
𝑍 λ
2
, 𝑧2 = min 𝑍, 𝑧𝑐 +
𝑍 λ
2
と定義する
これにより、 𝑧𝑐を中心として前後
𝑍 λ
2
の区間が欠損する
この作業を必要な𝑡, 𝑤, ℎに対して行う
9
実験
• Action Recognition (行動分類) 用データセット Kinetics-400 [5] 及びそのsubsetであるmini-
Kinetics-200に対する実験がメイン
(Kinetics-400は、400クラス, 240K train, 20K validation動画からなるデータセット)
(mini-Kinetics-200は、200クラス, 80K train, 5K validation動画からなるデータセット)
• (本資料では詳しく説明しないが)SlowOnly [6], SlowFast [6], ip-CSN [7] という、高い精度
を達成している3DCNNベースの行動分類モデルを用いる
• Spatial VideoMix, Temporal VideoMix, 及び Spaito-temporal VideoMix について実験を行い、
最も性能の良いものを提案手法VideoMixとして扱う
• VideoMixの有効性を示すために、RandAugment, Mixup, Cutout, CutMixとの精度比較を行う
10
結果
• 右の表はmini-Kinetics-200に対する結果を示す
(モデルはSlowOnly-34 (8×8))
• 三種類ののVideoMixの精度比較に関しては
Spatial VideoMixが最も精度が高い
• Spatial VideoMixを提案手法として扱い、
以降単にVideoMixと表記する
• 他のDAとの比較した結果、VideoMixを用いた
場合の精度がTop1, Top5共に最も高い
3種類のVideoMixの比較
他のDAとの比較
11
結果2
• 前スライドではSlowOnly-34 (8×8)に対する有効性を示
したが、他の4種類のモデルに対しても手法の優位性を
確認できる
• λのサンプリングに用いたαは、精度にあまり影響を及
ぼさない
• Mixする確率を0.5とすると少し精度が下がる
(デフォルトは1.0)
• 3つ以上に動画をMixするのは有効ではない
(大きく精度が下がる)
• 時間的な方向を無視して各フレームごとにMixを行うと
精度が下がる(Per-frame VideoMix)
モデルを変えた場合の比較
条件を変えた場合の比較
12
考察
• Epoch数とValidation loss と acc.を比較して、過学習を防
いでいると主張しているが、ちょっと納得できない
(精度は上がっているが、過学習との関係性が不明瞭)
• spatio-temporal CAM [8] を用いてモデルがとこに着目し
ているかを可視化
(CAMは特徴マップのActivation値を、各クラスに対し
て可視化する手法)
• 「ハーモニカ演奏」と「アメフトのパス」のMixに対す
る可視化の例では、ハーモニカの手や口部分、アメフト
ボールが存在するフレームに対してフォーカスが集まり、
背景部分のみからの判断が防がれている
• w/o VideoMixとの比較も見てみたい
13
Weakly Supervised Temporal Action Localization
• Weakly Supervised Temporal Action Localization (WSTAL) は、クラスラベルのみが付与され
た動画を学習に用い(Weakly Supervised)、特定のアクションが行われているフレームを
検出する(Temporal Action Localization)タスク
• データセットはTHUMOS’14 [9]、手法は I3D T-CAM [10]を用いる
(THUMOS’14 は101クラスのアクションラベルと正解フレームラベルを持っているが、今
回の学習では、正解フレームラベルは用いない)
• 本タスクではTemporal VideoMix (Spatialではない) を用いて行動分類タスクの学習を行い、
学習されたモデルのT-CAMを用いて、アクションが行われている区間の予測を行う
14
結果
• 右の表に結果を示す
(Optical Flowを使う場合と使わない場合に分けて
示している)
• 比較対象はMixupと、WSTAL向けに提案されたDA手
法であるHide-and-Seek [11] である
(Hide-and-Seekは、画像をパッチに分割してその
一部を隠すという手法で、Cutoutと似ている)
• VideoMixはここでも優位な精度を実現した
15
Action Detection
• Action Detectionは、特定の動作が行われているフレーム及び場所 (Bounding Box) を予測す
るタスク
• 本タスクでは、Kinetics-400を用いた行動分類タスクによる事前学習を行い、その際に
VideoMixを用いる
(Action Detectionでは動画の一部を欠損させるわけにはいかないので、Fine-tuningでは
VideoMixを用いない)
• データセットはAVA v2.2 [12]、モデルはBackboneにSlowOnlyやSlowFastを用いたFaster R-
CNN [13] の三次元拡張モデル用いる(詳細は割愛)
16
結果
• 右図に結果より、VideoMixを用いたPretrainingを
行った場合の方が精度が高いことが確認できる
• これによりVideoMixを用いた学習は、行動分類以外
の動画タスクに対する転移性能を上げる効果もある
ことが確認できた
17
まとめ
• 今まであまり研究されてこなかった動画に対するDAに着目した研究
• 画像を欠損させ、別の画像を挿入するCutMixと呼ばれるDAを行動分類向けに拡張した手法
VIdeoMixを提案し、有効性を確認
• VideoMixは行動分類以外にも、Weakly Supervised Temporal Action Localizationや、Action
Detectionに対する事前学習といった幅広い動画認識タスクに対して有効であることが確か
められた(下図参照)
18
感想
• Simple is Best というしかない結果が得られている
• 結局手法に関する新規性は、CutMixをシンプルに動画へ拡張し、最も精度の高いSpatial CutMixを
提案手法としているくらい?
• 複雑な試みは悉く精度につながっていない(3動画以上の混合、複雑なベータ分布)
• 考察に関してはやや弱いような気がする
• 精度の上がった理由を無理やりこじつけてる感が否めない
• 動画×DAの方向性はまだできることが沢山ありそう
19
引用
1. Ekin D Cubuk, Barret Zoph, Jonathon Shlens, and Quoc V Le. Randaugment: Practical data augmentation with no separate search.
arXiv preprint arXiv:1909.13719, 2019.
2. Hongyi Zhang, Moustapha Cisse, Yann N Dauphin, and David Lopez-Paz. mixup: Beyond empirical risk minimization. arXiv preprint
arXiv:1710.09412, 2017.
3. Terrance DeVries and Graham W Taylor. Improved regularization of convolutional neural networks with cutout. arXiv preprint
arXiv:1708.04552, 2017.
4. Sangdoo Yun, Dongyoon Han, Seong Joon Oh, Sanghyuk Chun, Junsuk Choe, and Youngjoon Yoo. Cutmix: Regularization strategy
to train strong classifiers with localizable features. In Proceedings of the IEEE International Conference on Computer Vision, pages
6023–6032, 2019.
5. Will Kay, Joao Carreira, Karen Simonyan, Brian Zhang, Chloe Hillier, Sudheendra Vijayanarasimhan, Fabio Viola, Tim Green, Trevor
Back, Paul Natsev, et al. The kinetics human action video dataset. arXiv preprint arXiv:1705.06950, 2017.
6. Christoph Feichtenhofer, Haoqi Fan, Jitendra Malik, and Kaiming He. Slowfast networks for video recognition. In Proceedings of the
IEEE International Conference on Computer Vision, pages 6202–6211, 2019.
7. Du Tran, Heng Wang, Lorenzo Torresani, and Matt Feiszli. Video classification with channel-separated convolutional networks. In
Proceedings of the IEEE International Conference on Computer Vision, pages 5552–5561, 2019.
20
引用
8. Bolei Zhou, Aditya Khosla, Agata Lapedriza, Aude Oliva, and Antonio Torralba. Learning deep features for discriminative localization.
In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 2921–2929, 2016.
9. Y.-G. Jiang, J. Liu, A. Roshan Zamir, G. Toderici, I. Laptev, M. Shah, and R. Sukthankar. THUMOS challenge: Action recognition with a
large number of classes. http://crcv.ucf.edu/THUMOS14/, 2014.
10. Joao Carreira and Andrew Zisserman. Quo vadis, action recognition? a new model and the kinetics dataset. In proceedings of the
IEEE Conference on Computer Vision and Pattern Recognition, pages 6299–6308, 2017.
11. Krishna Kumar Singh and Yong Jae Lee. Hide-and-seek: Forcing a network to be meticulous for weakly-supervised object and
action localization. In 2017 IEEE International Conference on Computer Vision, pages 3544–3553. IEEE, 2017.
12. Chunhui Gu, Chen Sun, David A Ross, Carl Vondrick, Caroline Pantofaru, Yeqing Li, Sudheendra Vijayanarasimhan, George Toderici,
Susanna Ricco, Rahul Sukthankar, et al. Ava: A video dataset of spatio-temporally localized atomic visual actions. In Proceedings of
the IEEE Conference on Computer Vision and Pattern Recognition, pages 6047– 6056, 2018.
13. Shaoqing Ren, Kaiming He, Ross Girshick, and Jian Sun. Faster r-cnn: Towards real-time object detection with region proposal
networks. In Advances in neural information processing systems, pages 91–99, 2015.
21

More Related Content

More from Deep Learning JP

More from Deep Learning JP (20)

【DL輪読会】Can Neural Network Memorization Be Localized?
【DL輪読会】Can Neural Network Memorization Be Localized?【DL輪読会】Can Neural Network Memorization Be Localized?
【DL輪読会】Can Neural Network Memorization Be Localized?
 
【DL輪読会】Hopfield network 関連研究について
【DL輪読会】Hopfield network 関連研究について【DL輪読会】Hopfield network 関連研究について
【DL輪読会】Hopfield network 関連研究について
 
【DL輪読会】SimPer: Simple self-supervised learning of periodic targets( ICLR 2023 )
【DL輪読会】SimPer: Simple self-supervised learning of periodic targets( ICLR 2023 )【DL輪読会】SimPer: Simple self-supervised learning of periodic targets( ICLR 2023 )
【DL輪読会】SimPer: Simple self-supervised learning of periodic targets( ICLR 2023 )
 
【DL輪読会】RLCD: Reinforcement Learning from Contrast Distillation for Language M...
【DL輪読会】RLCD: Reinforcement Learning from Contrast Distillation for Language M...【DL輪読会】RLCD: Reinforcement Learning from Contrast Distillation for Language M...
【DL輪読会】RLCD: Reinforcement Learning from Contrast Distillation for Language M...
 
【DL輪読会】"Secrets of RLHF in Large Language Models Part I: PPO"
【DL輪読会】"Secrets of RLHF in Large Language Models Part I: PPO"【DL輪読会】"Secrets of RLHF in Large Language Models Part I: PPO"
【DL輪読会】"Secrets of RLHF in Large Language Models Part I: PPO"
 
【DL輪読会】"Language Instructed Reinforcement Learning for Human-AI Coordination "
【DL輪読会】"Language Instructed Reinforcement Learning  for Human-AI Coordination "【DL輪読会】"Language Instructed Reinforcement Learning  for Human-AI Coordination "
【DL輪読会】"Language Instructed Reinforcement Learning for Human-AI Coordination "
 
【DL輪読会】Llama 2: Open Foundation and Fine-Tuned Chat Models
【DL輪読会】Llama 2: Open Foundation and Fine-Tuned Chat Models【DL輪読会】Llama 2: Open Foundation and Fine-Tuned Chat Models
【DL輪読会】Llama 2: Open Foundation and Fine-Tuned Chat Models
 
【DL輪読会】"Learning Fine-Grained Bimanual Manipulation with Low-Cost Hardware"
【DL輪読会】"Learning Fine-Grained Bimanual Manipulation with Low-Cost Hardware"【DL輪読会】"Learning Fine-Grained Bimanual Manipulation with Low-Cost Hardware"
【DL輪読会】"Learning Fine-Grained Bimanual Manipulation with Low-Cost Hardware"
 
【DL輪読会】Parameter is Not All You Need:Starting from Non-Parametric Networks fo...
【DL輪読会】Parameter is Not All You Need:Starting from Non-Parametric Networks fo...【DL輪読会】Parameter is Not All You Need:Starting from Non-Parametric Networks fo...
【DL輪読会】Parameter is Not All You Need:Starting from Non-Parametric Networks fo...
 
【DL輪読会】Drag Your GAN: Interactive Point-based Manipulation on the Generative ...
【DL輪読会】Drag Your GAN: Interactive Point-based Manipulation on the Generative ...【DL輪読会】Drag Your GAN: Interactive Point-based Manipulation on the Generative ...
【DL輪読会】Drag Your GAN: Interactive Point-based Manipulation on the Generative ...
 
【DL輪読会】Self-Supervised Learning from Images with a Joint-Embedding Predictive...
【DL輪読会】Self-Supervised Learning from Images with a Joint-Embedding Predictive...【DL輪読会】Self-Supervised Learning from Images with a Joint-Embedding Predictive...
【DL輪読会】Self-Supervised Learning from Images with a Joint-Embedding Predictive...
 
【DL輪読会】Towards Understanding Ensemble, Knowledge Distillation and Self-Distil...
【DL輪読会】Towards Understanding Ensemble, Knowledge Distillation and Self-Distil...【DL輪読会】Towards Understanding Ensemble, Knowledge Distillation and Self-Distil...
【DL輪読会】Towards Understanding Ensemble, Knowledge Distillation and Self-Distil...
 
【DL輪読会】VIP: Towards Universal Visual Reward and Representation via Value-Impl...
【DL輪読会】VIP: Towards Universal Visual Reward and Representation via Value-Impl...【DL輪読会】VIP: Towards Universal Visual Reward and Representation via Value-Impl...
【DL輪読会】VIP: Towards Universal Visual Reward and Representation via Value-Impl...
 
【DL輪読会】Deep Transformers without Shortcuts: Modifying Self-attention for Fait...
【DL輪読会】Deep Transformers without Shortcuts: Modifying Self-attention for Fait...【DL輪読会】Deep Transformers without Shortcuts: Modifying Self-attention for Fait...
【DL輪読会】Deep Transformers without Shortcuts: Modifying Self-attention for Fait...
 
【DL輪読会】マルチモーダル 基盤モデル
【DL輪読会】マルチモーダル 基盤モデル【DL輪読会】マルチモーダル 基盤モデル
【DL輪読会】マルチモーダル 基盤モデル
 
【DL輪読会】TrOCR: Transformer-based Optical Character Recognition with Pre-traine...
【DL輪読会】TrOCR: Transformer-based Optical Character Recognition with Pre-traine...【DL輪読会】TrOCR: Transformer-based Optical Character Recognition with Pre-traine...
【DL輪読会】TrOCR: Transformer-based Optical Character Recognition with Pre-traine...
 
【DL輪読会】HyperDiffusion: Generating Implicit Neural Fields withWeight-Space Dif...
【DL輪読会】HyperDiffusion: Generating Implicit Neural Fields withWeight-Space Dif...【DL輪読会】HyperDiffusion: Generating Implicit Neural Fields withWeight-Space Dif...
【DL輪読会】HyperDiffusion: Generating Implicit Neural Fields withWeight-Space Dif...
 
【DL輪読会】大量API・ツールの扱いに特化したLLM
【DL輪読会】大量API・ツールの扱いに特化したLLM【DL輪読会】大量API・ツールの扱いに特化したLLM
【DL輪読会】大量API・ツールの扱いに特化したLLM
 
【DL輪読会】DINOv2: Learning Robust Visual Features without Supervision
【DL輪読会】DINOv2: Learning Robust Visual Features without Supervision【DL輪読会】DINOv2: Learning Robust Visual Features without Supervision
【DL輪読会】DINOv2: Learning Robust Visual Features without Supervision
 
【DL輪読会】Poisoning Language Models During Instruction Tuning Instruction Tuning...
【DL輪読会】Poisoning Language Models During Instruction Tuning Instruction Tuning...【DL輪読会】Poisoning Language Models During Instruction Tuning Instruction Tuning...
【DL輪読会】Poisoning Language Models During Instruction Tuning Instruction Tuning...
 

Recently uploaded

Recently uploaded (20)

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 

【DL輪読会】VideoMix: Rethinking Data Augmentation for Video Classification

  • 1. DEEP LEARNING JP [DL Papers] http://deeplearning.jp/ VideoMix: Rethinking Data Augmentation for Video Classification Takumi Ohkuma, Nakayama Lab D1 1
  • 2. 書誌情報 • 題名:VideoMix: Rethinking Data Augmentation for Video Classification • 出典:Arxiv (2020/12/07に投稿) • 著者:Sangdoo Yun ら5名(韓国のNAVERの研究チーム) • URL:https://arxiv.org/abs/2012.03457v1 スライド中の出典の明記されていない図表は、本論文の出典である 2
  • 3. 概要 • これまであまり研究されてこなかった動画向けData Augmentation手法に関する研究 • 画像用のData Augmentation手法であるCutMixを拡張し、動画認識に有効なData Augmentation手法を提案 • 基本的にはAction Recognition (行動分類) に用いる手法であるが、 それ以外にも「Weakly Supervised Temporal Action Localization」, 及び 「Action Detectionへの転移性能」で、既存 のData Augmentationを上回る精度を実現 3
  • 4. 論文の背景 • 深層学習を持ちいた画像認識では、過学習を防ぎ精度を上げるためにData Augmentation (DA) が用いられる • 画像認識に関するDAでは大きな研究成果が報告されている一方、動画認識に対する研究は 殆ど行われてこなかった (画像に対するDAがそのまま用いられてきた) • 動画には時間軸が存在する為、画像に対するDAでは見られない方向性への考察余地があり、 より動画にフィットしたDAを提案できる可能性 4
  • 5. Data Augmentation • Data Augmentation (DA) は、学習データに変換を加 えることでデータの多様性を増やして学習の精度を 上げる、言わずと知れた深層学習の必須事項 • DAには様々な種類があり、右図に示しているよう な、左右反転・拡大・回転等が一般的に用いられる • このようなDAを複数組み合わせるRandAugment [1] 等の手法も提案されており、本研究における比較手 法として用いられている。 大熊 (本スライド作成者) の修士論文より引用 5
  • 6. Data Augmentation 2 • 本研究では、比較手法として以下のMixup [2], Cutout [3], CutMix [4]も用いている • Mixupは異なるクラスの二つの画像のRGBの平均を取り、ラベルも平均化する • Cutoutは画像の一部を欠損させる • Cutmixは画像の一部を欠損させ、その部分に他のクラスの画像を張り付ける ラベルは各画像の面積の割合に応じた値とする [4] より引用 6
  • 7. VideoMix • 本論文ではVideoMixと呼ばれる行動分類向けDA手法を提案する • VideoMixはCutMixの動画向けの拡張手法であり、一つの動画の縦・横に加え時間方向の一部 を欠損させ、その部分にほかの動画を埋め込む アルゴリズム 1. 入力動画を𝑥 ∊ ℝ𝑇×𝑊×𝐻 (𝑇: フレーム数, 𝑊: 幅, 𝐻: 高さ)、𝑦をクラスラベル (1-hot) とする 2. 訓練データの中から2つの動画 (𝑥𝐴, 𝑦𝐴), (𝑥𝐵, 𝑦𝐵) をランダムにサンプリングする 3. バイナリマスク 𝐌 ∊ {0, 1}𝑇×𝑊×𝐻を定義し、 ෤ 𝑥 = 𝐌⨀𝑥𝐴 + 1 − 𝐌 ⨀𝑥𝐵, ෤ 𝑦 = λ𝐌⨀𝑦𝐴 + 1 − λ𝐌 ⨀𝑦𝐵 とし (෤ 𝑥, ෤ 𝑦) 変換後のデータとする ただし、 λ𝐌 = 1 𝑇𝑊𝐻 σ𝑡,𝑤,ℎ 𝐌𝑡,𝑤,ℎ とする(変換後の動画のうち、動画Aの占める体積に相当) 7
  • 8. VideoMixの種類 VideoMixはCutMixの拡張であり、欠損領域は時間・縦・横に対して直方体とする 具体的には、 𝐌𝑡,𝑤,ℎ ≔ ቊ 1, if 𝑡1 < 𝑡 < 𝑡2, 𝑤1 < 𝑤 < 𝑤2, 𝑎𝑛𝑑 ℎ1 < ℎ < ℎ2 0, 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒 と定義する 𝑡1, 𝑡2, 𝑤1, 𝑤2, ℎ1, ℎ2の値はサンプリングにより決定する(後述) 更にサンプリングを行う次元の組み合わせによって以下の3種類のVideoMixを定義する 1、Spatial VideoMix (w, hに関してサンプリングを行い、(𝑡1, 𝑡2) = (0, T) とする) 2、Temporal VideoMix (tに関してサンプリングを行い、 (𝑤1, 𝑤2, ℎ1, ℎ2) = (0, W, 0, H) とする) 3、Spaito-temporal VideoMix (t, w, hすべてに関してサンプリングを行う) 8
  • 9. サンプリング方法 • 𝑡, 𝑤, ℎの任意の文字を𝑧, それに対応する𝑇, 𝑊, 𝐻を𝑍と表したとき、以下の手順で𝑧1, 𝑧2のサン プリングが行われる 1. λをベータ分布𝐵(α, α)からサンプリングする (本論文ではα = 1としており、この場合一様分布𝑈𝑛𝑖𝑓(0, 1)と等しくなる) 2. 𝑧𝑐を一様分布𝑈𝑛𝑖𝑓(0, 𝑍)からサンプリングする 3. サンプリングで得られたλ, 𝑧𝑐を用いて 𝑧1 = max 0, 𝑧𝑐 − 𝑍 λ 2 , 𝑧2 = min 𝑍, 𝑧𝑐 + 𝑍 λ 2 と定義する これにより、 𝑧𝑐を中心として前後 𝑍 λ 2 の区間が欠損する この作業を必要な𝑡, 𝑤, ℎに対して行う 9
  • 10. 実験 • Action Recognition (行動分類) 用データセット Kinetics-400 [5] 及びそのsubsetであるmini- Kinetics-200に対する実験がメイン (Kinetics-400は、400クラス, 240K train, 20K validation動画からなるデータセット) (mini-Kinetics-200は、200クラス, 80K train, 5K validation動画からなるデータセット) • (本資料では詳しく説明しないが)SlowOnly [6], SlowFast [6], ip-CSN [7] という、高い精度 を達成している3DCNNベースの行動分類モデルを用いる • Spatial VideoMix, Temporal VideoMix, 及び Spaito-temporal VideoMix について実験を行い、 最も性能の良いものを提案手法VideoMixとして扱う • VideoMixの有効性を示すために、RandAugment, Mixup, Cutout, CutMixとの精度比較を行う 10
  • 11. 結果 • 右の表はmini-Kinetics-200に対する結果を示す (モデルはSlowOnly-34 (8×8)) • 三種類ののVideoMixの精度比較に関しては Spatial VideoMixが最も精度が高い • Spatial VideoMixを提案手法として扱い、 以降単にVideoMixと表記する • 他のDAとの比較した結果、VideoMixを用いた 場合の精度がTop1, Top5共に最も高い 3種類のVideoMixの比較 他のDAとの比較 11
  • 12. 結果2 • 前スライドではSlowOnly-34 (8×8)に対する有効性を示 したが、他の4種類のモデルに対しても手法の優位性を 確認できる • λのサンプリングに用いたαは、精度にあまり影響を及 ぼさない • Mixする確率を0.5とすると少し精度が下がる (デフォルトは1.0) • 3つ以上に動画をMixするのは有効ではない (大きく精度が下がる) • 時間的な方向を無視して各フレームごとにMixを行うと 精度が下がる(Per-frame VideoMix) モデルを変えた場合の比較 条件を変えた場合の比較 12
  • 13. 考察 • Epoch数とValidation loss と acc.を比較して、過学習を防 いでいると主張しているが、ちょっと納得できない (精度は上がっているが、過学習との関係性が不明瞭) • spatio-temporal CAM [8] を用いてモデルがとこに着目し ているかを可視化 (CAMは特徴マップのActivation値を、各クラスに対し て可視化する手法) • 「ハーモニカ演奏」と「アメフトのパス」のMixに対す る可視化の例では、ハーモニカの手や口部分、アメフト ボールが存在するフレームに対してフォーカスが集まり、 背景部分のみからの判断が防がれている • w/o VideoMixとの比較も見てみたい 13
  • 14. Weakly Supervised Temporal Action Localization • Weakly Supervised Temporal Action Localization (WSTAL) は、クラスラベルのみが付与され た動画を学習に用い(Weakly Supervised)、特定のアクションが行われているフレームを 検出する(Temporal Action Localization)タスク • データセットはTHUMOS’14 [9]、手法は I3D T-CAM [10]を用いる (THUMOS’14 は101クラスのアクションラベルと正解フレームラベルを持っているが、今 回の学習では、正解フレームラベルは用いない) • 本タスクではTemporal VideoMix (Spatialではない) を用いて行動分類タスクの学習を行い、 学習されたモデルのT-CAMを用いて、アクションが行われている区間の予測を行う 14
  • 15. 結果 • 右の表に結果を示す (Optical Flowを使う場合と使わない場合に分けて 示している) • 比較対象はMixupと、WSTAL向けに提案されたDA手 法であるHide-and-Seek [11] である (Hide-and-Seekは、画像をパッチに分割してその 一部を隠すという手法で、Cutoutと似ている) • VideoMixはここでも優位な精度を実現した 15
  • 16. Action Detection • Action Detectionは、特定の動作が行われているフレーム及び場所 (Bounding Box) を予測す るタスク • 本タスクでは、Kinetics-400を用いた行動分類タスクによる事前学習を行い、その際に VideoMixを用いる (Action Detectionでは動画の一部を欠損させるわけにはいかないので、Fine-tuningでは VideoMixを用いない) • データセットはAVA v2.2 [12]、モデルはBackboneにSlowOnlyやSlowFastを用いたFaster R- CNN [13] の三次元拡張モデル用いる(詳細は割愛) 16
  • 18. まとめ • 今まであまり研究されてこなかった動画に対するDAに着目した研究 • 画像を欠損させ、別の画像を挿入するCutMixと呼ばれるDAを行動分類向けに拡張した手法 VIdeoMixを提案し、有効性を確認 • VideoMixは行動分類以外にも、Weakly Supervised Temporal Action Localizationや、Action Detectionに対する事前学習といった幅広い動画認識タスクに対して有効であることが確か められた(下図参照) 18
  • 19. 感想 • Simple is Best というしかない結果が得られている • 結局手法に関する新規性は、CutMixをシンプルに動画へ拡張し、最も精度の高いSpatial CutMixを 提案手法としているくらい? • 複雑な試みは悉く精度につながっていない(3動画以上の混合、複雑なベータ分布) • 考察に関してはやや弱いような気がする • 精度の上がった理由を無理やりこじつけてる感が否めない • 動画×DAの方向性はまだできることが沢山ありそう 19
  • 20. 引用 1. Ekin D Cubuk, Barret Zoph, Jonathon Shlens, and Quoc V Le. Randaugment: Practical data augmentation with no separate search. arXiv preprint arXiv:1909.13719, 2019. 2. Hongyi Zhang, Moustapha Cisse, Yann N Dauphin, and David Lopez-Paz. mixup: Beyond empirical risk minimization. arXiv preprint arXiv:1710.09412, 2017. 3. Terrance DeVries and Graham W Taylor. Improved regularization of convolutional neural networks with cutout. arXiv preprint arXiv:1708.04552, 2017. 4. Sangdoo Yun, Dongyoon Han, Seong Joon Oh, Sanghyuk Chun, Junsuk Choe, and Youngjoon Yoo. Cutmix: Regularization strategy to train strong classifiers with localizable features. In Proceedings of the IEEE International Conference on Computer Vision, pages 6023–6032, 2019. 5. Will Kay, Joao Carreira, Karen Simonyan, Brian Zhang, Chloe Hillier, Sudheendra Vijayanarasimhan, Fabio Viola, Tim Green, Trevor Back, Paul Natsev, et al. The kinetics human action video dataset. arXiv preprint arXiv:1705.06950, 2017. 6. Christoph Feichtenhofer, Haoqi Fan, Jitendra Malik, and Kaiming He. Slowfast networks for video recognition. In Proceedings of the IEEE International Conference on Computer Vision, pages 6202–6211, 2019. 7. Du Tran, Heng Wang, Lorenzo Torresani, and Matt Feiszli. Video classification with channel-separated convolutional networks. In Proceedings of the IEEE International Conference on Computer Vision, pages 5552–5561, 2019. 20
  • 21. 引用 8. Bolei Zhou, Aditya Khosla, Agata Lapedriza, Aude Oliva, and Antonio Torralba. Learning deep features for discriminative localization. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 2921–2929, 2016. 9. Y.-G. Jiang, J. Liu, A. Roshan Zamir, G. Toderici, I. Laptev, M. Shah, and R. Sukthankar. THUMOS challenge: Action recognition with a large number of classes. http://crcv.ucf.edu/THUMOS14/, 2014. 10. Joao Carreira and Andrew Zisserman. Quo vadis, action recognition? a new model and the kinetics dataset. In proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 6299–6308, 2017. 11. Krishna Kumar Singh and Yong Jae Lee. Hide-and-seek: Forcing a network to be meticulous for weakly-supervised object and action localization. In 2017 IEEE International Conference on Computer Vision, pages 3544–3553. IEEE, 2017. 12. Chunhui Gu, Chen Sun, David A Ross, Carl Vondrick, Caroline Pantofaru, Yeqing Li, Sudheendra Vijayanarasimhan, George Toderici, Susanna Ricco, Rahul Sukthankar, et al. Ava: A video dataset of spatio-temporally localized atomic visual actions. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 6047– 6056, 2018. 13. Shaoqing Ren, Kaiming He, Ross Girshick, and Jian Sun. Faster r-cnn: Towards real-time object detection with region proposal networks. In Advances in neural information processing systems, pages 91–99, 2015. 21