--- tags: Human Face --- # ArcFace (CVPR2019) ## 起源(? ### softmax loss 缺點 $$ L = -\frac{1}{N}\sum^N_{i=1}log\frac{e^{W^{T}_{y_{i}}x_i+b_{y_i}}}{\Sigma^n_{j=1}e^{W^{T}_{j}x_i+b_{j}}} $$ 1. 沒有 Margin 的概念 2. $W$ 跟著類別線性成長 ### Triplet loss 缺點 $$ L = \sum^N_i\big[\|f(x^\alpha_i)-f(x^p_i)\|^2_2- \|f(x^\alpha_i)-f(x^n_i)\|^2_2\big] $$ 1. image pair combinatorial explosion 2. semi-hard sample mining > 圖像之間的比較,轉換到圖像與類別(class center)之間的比較(類別的數目是遠小於圖片的數目) :::info 重點就在找出能代表該類別的高維度點RRRRRRR ::: ## pipeline  ### Step1: $X$ and $W$ Normalization $$ L_1 = -\frac{1}{N}\sum^N_{i=1}log\frac{e^{W^{T}_{y_{i}}x_i+b_{y_i}}}{\Sigma^n_{j=1}e^{W^{T}_{j}x_i+b_{j}}} $$ $W^{T}_{y_{i}}x_i=\|W_j\|\|x_i\|cos\theta_j=cos\theta_j$ $$ L_2 = -\frac{1}{N}\sum^N_{i=1}log\frac{e^{s \ cos\theta_{y_i}}}{e^{s\ cos \theta_{y_i}} + \Sigma^n_{j=1,j\neq y_i}e^{s\ cos \theta_{y_i}} } $$ > $W$ 可以看作代表某一類的 center ### Step2: Additivez Angular Margin $$ L_3 = -\frac{1}{N}\sum^N_{i=1}log\frac{e^{s \ cos(\theta_{y_i}+m)}}{e^{s\ cos (\theta_{y_i}+m)} + \Sigma^n_{j=1,j\neq y_i}e^{s\ cos \theta_{y_i}} } $$ ### 組合技 $$ L_4 = -\frac{1}{N}\sum^N_{i=1}log\frac{e^{s \ (cos(m_1\theta_{y_i}+m_2) - m_3)}}{e^{s\ (cos(m_1\theta_{y_i}+m_2) - m_3)} + \Sigma^n_{j=1,j\neq y_i}e^{s\ cos \theta_{y_i}} } $$ - SphereFace:$m_1$ - CosFace:$m_3$ ## 優點 1. 代碼簡單  3. 易解釋 直接去對應角度空間  5. 高效,訓練速度快,利用 $W$ 的分組進行大規模的訓練   > $W$ is large but we can easily split it. > Parallel acceleration on both $x$ and $W$. ## 問題 1. 類別增加角度增加? - 這個是高維度空間,多增加一類人是不會擠壓他其他人臉的角度的 2. $m$ 怎摸去做調整? - 偶不豬到
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up