code: def test_vector_sketch(self):
      vector_data = [[], [1, 2], [3], [4, 5, 6, 7], [8, 9, 10], None]
      sa = SArray(data=vector_data)
  
      sketch = sa.summary()
      self.__validate_sketch_result(sketch, sa)
      self.__validate_sketch_result(
          sketch.element_length_summary(), sa.dropna().item_length()
      )
  
      flattened = list(itertools.chain.from_iterable(list(sa.dropna())))
      self.__validate_sketch_result(
          sketch.element_summary(), SArray(flattened)
      )
  
      fi = sketch.frequent_items()
      self.assertEqual(len(fi), 5)
      self.assertEqual((fi["[1 2]"]), 1)
      self.assertEqual((fi["[4 5 6 7]"]), 1)
  
      # sub sketch with one key
      s = sa.summary(sub_sketch_keys=1).element_sub_sketch(1)
      expected = sa.vector_slice(1)
      self.__validate_sketch_result(s, expected)
  
      # sub sketch with multiple keys
      keys = [1, 3]
      s = sa.summary(sub_sketch_keys=keys).element_sub_sketch(keys)
      self.assertEqual(len(s), len(keys))
      for key in keys:
          self.assertTrue(key in s)
          expected = sa.vector_slice(key)
          self.__validate_sketch_result(s[key], expected)
  
      indexes = range(0, 10)
      s = sa.summary(sub_sketch_keys=indexes).element_sub_sketch()
      self.assertEqual(len(s), len(indexes))
  
imports: from __future__ import print_function
  from __future__ import division
  from __future__ import absolute_import
  from ..data_structures.sarray import SArray
  import pandas
  import numpy
  import unittest
  import random
  import copy
  import os
  import math
  import array
  import time
  import itertools
  import pytest
label_desc: Use image node_id 5 for calling the SArraySketchTest obj's underlying member method code with example usage: obj.test_vector_sketch() without return types