Hello,
I am having trouble with keeping my kernel alive when creating data frames from a TF-IDF vectorizer and appending them to a list. Here are snippets of my code:


The function chunks splits up the matrix tfmat, a 60K x 25K matrix, into smaller chunks. However, the kernel keeps dying. This is a screenshot of the error in the terminal:

I have tried the recommendations and supposed solutions here but nothing seems to be working! I'm quite desperate for answers since I need my output by the end of this week.
Any help would be greatly appreciated! Also, any alternatives will be welcome too.
Best,
Adeola
(edited for the error in the matrix size)