def create_branches(self, branches):
        """
        Create branches from a TreeBuffer or dict mapping names to type names

        Parameters
        ----------
        branches : TreeBuffer or dict
        """
        if not isinstance(branches, TreeBuffer):
            branches = TreeBuffer(branches)
        self.set_buffer(branches, create_branches=True)