简体   繁体   English

在 Python 中从 Doc2Vec 中提取特征

[英]Extract the features from Doc2Vec in Python

For a small project I need to extract the features obtained from Doc2Vec object in gensim.对于一个小项目,我需要提取从 gensim 中的 Doc2Vec 对象获得的特征。

I have used vector = model.infer_vector(words) is it correct?我用过vector = model.infer_vector(words)吗?

是的,如果words是一个单词字符串列表,则以与训练期间将训练数据馈送到model相同的方式进行预处理/标记化。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM