code: def compile(self, ttFont):
      glyphIds = list(map(ttFont.getGlyphID, self.names))
      # Make sure all the ids are consecutive. This is required by Format 2.
      assert glyphIds == list(
          range(self.firstGlyphIndex, self.lastGlyphIndex + 1)
      ), "Format 2 ids must be consecutive."
      self.imageDataOffset = min(next(iter(zip(*self.locations))))
  
      dataList = [EblcIndexSubTable.compile(self, ttFont)]
      dataList.append(struct.pack(">L", self.imageSize))
      dataList.append(sstruct.pack(bigGlyphMetricsFormat, self.metrics))
      return bytesjoin(dataList)
  
imports: from fontTools.misc import sstruct
  from .None import DefaultTable
  from fontTools.misc.textTools import bytesjoin, safeEval
  from .BitmapGlyphMetrics import BigGlyphMetrics, bigGlyphMetricsFormat, SmallGlyphMetrics, smallGlyphMetricsFormat
  import struct
  import itertools
  from collections import deque
  import logging
label_desc: Use image node_id 2 for calling the eblc_index_sub_table_2 obj's underlying member method code with example usage: obj.compile(ttFont) and returns: bytesjoin