jindongwang / activityrecognition

Resources about activity recognition-行为识别资料
908 stars 349 forks source link

Reproducing cross-dataset STL #5

Closed ariaghora closed 5 years ago

ariaghora commented 6 years ago

Hi, how can I reproduce the result for cross-dataset as shown in your STL (percom 18) paper? Is the test run for cross-dataset already in the code somewhere? I coded myself using STL function (in STL.m file), trying DSADS --> PAMAP, the accuracies were always <30% (while it is shown 37.83% in the paper). Here is my attempt:

cross_dsads = load('C:\dataset\crossposition-activity-recognition\cross_dsads.mat');
cross_dsads = cross_dsads.data_dsads;

cross_pamap = load('C:\dataset\crossposition-activity-recognition\cross_pamap.mat');
cross_pamap = cross_pamap.data_pamap;

Xcross_dsads = cross_dsads(:,1:81); %features for torso
ycross_dsads = cross_dsads(:,end);
Xcross_pamap = cross_pamap(:,82:162); %features for chest
ycross_pamap = cross_pamap(:,end);

acc_stl = STL(Xcross_dsads, ycross_dsads, Xcross_pamap, ycross_pamap,30);
fprintf('Acc: %.2f\n',acc_stl);

Do you think I missed something?

In addition, feature_norm is not defined in the "demo.m", when I tried using opportunity dataset.

Thanks, Aria

jindongwang commented 6 years ago

@ariaghora Thank you for your interest in this very early work of mine. Your code looks right. I think the reason is that STL.m is flawed. As I said in readme.md, this is a very early and starter work. After a long time of submission and iteration, I somehow accidentally messed up the code. I will not update and maintain the STL code since I now stop the activity recognition research and move on to transfer learning algorithms itself. I think you can try my another new algorithm BDA (https://github.com/jindongwang/transferlearning/tree/master/code/BDA), which is better than STL. Should you have any questions, feel free to contact me.