A Python implementation of Gaussian process regression.
- Supporting multi-dimensional Gaussian process regression.
- Kernel function is a Gaussian kernel with a constant term and a linear term.
This implementation is for personal study and has not yet been tested for faster computation or detailed accuracy, but I have confirmed that the results are qualitatively similar to the Gpy library.
Let's create a simple sine curve with some noise on it and perform a Gaussian process regression.
This is the result of fixing the kernel function with arbitrary parameters and performing a Gaussian process regression. The red dots represent the observed points, the green color is GroundTruth, the dark blue line is the mean of the regression, and the light blue color is plus or minus 1 sigma.
After hyperparameter optimization, the graph looks like this. This result is consistent with the Gpy library, confirming that my implementation is correct.
Here we use the famous advertising dataset as an example.
It can be used for two-dimensional data in exactly the same way. The blue points are the observed points and the red points are the unobserved test data.
If we draw a regression plane, it will look like the following