code: def compare_weights(w1: List[ndarray], w2: List[ndarray]) -> bool:
      if not len(w1) == len(w2):
          return False
      size = len(w1)
      for i in range(size):
          comparison = w1[i] == w2[i]
          if not comparison.all():
              return False
  
      return True
  
imports: import os.path
  import tempfile
  import unittest
  from typing import List
  import pytest
  import tensorflow
  from numpy import ndarray
  from ray import train
  from ray.data import Preprocessor
  from ray.train import ScalingConfig
  from ray.train.tensorflow import TensorflowCheckpoint, TensorflowTrainer
label_desc: Use image node_id 2 for calling a global function with example usage: compare_weights(w1, w2) and returns: True, False, False