clement-moulin-frier / vivarium

MIT License
5 stars 0 forks source link

Remove lax_fori_loop and to_jit from interface / configs #49

Open corentinlger opened 3 months ago

corentinlger commented 3 months ago

Description

Remove lax_fori_loop and to_jit from interface / configs (you can't 'unjit' the simulation and we don't want users to change the type of update loop during the simulation). Also we should change the lax_fori_loop name as we discussed @clement-moulin-frier.

clement-moulin-frier commented 3 months ago

Hi,

I'm not fully sure about this but we can discuss it. I agree with you that in almost all use cases there is no reason to change them, and that having them directly accessible in the interface might encourage users to try to change them, whereas they shouldn't. However, it could still be useful for e.g. debugging purpose, where it would be handy to e.g. switch between jit or not. A possibility could be to have a "Debug mode" checkbox in the interface. This could actually be more general : having different types of layouts for different use cases. E.g., by default we only display a minimal set of common parameters (e.g. diameter, color etc ..) ; then we have an "Advanced mode" checkbox where we display more parameters (e.g. entity idx) ; and a then a "Debug" mode where everything is displayed and we also set the interface logging mode to "debug". In that case, we should think about how we could flexibly specify what to display, e.g. from a configuration file or a cli argument. Actually, the best would be to be able to change the interface layout according to different use cases, the "advanced" and "debug" modes being just special cases.

Sorry for the long comment, I was thinking while I was writing. I'm pinging @Marsolo1 since it is interface-related. Not a priority for now though, let's first discuss it together when we'll have time for it.

corentinlger commented 3 months ago

Indeed having different modes could be nice ! Actually for to_jit, I would need to check it again but I think that the update function stays jitted even if you uncheck the box in the interface.