0c171740243d9fbd3a99dbecbcf5dcc6a1d895f4,pythainlp/transliterate/royin.py,,_normalize,#Any#,119

Before Change



def _normalize(text):
    ตัดอักษรที่ไม่ออกเสียง (การันต์ ไปยาลน้อย ไม้ยมก*) และวรรณยุกต์ทิ้ง
    text = _RE_KARAN.sub("", text)
    text = _RE_YAMOK_PAIYANNOI.sub("", text)
    text = _RE_TONE.sub("", text)
    if re.search(_RE_KARAN2, text):
        karans = re.findall(_RE_KARAN2, text)
        for karan in karans:
            text = re.sub(karan, "", text)
    return text


def _replace_vowels(word):
    for vowel in _VOWELS:

After Change



def _normalize(text):
    ตัดอักษรที่ไม่ออกเสียง (การันต์ ไปยาลน้อย ไม้ยมก*) และวรรณยุกต์ทิ้ง
    return _RE_NORMALIZE.sub("", text)


def _replace_vowels(word):
    for vowel in _VOWELS:
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 5

Instances


Project Name: PyThaiNLP/pythainlp
Commit Name: 0c171740243d9fbd3a99dbecbcf5dcc6a1d895f4
Time: 2018-11-11
Author: arthit@gmail.com
File Name: pythainlp/transliterate/royin.py
Class Name:
Method Name: _normalize


Project Name: studioml/studio
Commit Name: 514e97adf46aa0cad330d44ae820a793c6a1e308
Time: 2017-06-06
Author: peter.zhokhov@sentient.ai
File Name: studio/model.py
Class Name:
Method Name: _remove_backspaces


Project Name: CellProfiler/CellProfiler
Commit Name: a0f1f391dfe4448067ce7f0f795142a5f5c41661
Time: 2010-05-12
Author: thouis@1fc53939-2000-0410-845c-e8453a809027
File Name: cellprofiler/measurements.py
Class Name:
Method Name: find_metadata_tokens


Project Name: google/language-resources
Commit Name: 3bf58ef74461beba639872f6503b5e43a20d031a
Time: 2016-10-30
Author: mjansche@google.com
File Name: si/zero_width.py
Class Name:
Method Name: RemoveOptionalZW