AdeDZY / K-NRM

K-NRM: End-to-End Neural Ad-hoc Ranking with Kernel Pooling

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Errors? when initial idf values in testing part.

WonderMind opened this issue · comments

Hi zhuyun,
Please help me check this problem:

idf = np.array([int(t) for t in cols[2].split(',')])

I think when 'with_idf=True', this line should be:
if len(cols) < 3:
idf = np.ones(len(q))
else:
idf = np.array([int(t) for t in cols[2].split(',')])

all right?

Thanks for you attention.