def _get_subword_units(token, gram):
    """Return subword-units presentation, given a word/token.
    """
    if token == '</s>':  # special token for padding purpose.
        return [token]
    t = '#' + token + '#'
    return [t[i:i + gram] for i in range(0, len(t) - gram + 1)]