code: def _compare_datasets(dataset, expected_dataset):
      for rec, expected in zip(dataset, expected_dataset):
          for col in expected.__fields__.keys():
              # TODO: have to think about how we deal with `None`s
              if col in ["metadata", "metrics"]:
                  continue
              assert getattr(rec, col) == getattr(
                  expected, col
              ), f"Wrong column value '{col}'"
  
imports: import copy
  import os
  import sys
  from time import sleep
  import datasets
  import pandas
  import pytest
  import spacy
  from argilla.client.datasets import DatasetBase, DatasetForText2Text, DatasetForTextClassification, DatasetForTokenClassification, WrongRecordTypeError, read_datasets, read_pandas
  from argilla.client.models import Text2TextRecord, TextClassificationRecord, TokenClassificationRecord
  from argilla.datasets import TextClassificationSettings
label_desc: Use image node_id 2 for calling a global function with example usage: _compare_datasets(dataset, expected_dataset) without return types