docstr: Using this function, one can easily identify how many sentence has be truncated, thus help the user to choose a better thresthold for chunking.
          
docstr_tok: ["Using","this","function",",","one","can","easily","identify","how","many","sentence","has","be","truncated",",","thus","help","the","user","to","choose","a","better","thresthold","for","chunking","."]
code: def truncate_rate(
      self,
  ):
      r"""Using this function, one can easily identify how many sentence has be truncated, thus help the user to choose a better thresthold for chunking."""
      if self.total_passed_sentences == 0:
          return None
      else:
          return (
              self.num_truncated_sentences / self.total_passed_sentences
          )
  
imports: import itertools
  import warnings
  import torch
  import torch.nn
  from torch.utils.data import Dataset
  from typing import Union, List, Tuple, Dict, Optional
  from transformers.data.processors.utils import InputExample, InputFeatures
  from transformers.tokenization_utils import PreTrainedTokenizer
  from collections import defaultdict
  from openprompt.utils import round_list
  import numpy
label_desc: Use image node_id 2 for calling the TokenizerWrapper obj's underlying member method code with example usage: obj.truncate_rate() and returns: None, unknown