def AddToBatch(self, path, payload, mime_type):
    if not mime_type:
      mime_type = 'application/octet-stream'
    size = len(payload)
    if size <= MAX_BATCH_FILE_SIZE:
      if (len(self.batch) >= MAX_BATCH_COUNT or
          self.batch_size + size > MAX_BATCH_SIZE):
        self.Flush()
      if self.batching:
        logging.info('Adding %s %s (%s bytes, type=%s) to batch.',
                     self.what, path, size, mime_type)
        self.batch.append((path, payload, mime_type))
        self.batch_size += size + BATCH_OVERHEAD
        return
    self.SendSingleFile(path, payload, mime_type)
Create MultObsModel, all K component Distr objects,
dataset/ETHPy150Open CollabQ/CollabQ/.google_appengine/google/appengine/tools/appcfg.py/UploadBatcher.AddToBatch--crossover with--dataset/ETHPy150Open daeilkim/refinery/refinery/bnpy/bnpy-dev/bnpy/obsmodel/BernRelObsModel.py/BernRelObsModel.CreateWithAllComps