Question about SUBLAYERS and CUSTOMIZATION within utils
PaulCapestany opened this issue · 9 comments
Python isn't my strong suite, but I think I grok most of what's going on with all the .js → .txt → .json conversions — except for one part.
Towards the bottom of GroupingsAndPartInfoGeneration.py, are the LAYERS_ORDER
, SUBLAYERS
, and CUSTOMIZATION
values put together by hand, or is there a separate script that handles this as well? (I'm trying to figure out how they were arrived at...)
Layers order, customization and sublayer were created by hand, basically deciding things like "in what layer should this group be?". The step of putting those together is manual since it's based on knowledge of the model (what every part is and where do they belong) and of the desired output (how do we want the model to be explored?), it would probably require an AGI to infer that hierarchy automatically :)
Got it. Just wanted to make sure that I wasn't missing any sublayer metadata hidden in the .blend file or something. I hadn't previously looked into C. elegans much, so wasn't immediately clear if those groupings were extracted through some programmatic means or not.
The more I look into OpenWorm, the more I'm really liking what I see though.. especially the fact that you guys are assembling such a great swath of interconnected software/apps for the project.
My questions stem from the idea of perhaps pulling out the hard-coded aspects of openwormbrowser-ios (as well as this web wormbrowser repo, and perhaps other OW repos as I do a bit more exploring) in order to abstract the way the code works into a more generalized form.
For example, I think it could be pretty powerful to have a "plug-and-play" toolset of sorts where one could drop in an arbitrary model (e.g. a .blend of the BodyParts3D complete human anatomy project) and then be able to use it across apps on the web/iOS/etc. So you wouldn't necessarily just have OpenWorm; you could also pretty easily have OpenHuman, OpenDrosophila, OpenWhatever...
Anyway, I'll be digging into the code more, lotsa great stuff here — thanks for the help :)
@PaulCapestany I've been dreaming of that too - if you wanted to modify the iOS and WebGL apps to implement this plug & play concept it would be an awesome contribution :)
I always thought there's always gonna have to be somewhere where you specify those hierarchies for the parts somewhat manually - regardless if you encode it in the blender file and extract it somehow or you do it after in the scripts as we are doing at the moment.
If you have ideas to improve anything, please share them and more importantly feel free to issue pull requests!
@gidili — yeah, after getting a couple different models working I now see how the customization stuff comes into play.
I've actually sent a note to @coderforlife regarding http://webgl-tests.crbs.ucsd.edu/obj-viewer/ since it's integral to how everything gets generated… I've got some ideas for perhaps streamlining the whole process I'd like to experiment with. Happy to do pull requests if any of it pans out ;)
@PaulCapestany awesome - keep us in the loop!
As a followup I have posted the converter code to https://github.com/coderforlife/slash-objconverter
As part of a recent grant submitted by my lab (NCMIR at UCSD) to make a set of tools that will auto-generate the layers/sublayers based on ontologies. Our goal was for neuroscience using the NeuroLex ontology. Basically the ontology has lots of information about things like "nucleus is part of cell". Using this information a program could say that the nucleus is a sub-layer of cell (if layers were properly named - although NeuroLex also has a lot of information about synonyms).
@coderforlife thanks for that - I've been wanting to have a look at that code for a long time! 👍
As I said on the website you could have always emailed me! I had provided it to others before that way.
The reason it has not been in a public repository before is because it has been part of "SLASH" which has a private repo on github. While all that code should one day become public, it is waiting to be part of published papers. This particular code does not fall under that restriction though.
No worries, not blaming you at all - I have just been lazy. Now I have no excuse :) Thanks for the excellent work by the way, it really was (and is) a life saver!