# MemoryError for ScikitLearn Kernel PCA [closed]

I have a data set consisting of roughly 170,000 input vectors having 3,000 features each. On this data set I would like to perform a Kernel PCA using scikit-learn. Unfortunately, any attempt always results in:

MemoryError

I'm on a PC having 32 GB of RAM and setting the copy_X parameter to 'false' doesn't help. Any suggestions?

## closed as off-topic by kjetil b halvorsen, Jan Kukacka, Peter Flom♦May 28 '18 at 13:12

This question appears to be off-topic. The users who voted to close gave this specific reason:

• "This question appears to be off-topic because EITHER it is not about statistics, machine learning, data analysis, data mining, or data visualization, OR it focuses on programming, debugging, or performing routine operations within a statistical computing platform. If the latter, you could try the support links we maintain." – kjetil b halvorsen, Jan Kukacka, Peter Flom
If this question can be reworded to fit the rules in the help center, please edit the question.

On Wikipedia there is a specific paragraph related to large samples. Just like (kernel) SVM, you need to compute the whole matrix $K(x_i, x_j)$. Where $x_i$'s are your sample points. You have 170 000 of them, so 170 000 ^ 2 terms to compute (and store) in the matrix $K$. Even with enough memory, I doubt the calculation would end.