def _name_data(estr, estr_to_file):
  cps = tuple([ord(cp) for cp in estr])
  name = _sequence_name(cps)
  sequence = ''.join('&#x%x;' % cp for cp in cps)
  try:
    fname = path.basename(estr_to_file[estr])
  except KeyError as e:
    print 'error', e
    print 'estr', estr, '_'.join('%04x' % ord(cp) for cp in estr)
    print '\n'.join('%s %s' % (estr, '_'.join('%04x' % ord(cp) for cp in estr))
                    for estr in estr_to_file.keys())
    raise e
  return fname, sequence, name
dataset/ETHPy150Open googlei18n/nototools/nototools/generate_emoji_name_data.py/_name_data/original