看板 [ Python ]
討論串[問題] Bag of words 中文單字詞問題
共 2 篇文章
首頁
上一頁
1
下一頁
尾頁

推噓1(1推 0噓 2→)留言3則,0人參與, 7年前最新作者ctr1 (【積π】)時間7年前 (2018/06/27 08:42), 7年前編輯資訊
0
0
0
內容預覽:
我自己來回答. 預設過濾掉一個字符長度的詞. text = ["我|,|愛你|白Z",. "他|愛狗",. "貓|愛鼠". ]. vectorizer = CountVectorizer(min_df=1, token_pattern='(?u)\\b\\w+\\b'). vectorizer.fi
(還有333個字)

推噓0(0推 0噓 0→)留言0則,0人參與, 最新作者ctr1 (【積π】)時間7年前 (2018/06/26 10:48), 7年前編輯資訊
0
0
0
內容預覽:
from sklearn.feature_extraction.text import CountVectorizer. text = [. "我|愛你",. "他|愛狗",. "貓|愛鼠". ]. vectorizer = CountVectorizer(). vectorizer.fit(tex
(還有348個字)
首頁
上一頁
1
下一頁
尾頁