Files
obsidian/общее заметки/TF-IDF.md
T
2026-08-16 17:19:17 +03:00

554 B

TF - term frequency. IDF - inverse document frequency !Pasted image 20260719155922.png

!Pasted image 20260719155956.png

from sklearn.feature_extraction.text import TfidfVectorizer

Usage

  • keywords extraction
  • text clustering (kmeans on tf-idf matrix)

Initially - modification of bag of word, used to filter out useless (less important for meaning words)

Sources: https://habr.com/ru/companies/otus/articles/755772/ https://www.geeksforgeeks.org/machine-learning/understanding-tf-idf-term-frequency-inverse-document-frequency/