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

SWEM-concat Implementation in text2vec #331

Open
raywyf opened this issue May 11, 2021 · 0 comments
Open

SWEM-concat Implementation in text2vec #331

raywyf opened this issue May 11, 2021 · 0 comments

Comments

@raywyf
Copy link

raywyf commented May 11, 2021

Hello!

I'm currently using text2vec to create embeddings for a dataset of tweets. Since each document is pretty short, I want to implement a Simple Word Embedding Model (SWEM), specifically SWEM-concat, whereby I concatenate together the average of all word vectors in a document, and the result from max-pooling. This method is discussed in this paper.

I can get the document averages by normalizing the dtm object and then taking the dot product of that with the word vector object, but I'm struggling with how to get the max-pooling results. Any help would be much appreciated!

Thanks!

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

1 participant