class_docstr: Partial feature stats for natural language.
class_docstr_tok: ["Partial","feature","stats","for","natural","language","."]
code: def __init__(
      self,
      invalidate=False,
      num_in_vocab_tokens: int = 0,
      total_num_tokens: int = 0,
      sum_in_vocab_token_lengths: int = 0,
      num_examples: int = 0,
  ) -> None:
      # True only if this feature should never be considered, e.g: some
      # value_lists have inconsistent types or feature doesn't have an
      # NL domain.
      self.invalidate = invalidate
      self.num_in_vocab_tokens = num_in_vocab_tokens
      self.total_num_tokens = total_num_tokens
      self.sum_in_vocab_token_lengths = sum_in_vocab_token_lengths
      self.num_examples = num_examples
      self.vocab_token_length_quantiles = sketches.QuantilesSketch(
          _QUANTILES_SKETCH_ERROR,
          _QUANTILES_SKETCH_NUM_ELEMENTS,
          _QUANTILES_SKETCH_NUM_STREAMS,
      )
      self.min_sequence_length = None
      self.max_sequence_length = None
      self.sequence_length_quantiles = sketches.QuantilesSketch(
          _QUANTILES_SKETCH_ERROR,
          _QUANTILES_SKETCH_NUM_ELEMENTS,
          _QUANTILES_SKETCH_NUM_STREAMS,
      )
      self.token_occurrence_counts = sketches.MisraGriesSketch(
          _NUM_MISRAGRIES_SKETCH_BUCKETS
      )
      self.token_statistics = collections.defaultdict(_TokenStats)
      self.reported_sequences_coverage = []
      self.reported_sequences_avg_token_length = []
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import collections
  from typing import Dict, Iterable, List, Optional, Set, Text, Union
  import pyarrow
  import six
  from tensorflow_data_validation import types
  from tensorflow_data_validation.statistics.generators import stats_generator
  from tensorflow_data_validation.utils import quantiles_util
  from tensorflow_data_validation.utils import schema_util
  from tensorflow_data_validation.utils import stats_util
  from tensorflow_data_validation.utils import vocab_util
  from tfx_bsl import sketches
  from tensorflow_metadata.proto.v0 import schema_pb2
  from tensorflow_metadata.proto.v0 import statistics_pb2
  from tfx_bsl.types import tfx_namedtuple
label_desc: Use image node_id 1 to create a new _PartialNLStats object from inherited base classes: object with example: obj = _PartialNLStats(invalidate, num_in_vocab_tokens, total_num_tokens, sum_in_vocab_token_lengths, num_examples)