docstr: Not all `BatchSamplers` define a consistent `batch_size`, but those that
  do should override this method.
docstr_tok: ["Not","all","`","BatchSamplers","`","define","a","consistent","`","batch_size","`",",","but","those","that","do","should","override","this","method","."]
code: def get_batch_size(self) -> Optional[int]:
      """
      Not all `BatchSamplers` define a consistent `batch_size`, but those that
      do should override this method.
      """
      return None
  
imports: from typing import List, Iterable, Sequence, Optional
  from allennlp.common.registrable import Registrable
  from allennlp.data.instance import Instance
label_desc: Use image node_id 3 for calling the BatchSampler obj's underlying member method code with example usage: obj.get_batch_size() and returns: None