code: def test_non_petastorm_with_many_colums_with_one_shot_iterator(
      many_columns_non_petastorm_dataset,
  ):
      """Just a bunch of read and compares of all values to the expected values"""
      with make_batch_reader(
          many_columns_non_petastorm_dataset.url, workers_count=1
      ) as reader:
          dataset = make_petastorm_dataset(reader)
          iterator = dataset.make_one_shot_iterator()
  
          # Make sure we have static shape info for all fields
          for shape in dataset.output_shapes:
              # TODO(yevgeni): check that the shapes are actually correct, not just not None
              assert shape.dims is not None
  
          # Read a bunch of entries from the dataset and compare the data to reference
          with tf.Session() as sess:
              get_next = iterator.get_next()
              sample = sess.run(get_next)._asdict()
              assert set(sample.keys()) == set(
                  many_columns_non_petastorm_dataset.data[0].keys()
              )
  
file_path: petastorm/petastorm/tests/test_tf_dataset.py
imports: import functools
  import operator
  from copy import copy
  import numpy
  import pytest
  import tensorflow.compat.v1
  from petastorm import make_reader, make_batch_reader
  from petastorm.ngram import NGram
  from petastorm.predicates import in_lambda
  from petastorm.tests.test_common import TestSchema
  from petastorm.tests.test_tf_utils import create_tf_graph
  from petastorm.tf_utils import make_petastorm_dataset
label_desc: Use image node_id 7 for calling a global function with example usage: test_non_petastorm_with_many_colums_with_one_shot_iterator(many_columns_non_petastorm_dataset) without return types