eigen
import { eigen } from '@banou/opencv-wasm'Use after await initOpenCV(). See the initialization and named imports guide.
Calculates eigenvalues and eigenvectors of a symmetric matrix.
The function cv::eigen calculates just eigenvalues, or eigenvalues and eigenvectors of the symmetric matrix src:
src*eigenvectors.row(i).t() = eigenvalues.at<srcType>(i)*eigenvectors.row(i).t()
Note: Use cv::eigenNonSymmetric for calculation of real eigenvalues and eigenvectors of non-symmetric matrix.
See: eigenNonSymmetric, completeSymm, PCA
eigen(src: Mat, eigenvalues: Mat, eigenvectors: Mat): boolean;2 available overloads
eigen(src: Mat, eigenvalues: Mat): boolean;eigen(src: Mat, eigenvalues: Mat, eigenvectors: Mat): boolean;srcinput matrix that must have CV_32FC1 or CV_64FC1 type, square size and be symmetrical (src ^T^ == src).
eigenvaluesOutput destination, filled by the native operation. output vector of eigenvalues of the same type as src; the eigenvalues are stored in the descending order.
eigenvectorsOutput destination, filled by the native operation. output matrix of eigenvectors; it has the same size and type as src; the eigenvectors are stored as subsequent matrix rows, in the same order as the corresponding eigenvalues.
The boolean result.
These signatures describe this package. Upstream documentation can mention optional backends that are absent from this build. Check runtime compatibility before choosing a backend or file format.