Re: Encoding for Devanagari Script.

2008-07-28 Thread Atul.
Hi Fredrik and Terry, Well I got this on IDLE I think I have done something wrong. import codecs f = open(C:\Documents and Settings\admin\My Documents\corpus\dainaikAikya collected by sushant.txt,r, utf_8) Traceback (most recent call last): File pyshell#1, line 1, in module f =

Re: Encoding for Devanagari Script.

2008-07-28 Thread Tim Golden
Atul. wrote: Hi Fredrik and Terry, Well I got this on IDLE I think I have done something wrong. import codecs f = open(C:\Documents and Settings\admin\My Documents\corpus\dainaikAikya collected by sushant.txt,r, utf_8) Traceback (most recent call last): File pyshell#1, line 1, in module

Re: Encoding for Devanagari Script.

2008-07-28 Thread Atul.
Thanks, Tim that did work. I will proceed with my playing around now. Thanks a ton. Atul. Only slightly. You're importing the codecs module but you're not using it. So you're *actually* using the built-in open function, which doesn't have an encoding parameter. It does have a third param

Encoding for Devanagari Script.

2008-07-24 Thread Atul.
Hello All, I wanted to know what encoding should I use to open the files with Devanagari characters. I was thinking of UTF-8 but was not sure, any leads on this? Anyone used it earlier? Thanks in Advance. Regards, Atul. -- http://mail.python.org/mailman/listinfo/python-list

Re: Encoding for Devanagari Script.

2008-07-24 Thread Fredrik Lundh
Atul. skrev: I wanted to know what encoding should I use to open the files with Devanagari characters. I was thinking of UTF-8 but was not sure, any leads on this? Anyone used it earlier? Are we talking about existing files? If you don't know what encoding the files use, you could always

Re: Encoding for Devanagari Script.

2008-07-24 Thread Terry Reedy
Atul. wrote: Hello All, I wanted to know what encoding should I use to open the files with Devanagari characters. I was thinking of UTF-8 but was not sure, any leads on this? Anyone used it earlier? You cannot hurt your machine by giving that a try. This is a general comment for all