class_docstr: Base class for LIT datasets.
docstr: Convert LIT example to bytes representation.
docstr_tok: ["Convert","LIT","example","to","bytes","representation","."]
code: def bytes_from_lit_example(lit_example: JsonDict) -> bytes:
      """Convert LIT example to bytes representation."""
      return serialize.to_json(lit_example).encode("utf-8")
  
imports: from collections.abc import Callable, Mapping, Sequence
  import hashlib
  import glob
  import inspect
  import os
  import random
  import types
  from typing import Optional, Union, cast
  from absl import logging
  from lit_nlp.api import types
  from lit_nlp.lib import serialize
  from lit_nlp.lib import utils
label_desc: Use image node_id 15 for calling the Dataset obj's underlying member method code with example usage: obj.bytes_from_lit_example(lit_example) and returns: serialize