- This is an example code for our HFA and SHFA methods described in Algorithm 1 and 2 in
Wen LI, Lixin DUAN, Dong XU and Ivor W. TSANG, "Learning with Augmented Features for Supervised and Semi-supervised Heterogeneous Domain Adaptation," IEEE Transactions on Pattern Analysis and Machine Intelligence (T-PAMI), vol. 36(6), pp. 1134-1148, JUN 2014.
To run the example code:
-
Download the weighted LIBSVM package. Compile its MATLAB interface (by running the file ./matlab/make.m under the weighted libsvm folder). I have also provided a compiled mex file on Windows OS.
-
Setup the path for weighted libSVM package in demo.m. I.e., modify the first line to the folder containing your mex file. addpath('.\libs\libsvm-weights-3.20\matlab');
-
Run demo.m. Finally you will obtain the HFA result of one round on "Amazon->DSLR", it should be 0.567901.
-
Run demo_shfa.m, Finally you will obtain the SHFA result of one round on "Amazon->DSLR", it should be 0.572842.
For any problems with the code, please contact me via [email protected]