7. /38
شماره با کلمات نمایشIndex
•از استفاده کلمات نمایش برای ساده روش یکشمارهIndexباشد می کلمات.
the cat sat on the mat [5,1,4,3,5,2]
7
word index
Cat 1
Mat 2
On 3
…. …
Introduction to Word Embeddings
Dr.Mohammad-Reza Feizi-Derakhshi
9. /38
روشOne-hot encoding
•برا کلمه به مربوط جایگاه که شود می ایجاد نامه لغت طول به برداری روش این دربر1
باشد می صفر برابر مقادیر بقیه و.
9
Dic Index
The 1
On 2
Cat 3
Sat 4
… ….
1 0 0 0 …
0 0 1 0 …
0 0 0 1 …
0 1 0 0 …
The
Cat
Sat
On
… …
Word Embedings
Dr.Mohamad-Reza Feizi-Derakhshi
10. /38
معایبOne-hot encoding
•باال بعد
10
Corpus Number of words
Shakespeare 31 thousand
Brown corpus 38 thousand
Switchboard telephone conversations 20 thousand
COCA 2 million
Google N-grams 13 million
Word Embedings
Dr.Mohamad-Reza Feizi-Derakhshi