Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #57081

Re: Looking for UNICODE to ASCII Conversioni Example Code

Path csiph.com!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <z@etiol.net>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.116
X-Spam-Level *
X-Spam-Evidence '*H*': 0.77; '*S*': 0.00; 'url:pypi': 0.03; 'ascii': 0.09; 'i.e.,': 0.16; 'wrote:': 0.18; 'seems': 0.21; '>>>': 0.22; 'example': 0.22; 'import': 0.22; 'header:User-Agent:1': 0.23; 'subject:Code': 0.24; 'unicode': 0.24; 'this:': 0.26; 'post': 0.26; 'header:In-Reply-To:1': 0.27; 'leave': 0.29; 'characters': 0.30; '-0700,': 0.31; 'work:': 0.31; 'url:python': 0.33; 'fri,': 0.33; 'received:209.85': 0.35; 'skip:u 20': 0.35; 'received:google.com': 0.35; 'url:org': 0.36; 'received:209': 0.37; 'handle': 0.38; 'to:addr:python-list': 0.38; 'to:addr:python.org': 0.39; 'remove': 0.60; 'skip:u 10': 0.60; 'conversion': 0.61; 'content-disposition:inline': 0.62; 'email addr:gmail.com': 0.63; 'received:190': 0.69; '8bit%:100': 0.72; 'characters,': 0.84; 'received:190.163': 0.84; '2013': 0.98
X-Google-DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:subject:message-id:references :mime-version:content-type:content-disposition :content-transfer-encoding:in-reply-to:user-agent; bh=b9nPWmQcDfqRYORY7PJ4mVkHx23FzJKajHds7grHfXA=; b=R71ZATu4eP+P8Vngx3vfQe7LOv9w9NzjulLMSmLgljHL2jJxr/xyIQruDopR1yKCif RFidWCXpbg0WR/fLLGir1SljZZQnCJ3ljbhZGIvXt8S/AgjO+FaghE4apJRybNEa0snZ 7DUCmi07FHBOIa/0rR7qTd3AFKwJ5gD42L4Qn8c3h01n6/uTVyliBvWzh9JdnBMZeh6E 11sC3Y66StQJg5goLAlV+WQ7CtZSiiomnzbSzreE/AkveOuIUxY92hT7CTTxhfeRGOJa LBgBDXtLLH+88s9M16eufnA7yNrq4sF0BkOdLlQwHLVkxyLUeZwzMlcKVt5wkz9xDVvp BCZw==
X-Gm-Message-State ALoCoQmS5jVKfiUBLg7G1rSQyFjzw24Jm2xpja9KGaOV3zuyehhW/Z4CoxMfc7zAFXN6eDgjiX0e
X-Received by 10.236.86.42 with SMTP id v30mr2114024yhe.92.1382133779712; Fri, 18 Oct 2013 15:02:59 -0700 (PDT)
Date Fri, 18 Oct 2013 19:02:54 -0300
From Zero Piraeus <z@etiol.net>
To python-list@python.org
Subject Re: Looking for UNICODE to ASCII Conversioni Example Code
References <e7c0c225-bfd0-43a7-adfc-1b7639014c48@googlegroups.com>
MIME-Version 1.0
Content-Type text/plain; charset=utf-8
Content-Disposition inline
Content-Transfer-Encoding 8bit
In-Reply-To <e7c0c225-bfd0-43a7-adfc-1b7639014c48@googlegroups.com>
X-PGP-Key http://etiol.net/pubkey.asc
User-Agent Mutt/1.5.21 (2010-09-15)
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.1246.1382133788.18130.python-list@python.org> (permalink)
Lines 25
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1382133788 news.xs4all.nl 15996 [2001:888:2000:d::a6]:55964
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:57081

Show key headers only | View raw


:

On Fri, Oct 18, 2013 at 01:45:53PM -0700, caldwellinva@gmail.com wrote:
> I am looking for an example of a UNICODE to ASCII conversion example
> that will remove diacritics from characters (and leave the characters,
> i.e., Klüft to Kluft) as well as handle the conversion of other
> characters, like große to grosse.

This:

    https://pypi.python.org/pypi/Unidecode/

... seems to work:

    >>> from unidecode import unidecode
    >>> unidecode("Klüft, große")
    'Kluft, grosse'
    >>> unidecode("Текст декодирует вы")
    'Tekst dekodiruet vy'

 -[]z.

-- 
Zero Piraeus: post scriptum
http://etiol.net/pubkey.asc

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Looking for UNICODE to ASCII Conversioni Example Code caldwellinva@gmail.com - 2013-10-18 13:45 -0700
  Re: Looking for UNICODE to ASCII Conversioni Example Code Zero Piraeus <z@etiol.net> - 2013-10-18 19:02 -0300
  Re: Looking for UNICODE to ASCII Conversioni Example Code Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-10-19 09:19 +0000
    Re: Looking for UNICODE to ASCII Conversioni Example Code Zero Piraeus <z@etiol.net> - 2013-10-19 11:14 -0300
      Re: Looking for UNICODE to ASCII Conversioni Example Code Roy Smith <roy@panix.com> - 2013-10-19 11:10 -0400
        Re: Looking for UNICODE to ASCII Conversioni Example Code rusi <rustompmody@gmail.com> - 2013-10-19 08:26 -0700
      Re: Looking for UNICODE to ASCII Conversioni Example Code Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-10-19 16:16 +0000
        Re: Looking for UNICODE to ASCII Conversioni Example Code Roy Smith <roy@panix.com> - 2013-10-19 09:49 -0700
          Re: Looking for UNICODE to ASCII Conversioni Example Code Chris Angelico <rosuav@gmail.com> - 2013-10-20 09:10 +1100
            Re: Looking for UNICODE to ASCII Conversioni Example Code Roy Smith <roy@panix.com> - 2013-10-19 21:52 -0400
              Re: Looking for UNICODE to ASCII Conversioni Example Code Chris Angelico <rosuav@gmail.com> - 2013-10-20 13:09 +1100
                Re: Looking for UNICODE to ASCII Conversioni Example Code Roy Smith <roy@panix.com> - 2013-10-19 22:13 -0400
                Re: Looking for UNICODE to ASCII Conversioni Example Code Ben Finney <ben+python@benfinney.id.au> - 2013-10-20 13:26 +1100
                Re: Looking for UNICODE to ASCII Conversioni Example Code Chris Angelico <rosuav@gmail.com> - 2013-10-20 13:29 +1100
                Re: Looking for UNICODE to ASCII Conversioni Example Code Mark Lawrence <breamoreboy@yahoo.co.uk> - 2013-10-20 10:11 +0100
  Re: Looking for UNICODE to ASCII Conversioni Example Code Roy Smith <roy@panix.com> - 2013-10-19 08:28 -0400
  Re: Looking for UNICODE to ASCII Conversioni Example Code caldwellinva@gmail.com - 2013-10-19 05:50 -0700

csiph-web