code: def zeros_like(arr: T) -> T:
      if isinstance(arr, np.ndarray):
          return np.zeros_like(arr)
      elif isinstance(arr, torch.Tensor):
          return torch.zeros_like(arr)
      else:
          raise TypeError(f"Unsupported type for {arr}: {type(arr)}")
  
imports: from __future__ import annotations
  import operator
  from typing import Callable, Iterator, TypeVar, Any, Optional, Tuple, Union, List, Dict, Generic, cast
  import numpy
  import torch
label_desc: Use image node_id 1 for calling a global function with example usage: zeros_like(arr) and returns: np, torch