virtualvinodh / aksharamukha

Aksharamukha
161 stars 41 forks source link

Any way to convert accented Vedic script? #86

Open vijnasu opened 3 years ago

vijnasu commented 3 years ago

Is there any way to convert the texts similar to the ones in the link - http://gretil.sub.uni-goettingen.de/gretil/1_sanskr/1_veda/1_sam/avs_acu.htm to Devnagari and other Indian fonts? Or any other method is there to convert any accented Vedic text from its source format to Indian languages?

vbharadvaja commented 3 years ago

Namaskara sir, this Google sheet makes the conversions to IAST with svaras like in Indian scripts: https://docs.google.com/spreadsheets/d/13iSPO2DIVko2O_WGQtpgJ8_Cd1v6lB2gcrfhzmkKlaI/edit?usp=drivesdk

You can make a copy of this sheet and convert the text to IAST. The IAST can then be put thru Aksharamukha to get the text in any Indian script.

Caveat:

Screenshot_20210112-185244__01.jpg

As the instances of jatya and kampa svaritas cannot be differentiated without use of an entire dictionary, the marking must be done manually.

virtualvinodh commented 3 years ago

@vbharadvaja Would you mind sharing the steps for the conversion? I can try to implement this in Aksharamukha itself.

V

vbharadvaja commented 3 years ago

Sure.

I first get the accents of each vowel in the sentence as a string (aigu = udatta (U), grave = independent svarita (I), unaccented = unaccented (*)).

Then by these rules, the phonetic accents can be obtained:

U -> AU I -> AI U -> US Consecutive 's at start of sentence all become A's Any remaining *'s and U's become unmarked.

(A = anudatta, S = svarita)

Then the string of phonetic accents can be used to replace the vowels in the original sentence with the converted values, where A -> "॒" and I, S -> "॑". Optionally independent svaritas can be made to stand out by marking them with an asterisk.

I've uploaded my code here: [https://github.com/vbharadvaja/vedic-accent-converter]()

virtualvinodh commented 3 years ago

@vbharadvaja Thanks a lot :)

Makes my job easier!

V

vvasuki commented 3 years ago

@vbharadvaja https://vishvasa.github.io/vedAH/atharva/shaunakam/rUDha-saMhitA/vishvAsa-prastutiH/01/001_medhAjananam/ might interest you. jAtyasvarita-s are marked there.

vvasuki commented 3 years ago

https://groups.google.com/g/sanskrit-programmers/c/x_K7MZi5oKI might be of interest as well.

vbharadvaja commented 3 years ago

Thanks, ji

I will definitely check these out.

nsesha92 commented 1 year ago

need to add Roman (GRETIL) encoding for this.

http://gretil.sub.uni-goettingen.de/gretil/1_sanskr/1_veda/1_sam/avs_acu.htm