Skip to content

对于声母为w y的情况 有非常严重的偏误 #16

Description

@Lilydark
    if b.locp[0] == 'w' and b.vowel[0] == 'u' and len(b.vowel) > 1:
        b.consonant = 'w'
        b.vowel = b.vowel[1:]
    
    if a.locp[0] == 'w' and a.vowel[0] == 'u' and len(a.vowel) > 1:
        a.consonant = 'w'
        a.vowel = a.vowel[1:]
    
    if a.locp[0] == 'y' and a.vowel[0] == 'u' and len(a.vowel) > 1:
        a.consonant = 'y'
        a.vowel = a.vowel[1:]
        if a.vowel[-1] == ':':
            a.vowel = a.vowel[:-1]

    if b.locp[0] == 'y' and b.vowel[0] == 'u' and len(b.vowel) > 1:
        b.consonant = 'y'
        # b.vowel = b.vowel[1:]
        if b.vowel[-1] == ':':
            b.vowel = b.vowel[:-1]

自己写代码先修了一下,总之就是pypinyin这个库对这两个的识别和其他的是不一样的

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions