reads the characters in txt and returns a dictionary
	of all letters
519126
def _get_dict_char_count(txt):
	
	dct = {}
	for letter in txt:
		if letter in dct:
			dct[letter] += 1
		else:
			dct[letter] = 1
	return dct
1360346
def letter_set(self):
        
        end_str = ctypes.create_string_buffer(MAX_CHARS)

        cgaddag.gdg_letter_set(self.gdg, self.node, end_str)

        return [char for char in end_str.value.decode("ascii")]
871245
def read_all():
    
    global CACHE_
    load_cache(True)
    evs = CACHE_['evs'].keys()
    cache = CACHE_['cache'].keys()
    seeds = CACHE_['seeds'].keys()
    return {"evs"  : evs,
            "cache": cache,
            "seeds": seeds}
357507
def read_text(self):  # type: () ->Dict[str,str]
        
        found = {}
        for file in self.file_inventory.text_files:
            if not os.path.isfile(file):
                continue
            with self.file_opener.open_this(file, "r") as infile:
                text = infile.readline()
            found[file] = text.strip(" \n")
        return found
244316
def read_files(filenames, with_name=False):
    """"""
    text = [read_file(filename) for filename in filenames]
    if with_name:
        return dict(zip(filenames, text))
    return text
1170101
def _get_unique_ch(text, all_common_encodes):
    

    unique_chars = ''
    if isinstance(text, str):
        text = text.split("\n")
    elif isinstance(text, (list, tuple)):
        pass

    special_chars = ['.', ',', ';', ':','', ' ', '\r', '\t', '=', '\n']
    for line in text:
        for word in line.split(' '):
            if ( not PYTHON3 ): word = word.decode( 'utf-8')
            for ch in all_common_encodes:
                if ch in word: word = word.replace(ch, '')
            # end of for ch in _all_common_encodes_:
            # if len of word is zero, then go for another word
            if not word: continue

            for ch in word:
                if ch.isdigit() or ch in special_chars:
                    # remove special common chars
                    word = word.replace(ch, '')
                    continue
                # end of if ch.isdigit() or ...:
                # Whola, got unique chars from user passed text
                return word
            # end of for ch in word:
        # end of for word in line.split(' '):
    # end of for line in text:
    return ''
486413
def decode(txt):
    
    _nid = NameID()
    for part in txt.split(","):
        if part.find("=") != -1:
            i, val = part.split("=")
            try:
                setattr(_nid, ATTR[int(i)], unquote(val))
            except:
                pass
    return _nid
1252023
def bdecode(bstring):
    '''
        
    '''

    def get_val():
        i = reader.next()
        if i.isdigit():
            str_len = get_len(i)
            return get_str(str_len)
        if i == 'd':
            return get_dict()
        if i == 'l':
            return get_list()
        if i == 'i':
            return get_int()
        if i == 'e':
            return None

    def get_len(i=''):
        len_str = str(i)
        next_char = reader.next()
        if next_char == 'e':  # The line that collapses the dictionary
            return None
        while next_char is not ':':
            len_str += next_char
            next_char = reader.next()
        else:
            return int(len_str)

    def get_dict():
        this_dict = {}
        while 1:
            str_len = get_len()
            if str_len is None:  # This dict is done
                return this_dict
            key = get_str(str_len)
            val = get_val()
            this_dict[key] = val

    def get_int():
        int_str = ''
        i = reader.next()
        while i is not 'e':
            int_str += i
            i = reader.next()
        else:
            return int(int_str)

    def get_str(str_len):
        this_str = ''
        for i in range(str_len):
            this_str += reader.next()
        return this_str

    def get_list():
        this_list = []
        while 1:
            val = get_val()
            if not val:
                return this_list
            this_list.append(val)

    reader = _readchar(bstring)
    dict_repr = get_val()
    return dict_repr
399567
function (str) {
              var allPairs = [], pairs;
              var words = str.split(/\s+/);
              for (var i = 0; i < words.length; i++) {
                pairs = letterPairs(words[i]);
                allPairs.push.apply(allPairs, pairs);
              }
              return allPairs;
            }
90582
def read_text_file(filename, encoding="utf-8"):
    
    try:
        with open(filename, 'r', encoding) as f:
            r = f.read()
    except TypeError:
        with open(filename, 'r') as f:
            r = f.read()
    return r
257381
def symbols():
    """"""
    symbols = []
    for line in symbols_stream():
        symbols.append(line.decode('utf-8').strip())
    return symbols
1303013
private void loadDictionaries(final String inputDir) throws IOException {
    final List<File> fileList = StringUtils.getFilesInDir(new File(inputDir));
    dictNames = new ArrayList<String>(fileList.size());
    dictionaries = new ArrayList<Map<String, String>>(fileList.size());
    dictionariesIgnoreCase = new ArrayList<Map<String, String>>(
        fileList.size());
    System.err.println("\tloading dictionaries in " + inputDir + " directory");
    for (int i = 0; i < fileList.size(); ++i) {
      if (DEBUG) {
        System.err.println(
            "\tloading dictionary:...." + fileList.get(i).getCanonicalPath());
      }
      dictNames.add(fileList.get(i).getCanonicalPath());
      dictionaries.add(new HashMap<String, String>());
      dictionariesIgnoreCase.add(new HashMap<String, String>());

      final List<String> fileLines = Files.readLines(fileList.get(i),
          Charsets.UTF_8);
      for (final String line : fileLines) {
        final String[] lineArray = tabPattern.split(line);
        if (lineArray.length == 2) {
          dictionaries.get(i).put(lineArray[0], lineArray[1]);
          if (!line.equalsIgnoreCase("in") && !line.equalsIgnoreCase("on")
              && !line.equalsIgnoreCase("us") && !line.equalsIgnoreCase("or")
              && !line.equalsIgnoreCase("am")) {
            dictionariesIgnoreCase.get(i).put(lineArray[0].toLowerCase(),
                lineArray[1]);
          }
        }
      }
    }
    System.err.println("found " + dictionaries.size() + " dictionaries");
  }
264129
def dicttotext(d, sort=False, max = 0):
    """"""
    if sort:
        f = lambda x: sorted(x, key=lambda y: -1 * y[1])
    else:
        f = lambda x: x

    output = ""
    for i, (key, value) in enumerate(f(d.items())):
        output += key + "\t" + str(value) + "\n"
        if max != 0 and i >= max:
            break
    return output
1141267
def get_ctype_charset (text):
    
    for param in text.lower().split(';'):
        param = param.strip()
        if param.startswith('charset='):
            charset = param[8:].strip()
            try:
                codecs.lookup(charset)
                return charset
            except (LookupError, ValueError):
                pass
    return None
1072781
def charindex(self, line, char, context):
        """"""
        #Make sure that we have chars and lines to work from
        if len(context.bufferstr) > 0 and len(self._chars) == 0:
            #Add one for the \n that we split on for each line
            self._chars = [ len(x) + 1 for x in context.bufferstr ]
            #Remove the last line break since it doesn't exist
            self._chars[-1] -= 1

            #Now we want to add up the number of characters in each line
            #as the lines progress so that it is easy to search for the
            #line of a single character index
            total = 0
            for i in range(len(self._chars)):
                total += self._chars[i]
                self._chars[i] = total
        
        return self._chars[line - 1] + char
645136
def all(self):
        
        return {
            self._decode(k): self._loads(v)
            for k, v in self._client.hgetall(self.key_prefix).items()
        }
739262
def _get_char_pixels(self, s):
        

        if len(s) == 1 and s in self._text_dict.keys():
            return list(self._text_dict[s])
        else:
            return list(self._text_dict['?'])