71bfb00788ec6e899abc8d2de1a67a281879bccd,keras/preprocessing/text.py,,text_to_word_sequence,#Any#Any#Any#Any#,25
Before Change
if lower:
text = text.lower()
text = text.translate(maketrans(filters, split * len(filters)))
seq = text.split(split)
return [i for i in seq if i]
After Change
if lower:
text = text.lower()
if sys.version_info < (3,) and isinstance(text, unicode):
translate_map = dict((ord(c), unicode(split)) for c in filters)
else:
translate_map = maketrans(filters, split * len(filters))
text = text.translate(translate_map)
seq = text.split(split)
return [i for i in seq if i]
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 8
Instances
Project Name: keras-team/keras
Commit Name: 71bfb00788ec6e899abc8d2de1a67a281879bccd
Time: 2017-08-14
Author: nicole.m.white@outlook.com
File Name: keras/preprocessing/text.py
Class Name:
Method Name: text_to_word_sequence
Project Name: GoogleCloudPlatform/python-docs-samples
Commit Name: 5062b2dd5d1860c7af723f3cdb6e2115872b79f5
Time: 2017-04-18
Author: jonwayne@google.com
File Name: translate/cloud-client/snippets.py
Class Name:
Method Name: translate_text_with_model
Project Name: GoogleCloudPlatform/python-docs-samples
Commit Name: 5062b2dd5d1860c7af723f3cdb6e2115872b79f5
Time: 2017-04-18
Author: jonwayne@google.com
File Name: translate/cloud-client/snippets.py
Class Name:
Method Name: translate_text