You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ParamUpdate objects track sets of parameters to update. When a ParamUpdate is constructed, the user can manually provide a list of parameters it should track, or the user can pass in a generative function, with the meaning "track all parameters owned by this generative function."
However, when the generative function is written in the dynamic DSL, Gen has no way of knowing what parameters the GF introduces unless the user explicitly initializes them. When the ParamUpdate object is created before the parameters are initialized, the parameters do not end up tracked by the ParamUpdate object.
This leads to counterintuitive order-dependent behavior, as in #414.
We should at the very least document this behavior. Even better would be to find a way to get around it, e.g. by having a different kind of ParamObject that, whenever necessary, checked the GF in question for newly initialized parameters.
The text was updated successfully, but these errors were encountered:
ParamUpdate
objects track sets of parameters to update. When aParamUpdate
is constructed, the user can manually provide a list of parameters it should track, or the user can pass in a generative function, with the meaning "track all parameters owned by this generative function."However, when the generative function is written in the dynamic DSL, Gen has no way of knowing what parameters the GF introduces unless the user explicitly initializes them. When the
ParamUpdate
object is created before the parameters are initialized, the parameters do not end up tracked by theParamUpdate
object.This leads to counterintuitive order-dependent behavior, as in #414.
We should at the very least document this behavior. Even better would be to find a way to get around it, e.g. by having a different kind of ParamObject that, whenever necessary, checked the GF in question for newly initialized parameters.
The text was updated successfully, but these errors were encountered: