def verify_equal(name: str, tile_dict: dict, storage: EnsemblePredictions, eq_funct: Callable) -> bool:
        """Verify that all data at same tile index and same batch index matches."""
        batch_num = len(tile_dict[0, 0])

        for batch_i in range(batch_num):
            # batch is dict where key: tile index and val is batched data of that tile
            curr_batch = storage.get_batch_tiles(batch_i)

            # go over all indices of current batch of stored data
            for tile_index, stored_data_batch in curr_batch.items():
                stored_data = getattr(stored_data_batch, name)
                # get original data dict at current tile index and batch index
                original_data = getattr(tile_dict[tile_index][batch_i], name)
                if isinstance(original_data, Tensor):
                    if not eq_funct(original_data, stored_data):
                        return False
                elif original_data != stored_data:
                    return False

        return True
Verify that all data at same tile index and same batch index matches.
tests/unit/pipelines/tiled_ensemble/test_prediction_data.py