class_docstr: Process embeddings in blocks & save to disk.
class_docstr_tok: ["Process","embeddings","in","blocks","&","save","to","disk","."]
code: def __init__(
      self, batch_size, max_bert_seq_length, block_size, embedder_type
  ):
      self.embedder = BertEmbedder(
          batch_size, max_bert_seq_length, embedder_type
      )
      self.block_size = block_size
  
imports: from functools import partial
  import numpy
  import os
  import time
  import torch
  from torch.utils.data import BatchSampler, DataLoader, SequentialSampler, Subset
  from torch.utils.data._utils.collate import default_collate
  from tqdm import tqdm
  from megatron import get_args, get_tokenizer, print_rank_0
  from megatron import core
  from megatron.arguments import core_transformer_config_from_args
  from megatron.core.enums import ModelType
  from megatron.core.pipeline_parallel import get_forward_backward_func
  from megatron.model import BertModel
  from megatron.training import setup_model_and_optimizer
  from .dataset import BertEmbeddingDataset
  from .external_libs import h5py
  from .huggingface import HuggingfaceEmbedder
  from .utils import get_missing_blocks_by_rank
label_desc: Use image node_id 1 to create a new DiskDataParallelBertEmbedder object  with example: obj = DiskDataParallelBertEmbedder(batch_size, max_bert_seq_length, block_size, embedder_type)