Skip to content

Conversation

JianYan-g
Copy link

There is no need to calculate the distance in a quadratic form by generating the diagonal matrix intermediately. Just arranging the weights as a vector and calculating the linear combination solves the calculation. This also reduces the overhead of computation because after the modification, only one matrix product need to be calculated.

There is no need to calculate the distance in a quadratic form by generating the diagonal matrix intermediately. Just arranging the weights as a vector and calculating the linear combination solves the calculation. This also reduces the overhead of computation.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant