chuyuanli / MTL4Depr

Source code for paper Multi-Task Learning for Depression Detection in Dialogs (SIGDial 2022)
10 stars 2 forks source link

How to run test mode? #2

Open gambiTarun opened 1 year ago

gambiTarun commented 1 year ago

When running test mode, there is a runtime error when trying to calculate metrics in the cal_f1 function in utility.py.

macro_rec = round((df.da.recall.sum()) / len(df.da.recall),4)

'DataFrame' object has no attribute 'da'

Can you please help with resolving this issue? What is "da"?

chuyuanli commented 1 year ago

Hi, thanks for pointing it out!

"da" is disarray, to help the confusion matrix calculation: https://pypi.org/project/disarray/ You need to pip install and then import disarray in utility.py to make it work.

Hope that helps.