Closed tcstewar closed 10 years ago
This is harder than expected, since the javaviz system doesn't automatically get access to the locals() dictionary needed to do the namefinder. So instead it makes up unique names by adding (#) on the end of the obj.label.
I think this works well enough for now.
So we should make sure to use unique labels? Or is # a variable you generate that makes it unique?
On 30 May 2014 18:49:01 GMT-04:00, tcstewar notifications@github.com wrote:
This is harder than expected, since the javaviz system doesn't automatically get access to the locals() dictionary needed to do the namefinder. So instead it makes up unique names by adding (#) on the end of the obj.label.
I think this works well enough for now.
Reply to this email directly or view it on GitHub: https://github.com/ctn-waterloo/nengo_gui/issues/53#issuecomment-44707858
It generates a unique #
Okay, names are now much happier. If you specify a label, it'll use that. If you don't, it'll fall back on the name created by namefinder. Not sure this is always the right order, but seems good in the cases I've tried.
It'll also use a "." hierarchy to show the subnetwork structure.
New nengo doesn't have unique labels, but old nengo (and thus javaviz) requires this. We should use the specified labels when possible, and fall back on the same "id" values that the namefinder.py uses to refer to the components in the gui.