Aircraft Detection 1.0
Loading...
Searching...
No Matches
eigenplanes.h File Reference
#include <opencv2/core/mat.hpp>

Go to the source code of this file.

Functions

cv::Mat eigenPlanes (const std::vector< cv::Mat > &vec, cv::Size img_dims)
 Computes the average plane from a vector of images using PCA.
 

Function Documentation

◆ eigenPlanes()

cv::Mat eigenPlanes ( const std::vector< cv::Mat > & vec,
cv::Size img_dims )

Computes the average plane from a vector of images using PCA.

This function takes a vector of images, converts them to CV_64F, and creates a data matrix. It then performs Principal Component Analysis (PCA) on the centered data matrix, projects each image onto the PCA space, and computes the average projection. Finally, it reshapes the average projection back into the original image dimensions and normalizes the result.

Parameters
[in]vecA vector of images (each represented as a cv::Mat) to be processed.
[in]img_dimsThe dimensions of the input images.
Returns
A cv::Mat representing the average plane computed from the input images.
See also
cv::Mat
cv::PCA