Quantcast
Channel: Active questions tagged kernel - Stack Overflow
Viewing all articles
Browse latest Browse all 6402

Kernel died when running ngram

$
0
0
vectorizer = TfidfVectorizer(sublinear_tf=True, max_df=0.5,stop_words='english',use_idf=True, ngram_range =(2,2))

My jupyter notebook's kernel keep restarting when implementing TFIDF with ngram=2. Is there anyway to efficiently run it, so the kernel is not crashed.

I tried running it in VScode as well, and it said "zsh: killed /opt/anaconda3/bin/python"

The dataset is quite large (around 5000 records with a bunch of String in each record)


Viewing all articles
Browse latest Browse all 6402

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>