bwang482 / tdparse

Code for "TDParse: Multi-target-specific sentiment recognition on Twitter", EACL, 2017
MIT License
25 stars 5 forks source link

Running tdparse+ and tdparse models #2

Closed kush789 closed 6 years ago

kush789 commented 6 years ago

Hi,

When we execute the script as mentioned in the README, the tdparse+ (m) model gets used. Is there any way we can reproduce the results for the tdparse+ and tdparse models?

Thanks a lot!

bwang482 commented 6 years ago

Hi @kush789 the difference between tdparse+ (m) and tdparse+ is that tdparse+ doesn't taking into account the same-target-multiple-appearence scenario and only count the first target appearance. In this case you can add a break after line 171 target_positions.append(position) in utilities.py.

The result for tdparse+ with C=0.003 is

Macro-F1 score: 0.697672428496 Accuracy score: 0.721098265896 Macro-F1 score (2 classes): 0.66014500638

bwang482 commented 6 years ago

The tdparse model referred in the paper is actually tdparse (m), which doesn't use features from lexicon filtered words. So all you gotta do is commenting out line 407 and 408 from tdparse.py.

The result for tdparse (m) with C=0.005 is

Macro-F1 score: 0.684067992817 Accuracy score: 0.709537572254 Macro-F1 score (2 classes): 0.642521908471

kush789 commented 6 years ago

That helps a lot, thanks! :)