LoginSignup
2
2

More than 3 years have passed since last update.

【StereoDepth】DSMNet(Domain Norm) : ピクセルレベルのInstanceNorm

Last updated at Posted at 2020-10-18

Domain-invariant Stereo Matching Networks

Pixelレベルの影響が大きいStereo Depth Estimation
そこでDSMNetではDomain Normを提案した

アルゴリズム

image.png
Instance Norm=>Batch NormのBatch size=1の時
Domain Norm=>Instance Normをした後にPixel毎にChannel方向にNormalizationする

数式的に見てみよう

class DomainNorm(nn.Module):
    def __init__(self, channel):
        super(DomainNorm, self).__init__()
        self.instanceNorm = nn.InstanceNorm2d(num_features=channel, affine=False)
    def forward(self, x):
        x = self.instanceNorm(x)
        return F.normalize(x, p=2, dim=1)

InstanceNormした後に最大値の2乗の値で正規化するのか
output = x / Max(x)^2

なるほど~!

一応PytorchのF.normalizeの説明を下に付けときます。
image.png

Stereo Depthへの実装

Feature ExtractionのBatch NormをDomain Normに代える

Domain Normを使うとcolor, style, illuminanceの影響が軽減されるらしい

結果

image.png

Domain NormはChannelをpixel levelで正規化出来ている。

image.png

Domain Normを使うと精度が上がってる。

結論

・Domain Normlizationを使う事でpixel単位でchannelの正規化が出来、精度があがっている。
簡単に実装できるし一般的に有効な気がするけど、あんまり使われてないのはどこかに問題があったりするのかな~?

参考文献

Domain-invariant Stereo Matching Networks
https://arxiv.org/pdf/1911.13287.pdf

normalize(Pytorch実装)
https://pytorch.org/docs/master/nn.functional.html#torch.nn.functional.normalize

DSMNet git
https://github.com/feihuzhang/DSMNet/blob/7b7763c33f74532e2f09983731e9c1543462fbf0/models/DSMNet.py#L17

2
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
2