Rewrite linalg.eye() to use ElementwiseKernel.
Use ElementwiseKernel to suppress small singular values in linalg.pinv().