code: def test_write_parquet_simple(orca_context_fixture):
      sc = orca_context_fixture
      temp_dir = tempfile.mkdtemp()
  
      def generator(num):
          for i in range(num):
              yield {
                  "id": i,
                  "feature": np.zeros((10,)),
                  "label": np.ones((4,)),
              }
  
      schema = {
          "id": SchemaField(
              feature_type=FeatureType.SCALAR,
              dtype=DType.INT32,
              shape=(),
          ),
          "feature": SchemaField(
              feature_type=FeatureType.NDARRAY,
              dtype=DType.FLOAT32,
              shape=(10,),
          ),
          "label": SchemaField(
              feature_type=FeatureType.NDARRAY,
              dtype=DType.FLOAT32,
              shape=(4,),
          ),
      }
  
      try:
          ParquetDataset.write(
              "file://" + temp_dir, generator(100), schema
          )
          data, schema = ParquetDataset._read_as_dict_rdd(
              "file://" + temp_dir
          )
          data = data.collect()[0]
          assert data["id"] == 0
          assert np.all(
              data["feature"] == np.zeros((10,), dtype=np.float32)
          )
          assert np.all(
              data["label"] == np.ones((4,), dtype=np.float32)
          )
  
      finally:
          shutil.rmtree(temp_dir)
  
file_path: BigDL/python/orca/test/bigdl/orca/data/test_write_parquet.py
imports: import tempfile
  import shutil
  import pytest
  import numpy
  import os
  from bigdl.orca.data.image.parquet_dataset import ParquetDataset
  from bigdl.orca.data.image.parquet_dataset import write_from_directory, write_parquet
  from bigdl.orca.data.image.utils import DType, FeatureType, SchemaField
  from bigdl.orca.data.image import write_mnist, write_voc
label_desc: Use image node_id 1 for calling a global function with example usage: test_write_parquet_simple(orca_context_fixture) without return types