class_docstr: Class implementing the Tree Traversal strategy in PyTorch for tree-base models.
code: def _expand_indexes(self, batch_size):
      indexes = self.nodes_offset
      indexes = indexes.expand(batch_size, self.num_trees)
      return indexes.reshape(-1)
  
imports: from abc import abstractmethod
  from enum import Enum
  import numpy
  import torch
  from .None import constants
  from ._physical_operator import PhysicalOperator
  from .None import _tree_commons
label_desc: Use image node_id 1 for calling the TreeTraversalTreeImpl obj's underlying member method code with example usage: obj._expand_indexes(batch_size) and returns: indexes