When you do y=... You don't replace y. Theano create a new node (a Python
object), and assign it to a Python variable y.

It is the same as if you named the second variable y2.

I don't understand what you want to do, so I can't be more precise.

Fred

Le ven. 4 août 2017 20:22, <dherna...@gmail.com> a écrit :

> Hello,
>
> How can I replace a shared variable by a scalar in a graph? I am in
> particular interested in replacing it by its current value. For instance,
> say I have
>
> >>  z = T.scalar('z')
> >>  x = theano.shared(1.0, 'x')
> >>  y = z + x
>
> I would like to evaluate x in the above graph, so as to end up with a
> Tensor Variable y
>
> >> y = z + 1.0
>
> which does not depend anymore on any Shared Variable. How can I do this?
>
> Thanks!
>
> Daniel
>
>
> --
>
> ---
> You received this message because you are subscribed to the Google Groups
> "theano-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to theano-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"theano-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to theano-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to