MDNet网络

MDNet: A Semantically and Visually Interpretable Medical Image Diagnosis Network

ResNet

在这里插入图片描述

y l = F l ( x l ) + h ( x l ) (1) y_{l}= F_{l}(x_{l})+h(x_{l}) \tag{1} yl=Fl(xl)+h(xl)(1)

x l + 1 = f ( y l ) (2) x_{l+1}=f(y_{l}) \tag{2} xl+1=f(yl)(2)
其中f和h是恒等映射,即
x l + 1 = y l = x l + F l ( x l ) (3) x_{l+1}=y_{l}=x_{l}+F_{l}(x_{l}) \tag{3} xl+1=yl=xl+Fl(xl)(3)
其中
x l = x l − 1 + F l ( x l − 1 ) i . e . , x l + 1 = x l − 1 + F l ( x l ) + F ( x l − 1 ) (4) x_{l}=x_{l-1}+F_{l}(x_{l-1})\\ i.e., x_{l+1}=x_{l-1}+F_{l}(x_{l})+F(x_{l-1}) \tag{4} xl=xl1+Fl(xl1)i.e.,xl+1=xl1+Fl(xl)+F(xl1)(4)
由此推出
x L = x l + ∑ i = l L − 1 F l ( x i ) (5) x_{L}=x_{l}+\sum_{i=l}^{L-1}F_{l}(x_{i}) \tag{5} xL=xl+i=lL1Fl(xi)(5)
反向传播:
∂ L ∂ x l = ∂ L ∂ x L ∂ x L ∂ x l = ∂ L ∂ x L ( 1 + ∂ ∂ x l ∑ i = l L − 1 F l ( x i ) ) (6) \frac{\partial\mathcal{L}}{\partial x_{l}}=\frac{\partial\mathcal{L}}{\partial x_{L}}\frac{\partial x_{L}}{\partial x_{l}}=\frac{\partial\mathcal{L}}{\partial x_{L}}\left(1+\frac{\partial}{\partial x_{l}}\sum_{i=l}^{L-1}F_{l}(x_{i})\right) \tag{6} xlL=xLLxlxL=xLL(1+xli=lL1Fl(xi))(6)

Decouple ensemble network outputs

p c = ∑ k w k c ⋅ ∑ i , j y L ( k ) ( i , j ) (7) p^{c}=\sum_{k}w_{k}^{c}\cdot \sum_{i,j}y_{L}^{(k)}(i,j) \tag{7} pc=kwkci,jyL(k)(i,j)(7)

其中 p c p^{c} pc是类别 c c c的输出概率, ( i , j ) (i,j) (i,j)表示空间坐标。 w c = [ w 1 c , ⋯   , w k c , ⋯   ] T \mathcal{w}^{c}=[w_{1}^{c},\cdots,w_{k}^{c},\cdots]^{T} wc=[w1c,,wkc,]T是全连接层的第 c c c列权重矩阵。
y L k y_{L}^{k} yLk是最后的残差块的第 k k k个特征图。

把公式(5)代入到(7)中,推出 :
p c = ∑ i , j w c ⋅ y L = ∑ i , j w c ( y 1 + ∑ m = 1 L − 1 F m ( y m ) ) (8) p^{c}=\sum_{i,j}w^{c}\cdot y_{L}=\sum_{i,j}w^{c}(y_{1}+\sum_{m=1}^{L-1}F_{m}(y_{m})) \tag{8} pc=i,jwcyL=i,jwc(y1+m=1L1Fm(ym))(8)
文章中指出了ResNet的一个缺点: Using a single weighting function in the classification module is suboptimal in this situation. This is because the outputs of all ensembles share classifiers such that the importance of their individual features are undermined.

To address this issue, they propose to decouple the ensemble outputs and apply classifiers to them individually by using:
p c = ∑ i , j ( w 1 c ⋅ y 1 + ∑ m = 1 L − 1 w m + 1 c ⋅ F m ( y m ) ) (9) p^c=\sum_{i,j}\left(\boldsymbol{w}_{1}^{c}\cdot y_{1}+\sum_{m=1}^{L-1}\boldsymbol{w}_{m+1}^{c}\cdot F_{m}(y_{m})\right) \tag{9} pc=i,j(w1cy1+m=1L1wm+1cFm(ym))(9)
同时提出一个新的 skip-connection,定义如下:
y l + 1 = F l ( y l ) ⊗ y l (10) y_{l+1}=F_{l}(y_{l})\otimes y_{l} \tag{10} yl+1=Fl(yl)yl(10)
where ⊗ \otimes is the concatenation operation. And defining this skip-connection scheme as ensemble-connection.

Language model

log ⁡ p ( x 0 : T ∣ I ; θ L ) = ∑ t = 0 T log ⁡ p ( x t ∣ I , x 0 : t − 1 ; θ L ) (11) \log p(\boldsymbol{x}_{0:T}\mid I;\theta_{L})=\sum_{t=0}^{T}\log p(\boldsymbol{x}_{t}\mid I,\boldsymbol{x}_{0:t-1}; \theta_{L}) \tag{11} logp(x0:TI;θL)=t=0Tlogp(xtI,x0:t1;θL)(11)

where { x 0 , ⋯   , x T } \left\{\boldsymbol{x}_{0},\cdots,\boldsymbol{x}_{T}\right\} {x0,,xT} are sentence words, θ L \theta_{L} θL are the parameters of LSTM.
h t = L S T M ( E x t − 1 , h t − 1 , z t ) (12) \boldsymbol{h}_{t}=LSTM(E\boldsymbol{x}_{t-1},\boldsymbol{h}_{t-1},\boldsymbol{z}_{t}) \tag{12} ht=LSTM(Ext1,ht1,zt)(12)
where E E E is the word embedding matrix, z t \boldsymbol{z}_{t} zt is a context vector.
z t = a t C ( I ) T (13) \boldsymbol{z}_{t}=\boldsymbol{a}_{t}\mathcal{C}(I)_{T} \tag{13} zt=atC(I)T(13)
where C ( I ) \mathcal{C}(I) C(I) is the Conv feature maps generated by the image model (stands for y L y_{L} yL).
a t = s o f t m a x ( W a t t t a n h ( W h h t − 1 + c ) ) c = ( w c ) T C ( I ) (14) \boldsymbol{a}_{t}=softmax(W_{att}tanh(W_{h}\boldsymbol{h}_{t-1}+\mathcal{c})) \\ \boldsymbol{c}=(\boldsymbol{w}^c)^{T}\mathcal{C}(I) \tag{14} at=softmax(Watttanh(Whht1+c))c=(wc)TC(I)(14)
where W a t t W_{att} Watt and W h W_{h} Wh are learned embedding matrices, c \boldsymbol{c} c is the Conv feature embedding through w c \boldsymbol{w}^c wc.

edding matrices, c \boldsymbol{c} c is the Conv feature embedding through w c \boldsymbol{w}^c wc.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值