Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MisMatch between labels during dataPrep v.s. during inference #17

Closed
iattar opened this issue Dec 7, 2020 · 1 comment
Closed

MisMatch between labels during dataPrep v.s. during inference #17

iattar opened this issue Dec 7, 2020 · 1 comment

Comments

@iattar
Copy link

iattar commented Dec 7, 2020

I might be missing something, but it seems there is a mis-match between the label ordering when preparing the training data v.s. when doing the inference in the provided jupyter notebook.

In the 'datasets.py' file, in the 'transform_labels' method, the order is: "dict_labels = {'positive': 0, 'neutral':1, 'negative':2}"
But in the notebook: "labels = {0:'neutral', 1:'positive', 2:'negative'}"

In both cases, 'negative'=2, but 'positive' and 'neutral' are switched.
Is there a reason I am missing?
Thank you!

@yya518
Copy link
Owner

yya518 commented Dec 8, 2020

Thanks for pointing it out. The transform_labels method in the dataset.py is used to prepare a different dataset (financialPhraseBankDataset), and it's not used by the inference Notebook code. If you use our notebook, I assume you want to use the model fine-tuned by the analyst-tone data, where the labels are {0:'neutral', 1:'positive', 2:'negative'}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants