Hi Oscar,
Thanks for the answer. I was trying to find the values of w1, w2 from loss2
(starting with calculation of all partial derivatives). Are you suggesting
not to work on the matrix in loss2?
I know how the problem can be tackled through numerical differentiation
(gradient descent), but
On Sun, 31 May 2020 at 18:44, Giuseppe G. A. Celano
wrote:
>
> PS: I checked my previous post and the code I wrote looks correct:
Your code is correct but it is probably not a good way of solving your
actual problem.
What would make more sense as a use of sympy is to use sympy to derive
a
PS: I checked my previous post and the code I wrote looks correct:
> import numpy as np
> from sympy import *
>
> n, d, n2, d2 = 5, 7, 4, 3
>
> x = np.random.randn(n, d)
> y = np.random.randn(n, d2)
>
> w1 = MatrixSymbol("l", 7, 4)
> w1 = Matrix(w1)
>
> w2 = MatrixSymbol("p", 4, 3)
> w2 =
Hi Lee,
Yes, it is a mistake. I meant:
x = np.random.randn(n, d)
y = np.random.randn(n, d2)
On Sunday, May 31, 2020 at 3:18:56 PM UTC+2, S.Y. Lee wrote:
>
> It's better work on matrix expressions
> I also don't think that x, y should be numeric matrices if they are random
> matrices.
>
>
It's better work on matrix expressions
I also don't think that x, y should be numeric matrices if they are random
matrices.
Now, the problem is the matrix derivative is computed wrong when it's
derived with it's own elements
But when I tried with https://github.com/sympy/sympy/pull/17232 and
On Sun, 31 May 2020 at 03:42, Giuseppe G. A. Celano
wrote:
>
> I am trying to use very small matrices. Is there any way to calculate the
> partial derivatives of "loss2" below?
>
> import numpy as np
> from sympy import *
>
> n, d, n2, d2 = 5, 7, 4, 3
>
> x = np.random.randn(n, d)
> y =
Thanks!
I am trying to use very small matrices. Is there any way to calculate the
partial derivatives of "loss2" below?
import numpy as np
from sympy import *
n, d, n2, d2 = 5, 7, 4, 3
x = np.random.randn(n, d)
y = np.random.randn(n, d2)
w1 = MatrixSymbol("l", 7, 4)
w1 = Matrix(w1)
w2 =
On 30/05/2020 15:02, Giuseppe G. A. Celano wrote:
|
Entercode here...
|
I am trying to perform a dot multiplication between a numpy array
(64,1000) and a sympy matrix (1000, 100) containing only variables,
but the computation never ends. How to do that?
--
You received this message because
Enter code here...
I am trying to perform a dot multiplication between a numpy array (64,1000)
and a sympy matrix (1000, 100) containing only variables, but the
computation never ends. How to do that?
--
You received this message because you are subscribed to the Google Groups
"sympy" group.