News for hackers. Stuff that matters.
Re:Matrix Calculus: Calculate derivatives of matrices by eachro on Friday April 14, 2023 @09:31PM (#35576832)
Knowing matrix derivatives well is one of those skills that were essential in machine learning 10 years ago. Not so much anymore with the dominance of massive neural networks.
Re:Matrix Calculus: Calculate derivatives of matrices by rdedev on Friday April 14, 2023 @09:35PM (#35576856)
I wouldn't completely discount it. Like I wanted to speed up a certain loss function by rewriting it in triton. But I have to manually code the backward pass function for it in triton. For that I need to know how to calculate the derivative. Then again I guess with pytorch 2.0 compile function it might not be necessary
Re:Matrix Calculus: Calculate derivatives of matrices by 6gvONxR4sf7o on Friday April 14, 2023 @10:23PM (#35577098)
It depends what kind of work you do. I still find it to be really handy.
Re:Matrix Calculus: Calculate derivatives of matrices by p1esk on Friday April 14, 2023 @10:30PM (#35577132)
It’s much more relevant now because of the massive neural networks - specifically the need to compress them. Most of the state of the art model compression methods (quantization or pruning) rely on second order gradients, so you need to know how to compute, invert, and approximate the Hessian matrix (a matrix of all second order partial derivatives of the loss function wrt model parameters).
Re:Matrix Calculus: Calculate derivatives of matrices by thomasahle on Friday April 14, 2023 @10:35PM (#35577151)
What quantization methods rely on second order gradients? I thought people just applied gradient decent, then round to whatever precision.
Re:Matrix Calculus: Calculate derivatives of matrices by p1esk on Friday April 14, 2023 @10:49PM (#35577219)
Current SOTA post training quantization method is GPTQ: https://arxiv.org/abs/2210.17323
Re:Matrix Calculus: Calculate derivatives of matrices by mcapodici on Saturday April 15, 2023 @06:04AM (#35579160)
This field is so interesting, sad I didn’t get into it sooner
Re:Matrix Calculus: Calculate derivatives of matrices by vinte on Friday April 14, 2023 @11:58PM (#35577493)
I guess it will be like assembly or low level programing languages like c for future ML engineers. Its good to know the basics but not always needed.