anoopkunchukuttan / indic_nlp_library

Resources and tools for Indian language Natural Language Processing
http://anoopkunchukuttan.github.io/indic_nlp_library/
MIT License
546 stars 158 forks source link

Issue in Romanization #38

Open Sreelakshmi-k opened 3 years ago

Sreelakshmi-k commented 3 years ago

Sir i tried the code pasted below for romanising the hindi script. But when i run the code the script is not getting romanised. The output that I get is ाजान. Please let me know how can i get the proper romanised script.

from indicnlp.transliterate.unicode_transliterate import ItransTransliterator

input_text='राजस्थान'

input_text='ஆசிரியர்கள்'

lang='hi'

print(ItransTransliterator.to_itrans(input_text,lang))

talent404 commented 3 years ago

I am also facing the same issue.

SimengSun commented 3 years ago

I also have the same issue.

anilkumar911 commented 2 years ago

INDIC_NLP_RESOURCES needs to set for this to work

$ python3
Python 3.9.5 (default, May 11 2021, 08:20:37) 
[GCC 10.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> INDIC_NLP_LIB_HOME='/home/axlolotl/git/indic_nlp_library'
>>> INDIC_NLP_RESOURCES='/home/axlolotl/git/indic_nlp_resources/'
>>> from indicnlp import common
>>> common.set_resources_path(INDIC_NLP_RESOURCES)
>>> from indicnlp import loader
>>> loader.load()
>>> from indicnlp.transliterate.unicode_transliterate import ItransTransliterator
>>> input_text='राजस्थान'
>>> lang='hi'
>>> print(ItransTransliterator.to_itrans(input_text,lang))
raajasthaana
Sreelakshmi-k commented 2 years ago

Thank you. But this is creating the error "AttributeError: 'DataFrame' object has no attribute 'ix'" at loader.load(). Can you please help

anoopkunchukuttan commented 2 years ago

What is the version of pandas that you are using?

Sreelakshmi-k commented 2 years ago

It is 1.0.1