code: def copy(self):
      ret = type(self).__new__(type(self))
  
      # base linearizer params
      ret.opts, ret.ast = self.opts, self.ast
  
      # things downstream of the AST
      # NOTE: we copy bufs for local buffers and sts for optimizations
      (
          ret.info,
          ret.reduceop,
          ret.bufs,
          ret.earlybufs,
          ret.full_buf_index,
          ret.sts,
      ) = (
          self.info,
          self.reduceop,
          self.bufs[:],
          self.earlybufs,
          self.full_buf_index,
          self.sts[:],
      )
  
      # parameters for optimizations
      (
          ret.applied_opts,
          ret.group_for_reduce,
          ret.upcasted,
          ret.local_dims,
          ret.local_alias,
          ret.tensor_core,
          ret.dont_use_locals,
      ) = (
          self.applied_opts[:],
          self.group_for_reduce[:],
          self.upcasted,
          self.local_dims,
          self.local_alias.copy(),
          self.tensor_core,
          self.dont_use_locals,
      )
  
      # uncached since linearize didn't run
      ret.applied_opts_cache = None
  
      return ret
  
imports: from __future__ import annotations
  import os, math, itertools
  from typing import NamedTuple, Optional, List, Tuple, cast, Dict, Union
  from tinygrad.ops import LazyOp, FlopCounter, get_lazyop_info, UnaryOps, BinaryOps, ReduceOps, MemBuffer, ConstBuffer, BufferOps
  from tinygrad.device import Device, Compiled
  from tinygrad.dtype import dtypes, ImageDType, DType
  from tinygrad.helpers import dedup, colored, ansilen, getenv, prod, DEBUG, round_up, all_int
  from tinygrad.shape.shapetracker import ShapeTracker, get_contraction
  from tinygrad.shape.symbolic import sint
  from tinygrad.shape.view import View, strides_for_shape
  from dataclasses import dataclass
  from enum import Enum, auto
label_desc: Use image node_id 2 for calling the Kernel obj's underlying member method code with example usage: obj.copy() and returns: ret