Weisfeiler-Lehman Graph Kernels
https://www.jmlr.org/papers/volume12/shervashidze11a/shervashidze11a.pdf
에 대한 리뷰입니다.
Weisfeiler-Lehman test를 기반으로 빠르게 그래프의 feature (topological, label information) extraction 하는 것이 목적이고 kernel method를 적용해 large scale & high-dimensional node labels를 갖는 graph들의 classification , similarity 계산에 있어서 효과적인 방법을 제시한다.
Notation
G=(V,E,ℓ)
V : the set of vertices
E : the set of undirected edges
ℓ:V→Σ, WL Algorithm에 의해 새로운 label을 graph node로 mapping하는 함수
Weisfeiler-Lehman test


기존의 WL-test의 경우 relabeling된 node set의 partition이 그 이전과 동일하면 그만두지만, 해당 논문에서는 그냥 n번 반복한다.
Weisfeiler-Lehman graph sequence
WL test에서 새로운 라벨을 할당하는 함수를 r(⋅)라고 했을 때,
r((V,E,li))=(V,E,li+1)
높이가 i인 Weisfeiler-Lehman graph G=(V,E,li) 일 때,
{G0,...,Gh}={(V,E,l0),(V,E,l1),...,(V,E,lh)} 를
높이 h까지의 "Weisfeiler-Lehman graph sequence"라고 한다.
G0는 original graph이다.
Weisfeiler-Lehman kernel
kWL(h)(G,G′)=k(G0,G0′)+k(G1,G1′)+...+k(Gh,Gh′)
에서 kWL(h)를 높이가 h인 "Weisfeiler-Lehman kernel" 이라고 하고
k를 "base kernel"이라고 한다.
참고로 , 더 일반적인 표현은 다음과 같다.
kWL(h)(G,G′)=α0k(G0,G0′)+α1k(G1,G1′)+...+αhk(Gh,Gh′)
α∗ : nonnegative real value
두 경우 모두 당연하게도 base kernel과 WL kernel은 positive semidefinite하다.
The Weisfeiler-Lehman Subtree Kernel

여기서, kWLsubtree(h)(G,G′)를
Weisfeiler-Lehman subtree kernel on two graphs G and G' with h iterations 라고 정의한다.
The process of WL Subtree Kernel computation



height 수 만큼 iteration 한다.
Subtree pattern 이란

WL Subtree Kernel이라고 부르는 이유
틀릴 수 있음
결론부터 말하자면, the process of WL Subtree kernel computation의 효과가 일치하는 Subtree pattern의 개수를 세는 것과 같기 때문이다.
height = 1인 경우의 간단한 예제를 통한 확인은 다음과 같다.
우선, WL Subtree kernel computation을 해보자.


다음으로, height = 1까지 G,G′의 일치하는 Subtree의 개수를 세보자.

두 그래프의 일치하는 Subgraph의 개수 벡터의 내적 = 8 WL Subtree kernel computation의 결과와 동일하다.
- compressed label li(ν) = root 가 ν이고 height = i인 subtree pattern들과 대응된다.
The representation of WL-Subtree kernel with Dirac kernel
Base kernel을 Dirac kernel로 정의하면 그것에 대응하는 WL Kernel은 WL-Subtree kernel이 된다.

증명생략 .
The Weisfeiler-Lehman Edge Kernel
두 그래프의 유사성을 계산할 때 edge의 endpoint node label들이 동일한지에 대해 고려한다.
즉, edge에 연결되어있는 node pair (a,b)의 개수를 센다.
base kernel kE(G,G′)=⟨ϕE(G),ϕE(G′)⟩ 라고 했을 때, vector ϕ(G)는 각각의 성분에 해당하는 제각각의 쌍(a,b)가 등장한 횟수가 된다.
따라서 WL-Edge kernel은 다음과 같다.
kWLedge(h)=kE(G0,G0′)+kE(G1,G1′)+...+kE(Gh,Gh′)
The representation of WL-Edge kernel with Dirac kernel
Edge에 가중치가 동일한 Graph의 경우는 base kernel 은 다음과 같다.
kE=Σe∈EΣe′∈E′δ(a,a′)δ(b,b′)
가중치가 존재하는 경우는 다음과 같다.
kE=Σe∈EΣe′∈E′δ(a,a′)δ(b,b′)kw(w(e),w(e′))
where kw is a kernel comparing edge weights.
The Weisfeiler-Lehman Shortest Path Kernel
kSP(G,G′)=⟨ϕSP(G),ϕSP(G′)⟩
vector ϕSP(G)는 triplet (a,b,p)이 등장하는 개수를 성분으로 갖는다.
이때, (a,b)는 Edge kernel과 마찬가지로 edge의 endpoint label pair 이고 p는 node a,b 사이의 shortest path length 이다.
따라서 WL-Shortest Path kernel은 다음과 같다.
kWLshortestpath(h)=kSP(G0,G0′)+kSP(G1,G1′)+...+kSP(Gh,Gh′)