Refactoring: self.D > self.input_dim in kernels