NETL-Automatic-Topic-Labelling- icon indicating copy to clipboard operation
NETL-Automatic-Topic-Labelling- copied to clipboard

TypeError: 'float' object is not subscriptable in get_labels in cand generation

Open seilsepour opened this issue 6 years ago • 0 comments

Hi all. I have called get_labels in my code, and i have received this error: **``` in get_labels(topic_num) 53 print(temp) 54 print(type(avgdoc2vec)) ---> 55 resultdoc2vec.append((temp,float(avgdoc2vec[elem]))) 56 57 # This modifies the average word2vec vector for cases in which the word2vec label was same as topic word.

TypeError: 'float' object is not subscriptable

it seems avgdoc2vec is a float varible, so it can not be used by [elem].

any help please?

seilsepour avatar Aug 17 '19 09:08 seilsepour