code: def bigquery_schema(table):
      
      fields = OrderedDict((el.name, dt.dtype(el)) for el in table.schema)
      partition_info = table._properties.get('timePartitioning', None)
  
      # We have a partitioned table
      if partition_info is not None:
          partition_field = partition_info.get('field', NATIVE_PARTITION_COL)
  
          # Only add a new column if it's not already a column in the schema
          fields.setdefault(partition_field, dt.timestamp)
      return sch.schema(fields)
docs: Infer the schema of a BigQuery `table` object.