class_docstr: Memory-mapped iteration over a JSONL file.
docstr: Args:
      dataset_paths: list of JSONL file paths.
      newline_int: ASCII code to use to interpret newlines in file.
      header_lines: number of header lines in JSON files.
      workers: number of workers to use for creating index files.
      tokenizer: tokenizer to use to convert text to tokens.
      sort_dataset_paths: whether to sort datasets by paths.
      index_mapping_dir: directory to save the index mapping to.
          If None, will write to the same folder as the dataset.
code: def __init__(
      self,
      dataset_paths: List[str],
      newline_int: Optional[int] = 10,
      header_lines: Optional[int] = 0,
      workers: Optional[int] = None,
      tokenizer: Optional[Type["TokenizerSpec"]] = None,
      sort_dataset_paths: Optional[bool] = True,
      index_mapping_dir: Optional[str] = None,
  ):
      """
      Args:
          dataset_paths: list of JSONL file paths.
          newline_int: ASCII code to use to interpret newlines in file.
          header_lines: number of header lines in JSON files.
          workers: number of workers to use for creating index files.
          tokenizer: tokenizer to use to convert text to tokens.
          sort_dataset_paths: whether to sort datasets by paths.
          index_mapping_dir: directory to save the index mapping to.
              If None, will write to the same folder as the dataset.
      """
      super().__init__(
          dataset_paths=dataset_paths,
          newline_int=newline_int,
          header_lines=header_lines,
          workers=workers,
          tokenizer=tokenizer,
          sort_dataset_paths=sort_dataset_paths,
          index_mapping_dir=index_mapping_dir,
      )
  
imports: import datetime
  import json
  import multiprocessing
  import os
  import pickle
  import time
  from functools import partial
  from typing import Callable, List, Optional, Type
  import numpy
  import torch
  from nemo.core import Dataset
  from nemo.utils import AppState, logging
label_desc: Use image node_id 1 to create a new JSONLMemMapDataset object from inherited base classes: TextMemMapDataset with example: obj = JSONLMemMapDataset(dataset_paths, newline_int, header_lines, workers, tokenizer, sort_dataset_paths, index_mapping_dir)