Introduction and Purpose
Facial recognition and machine learning have become more and more relevant in modern society. As we use more data to help inform decisions, it becomes increasingly important to use computational resources efficiently. In PCA (principal component analysis), eigenvectors point in the principal directions of the data, while eigenvalues measure the variance along those directions.
In our case, we use PCA and the power method to identify tree species through images of its leaves. Since a single image can be represented as a 690,000×1 RGB vector, the covariance matrix would be a 690,000×690,000 matrix, which is computationally expensive to compute and analyze. Instead, we use the power method to compute the dominant eigenvalue and its respective eigenvector without actually computing the covariance matrix.


Results and Process
The first goal was to use the first principle component, aka the dominant eigenvector. To test the effectiveness of one eigenvector, we tested a sample of 30 images not used in the “training” process. The 30 images consisted of 3 images of leaves from 10 different species. After applying our numerical method that finds this dominant eigenvector, we compare our sample image to this dominant eigenvector. The program compares the sample image and the eigenvectors of the 10 species to determine which species it guesses. The eigenvector closest (orthogonally) to the sample image vector is the species guessed.
To the right, we can see the confusion chart, which nicely shows how our program performed. We can see that our program struggled to identify species 9 the most, and had an overall identification rate of 26/30.

Afterwards, we implement another principle component, the secondmost dominant eigenvector. This is supposed to help increase the successful identification rate. In this case, we compared the distance between the sample vector to our eigenspace spanned by the twomost dominant eigenvectors.
To the right, we can again see a different confusion chart. After implementing the second principle component, the program was significantly better at identifying species 9, but new errors seem to apper. The overall identifaction rate was 27/30.
Overall, this small increase in improvement is likely due to the sensitivity of these vectors to the image background. This project was a super cool application of the power method and introduced me to the idea of vectorizing data, which connects conceptually to the embeddings widely used in today’s AI models.
