I'm using sklearn version 0.18
When using sklearn.decomposition.PCA on a scipy.sparse, the value provided in the svd_solver parameter must be "arpack" (which is the only algorithm supporting sparse input).
the default svd_solver value, "auto" presumes to pick an appropriate default value depending on other input parameters (such as matrix shape and n_components).
It would be helpful if "auto" will also take sparsity into consideration.
Additionally, svd_solver value "full" (or "auto" that picks "full") yields the following error:
TypeError: A sparse matrix was passed, but dense data is required. Use X.toarray() to convert to a dense numpy array.
It would be helpful if the error included a suggestion to use svd_solver value of "arpack" as a potential fix.
I'm using sklearn version 0.18
When using
sklearn.decomposition.PCAon ascipy.sparse, the value provided in thesvd_solverparameter must be "arpack" (which is the only algorithm supporting sparse input).the default
svd_solvervalue, "auto" presumes to pick an appropriate default value depending on other input parameters (such as matrix shape andn_components).It would be helpful if "auto" will also take sparsity into consideration.
Additionally,
svd_solvervalue "full" (or "auto" that picks "full") yields the following error:It would be helpful if the error included a suggestion to use
svd_solvervalue of "arpack" as a potential fix.