code: def buildVarData(varRegionIndices, items, optimize=True):
      self = ot.VarData()
      self.VarRegionIndex = list(varRegionIndices)
      regionCount = self.VarRegionCount = len(self.VarRegionIndex)
      records = self.Item = []
      if items:
          for item in items:
              assert len(item) == regionCount
              records.append(list(item))
      self.ItemCount = len(self.Item)
      self.calculateNumShorts(optimize=optimize)
      return self
  
file_path: catboost/contrib/python/fonttools/fontTools/varLib/builder.py
imports: from fontTools import ttLib
  from fontTools.ttLib.tables import otTables
label_desc: Use image node_id 8 for calling a global function with example usage: buildVarData(varRegionIndices, items, optimize) and returns: self