I spent the majority of this past week debugging a single issue in RoCo. We noticed that when we constrained subcomponent parameters in RoCo and rebuilt the component, the drawing would not reflect the constraint. The representation of the faces in RoCo are parameterized with Variables that define the vertices and transforms of each Face. Therefore, this is dependent on the Variable whose value is set at the top level of the component during solving to reference the same variable as the ones inside the Face representations so when one changes, the other does as well. It was clear that this relationship was not being maintained, but the why was not very clear. What was even more confusing was that everything worked properly when RoCo was run directly from the command line, instead of through the interface. On top of that, sometimes it would work properly even through the interface, although this was quite rare.
After being puzzled for a while and constantly checking the ids of different parameters at different time steps in RoCo, I noticed that every time the component was loaded from the session database on the backend, the ids of the Variables in the list of parameters would change. This means that for some reason, the reference was changing every single time the component was being deserialized. However, for some reason, the Variables that defined the Faces correctly maintained their references. My current idea is that the deserialization process generates a new variable based on the data from the old variable, but that still does not answer the question for why the variables in the face representations seem to be restored correctly. If this is true, I will need to delve deeper into Python memory management and figure out how I can have the deserializer generate the variables from the same reference.
Aside from investigating this bug, I came up with a research question with Christian and Gopi for my next project. We will be looking into how we can optimize design and control of parameterized robots using task-based reinforcement learning in simulation. We will be working on writing a project proposal in the coming weeks.