-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create a visual distinction for data flow into Calculators and Distributions #76
Conversation
I would like to see what the result looks like ;) |
import liesel.model as lsl
import tensorflow_probability.substrates.jax.distributions as tfd
import jax.numpy as jnp
n0 = lsl.Param(1.0, None, 'n0')
n1 = lsl.Var(2.0, None, 'n1')
n2 = lsl.Var(lsl.Calc(jnp.exp, n1), None, 'n2')
n0.dist_node = lsl.Dist(tfd.HalfNormal, scale=n2)
gb = lsl.GraphBuilder()
gb.add(n0, n1, n2)
model = gb.build_model()
lsl.plot_vars(model) It can be something like that. I'm not a huge fan of the solution. Do we want to do that only for |
I'm not sure whether I correctly understand what the purpose is. Is this interpretation correct? Arrows that represent input to a variable's distribution are colored in light grey now, to create a visual distinction from arrows that represent input to a variable's calculator. The latter are colored in black, like they used to be. |
Yes |
Thanks! Maybe then a legend entry for both cases would be nice, something like "black: Used in value", "grey: Used in distribution". What do you think? |
Sure |
You can check now |
No description provided.