Click on the Scratch Cat to watch the presentation Press "Space" to skip to the demo For the demo: Use the "k" slider to select a compression level and press "Space" to compress and visualize ...and that's about it!
How this works (oversimplified): Think of an image as a grid of numbers where the numbers represent the "intensity" of light and color in the image. Now think about trying to recreate that image with just one column of the grid. It sounds impossible at such a small scale, but an image can be nearly perfectly reconstructed with only a few of these "columns". In the opening visualization, each successive scratch cat image adds one of these "columns" to the approximation to make it slightly better. So the "k" slider in the demo is actually selecting how many of these "columns" to use in the approximation. Pretty nifty But one other thing... this is oversimplified because we aren't actually using the image columns to reconstruct the image - we are actually using specially normalized and modified versions of the columns called singular vectors. These are obtained through the process of SVD Digital Image Compression using Low-Rank Matrix Approximation. All scratch code, explanations, and visualizations done by me. Scratch cat logo came from the Scratch website. U,V and Sigma matrices derived from matlab - if you want the code to try your own image, let me know! Links and such: ----------------------------------- https://towardsdatascience.com/understanding-singular-value-decomposition-and-its-application-in-data-science-388a54be95d (really really good but slightly complex explanation of the SVD - not for the faint of heart) https://dustinstansbury.github.io/theclevermachine/svd-data-compression (low-rank matrix approximations) https://www.mathworks.com/help/matlab/math/image-compression-with-low-rank-svd.html (how to do this yourself with matlab)