Thank you so much! I’ve been looking for something like this for hours.
@bitbit56267 ай бұрын
Thank you so much sur , the explanation was very clear, just i have a question about vector sigma that contain the eigenvalues in his diagonal , why we don't use it to find the vectors U like the formula ? (U1=(1/sigma_1)*A*V1 (U2=(1/sigma_2)*A*V2 ....ext and thank you again sur ❤️
@hungduy3152 Жыл бұрын
Thank you for this very straight forward video to understand SVD, I have some questions: - After finding V, what is the method to find U. As the video of RANJI RAJ (kzbin.info/www/bejne/aqXZqGBnfa5na9U), I can find U by just find the eigenvector of A@A.T - Why you using `eigh` instead of `eig`, I see the result if replace `eigh` to `eig` in your code, it still the same eigenmatrix but different in order of eigenvalue and eigenvector, that leads to wrong Diagonal Matrix
@daniel_an Жыл бұрын
Hi. I must have been busy when you posted this question. I was just about to use this video again for my class and noticed your comment. One can get either U or V by getting the eigenvectors of A@A.T or A.T@A, but then you have to make sure that U and V are chosen to correspond to each other by u=Av or else the diagonal matrix won't appear. That's why in the video I first find V as eigenvectors of A.T@A and then use u=Av to find the u's. Of course, the u's found that way won't be unit vectors, so one has to normalize it (divide by its size.) About eigh vs eig, it doesn't matter. It's just that eigh is faster and more accurate if the matrix is hermitian. The ordering of the eigenvectors will give you different SVD (SVD is not unique unless you impose some ordering on the eigenvalues, and even then it may not be unique if A.T@A has eigenvalues with multiplicities). That's why you got something different using eigh vs eig. Both are correct. I hope this helps.