code: def append(self, tensor_list: List[Tensor], callback_fn: Callable):
      # copy data from input_list into bucket
      tensor_size = tensor_list[0].numel()
      stacked_input = torch.stack(tensor_list).view(
          self.group.size(), tensor_size
      )
      offset = self.offset
      self.buffer[:, offset : offset + tensor_size].copy_(stacked_input)
      self.offset += tensor_size
  
      # callback will be given the reduced result
      if callback_fn is not None:
          result_view = self.output_shard[
              offset : offset + tensor_size
          ].view_as(tensor_list[0])
          self.callbacks.append(
              functools.partial(callback_fn, result_view)
          )
  
file_path: ColossalAI/colossalai/legacy/zero/sharded_model/reduce_scatter.py
imports: import functools
  import os
  from typing import Callable, Dict, List, Optional, Tuple
  import torch
  import torch.distributed
  from torch import Tensor
  from torch.distributed import ProcessGroup
label_desc: Use image node_id 5 for calling the Bucket obj's underlying member method code with example usage: obj.append(tensor_list, callback_fn) without return types