Hungarian algorithm尋找點的對應集合
python實現(xiàn)
http://github.com/tdedecko/hungarian-algorithm
調試和wiki的說明一起對照看
Hungarian 算法對于m,n不等的情況怎么處理,以下鏈接解題步驟一目了然
TPS算法
代碼實現(xiàn)可參看里面的bookstein
https://www2.eecs.berkeley.edu/Research/Projects/CS/vision/shape/sc_digits.html
源碼已傳到同步盤
Thin Plate Spline
http://mathworld.wolfram.com/ThinPlateSpline.html
The name "thin plate spline" refers to a physical analogy involving the bending of a thin sheet of metal. In the physical setting, the deflection is in the z direction, orthogonal to the plane. In order to apply this idea to the problem of coordinate transformation, ++one interprets the lifting of the plate as a displacement of the x or y coordinates within the plane. Thus, in general, two thin plate splines are needed to specify a two-dimensional coordinate transformation++
Shape context
https://www2.eecs.berkeley.edu/Research/Projects/CS/vision/shape/sc_digits.html
- 模板點對X,圖片點對Y(Y點對的數(shù)目可能大于X)
- hungarian algorithm出當前距離最小的點對统诺,然后根據(jù)這些點對使用TPS算法(bookstein)計算出coofficient,然后計算出原始點X變換后的點對XA,更新energy loss
- 對XA和Y再用hungarian algorithm 算法計算點對assignment,然后根據(jù)assignment計算coofficient,然后用coofficient處理原始點對X后更新XA,和energy loss
- 根據(jù)迭代次數(shù)和energy loss 選擇合適的時候結束迭代