Skip to main content


OpenPecha

Python Tibetan Unicode to Wylie (EWTS) Converter

Description • Installation • Examples • License • Maintenance • Owner


Description

The goal of this code is to provide a library to convert back and forth between Tibetan Unicode and EWTS. The code is adapted from Java ewts-converter.

It also provides a conversion from the ACIP Transliteration to EWTS.

Installation

pip install pyewts

Examples

Convert Wylie to Unicode

import pyewts

converter = pyewts.pyewts()
print(converter.toUnicode("ba b+ba [a] ba\\u0f0b"))
# བ་བྦ་a་བ་

Convert Unicode to Wylie

print(converter.toWylie("༼༽"))
# ()

Catch Wylie warnings

>>> orig = """dangs
... zhwa
... dwang
... rma
... tshe
... phywa
... dge
... rgya
... dwags
... (rtse mgron)"""
>>> 
>>> print(orig)
dangs
zhwa
dwang
rma
tshe
phywa
dge
rgya
dwags
(rtse mgron)
>>> warns = []
>>> res = converter.toUnicode(orig, warns)
>>> print(res)
དངས
ཞྭ
དྭང
རྨ
ཚེ
ཕྱྭ
དགེ
རྒྱ
དྭགས
༼རྩེ་མགྲོན༽
>>> print(warns)
['line 1: "dangs": Syllable should probably be "dngas".']

See demo.py

License

The Python code is Copyright (C) 2018 Esukhia, provided under MIT License. See CONTRIBUTORS.md for a list of authors and contributors.

Maintenance

Build the source dist:

rm -rf dist/
python -m build

or with pip:

pip install build
python -m build

Upload on twine (version >= 1.11.0) with:

twine upload dist/*

Owner

Release files for pyewts 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyewts 1.0.0
File Size Uploaded
pyewts-1.0.0.tar.gz 23.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pyewts 1.0.0
File Interpreter ABI Platform
pyewts-1.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 46.0 kB

Release files / pyewts-1.0.0.tar.gz

Download URL pyewts-1.0.0.tar.gz
Size 23.5 kB
Tags Source
SHA-256 checksum
How to use checksums
d96516abb063ba5fac87d6b2e6457ad7f8e90ea740cfbc3b07055864d29527cb
BLAKE2b-256 checksum
How to use checksums
7880a09f26789b27eb905ec37b8cc361e26f32550e933b86f13f33e43f3470ef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.2

Release files / pyewts-1.0.0-py3-none-any.whl

Download URL pyewts-1.0.0-py3-none-any.whl
Size 22.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
73b52e4469dbb47bcbabe422bb2dbec88f657bb44a0017b9ba3166bb50c076e5
BLAKE2b-256 checksum
How to use checksums
c4ec17ab2aa3919563cde601c721e5258eb972d6be1bff5deaeaa9d33925e554
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.2

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files

0.2.0

1 release file

0.1.3

1 release file

0.1.2

1 release file

0.1.1

1 release file

0.1.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page