ytree.arbor.arbor.load

ytree.arbor.arbor.load(filename, method=None, **kwargs)

Load an Arbor, determine the type automatically.

filename : string
Input filename.
method : optional, string
The type of Arbor to be loaded. Existing types are: ConsistentTrees, Rockstar, TreeFarm, YTree. If not given, the type will be determined based on characteristics of the input file.
kwargs : optional, dict
Additional keyword arguments are passed to _is_valid and the determined type.

Arbor

>>> import ytree
>>> # saved Arbor
>>> a = ytree.load("arbor/arbor.h5")
>>> # consistent-trees output
>>> a = ytree.load("rockstar_halos/trees/tree_0_0_0.dat")
>>> # Rockstar catalogs
>>> a = ytree.load("rockstar_halos/out_0.list")
>>> # TreeFarm catalogs
>>> a = ytree.load("my_halos/fof_subhalo_tab_025.0.h5")
>>> # LHaloTree catalogs
>>> a = ytree.load("my_halos/trees_063.0")
>>> # Amiga Halo Finder
>>> a = ytree.load("ahf_halos/snap_N64L16_000.parameter",
...                hubble_constant=0.7)