ytree-project / ytree

A yt-based merger-tree code.
Other
15 stars 10 forks source link

add tree access for TreeFrog frontend #97

Closed brittonsmith closed 3 years ago

brittonsmith commented 3 years ago

As discussed in PR #95, @manodeep asks:

is it possible to add access=’forest’ or access=‘trees’ (just like for ctrees-hdf5?)

brittonsmith commented 3 years ago

I'm not sure about how to do this efficiently. In ctrees-hdf5, the information analogous to file offsets and tree/forest sizes are stored for both forests and trees. We just have to change where to look. As far as I can tell, this information is only stored for forests in TreeFrog. It would be necessary to go through each forest manually and pull out all root halos. It's not undoable, but would be more than simply changing what data to read. Am I missing something?

manodeep commented 3 years ago

You are totally right - I was confusing the treefrog format with the ctrees-hdf5 format. Please feel free to close this (since I apparently can't close the issue).

brittonsmith commented 3 years ago

No worries! We do at least have a get_root_nodes function that will return all roots within a given forest. I didn't realize you couldn't close issues. I've upgraded member privileges so you should be able to now.