I'm currently using the Scikit-learn's KPCA to perform dimensionality reduction on my dataset. They have the isotropic Gaussian kernel (RBF kernel) which only has one value gamma. But now, I want to implement an anisotropic Gaussian kernel that has many values of gamma that depend on the number of dimensions.
I'm aware that Kernel PCA has an option for precomputed kernel but I couldn't find any code example of it being used for dimensionality reduction.
Does anyone know how to implement a custom kernel in sklearn KPCA?