Skip to main content

Packing transcoder model

Project description

TransCoder Package

This is a library implementation of the infamous Transcoder model Unsupervised Translation of Programming Languages Model

Usage

Installation

Create a virtual environment and activate it:

virtualenv venv --python=python3.8
source venv/bin/activate

Install library

pip install transcode

If your libclang.so is not in /usr/lib/llvm-10/lib/, replace the path to libclang.so to the correct path in clang.cindex.Config.set_library_path('path_to_libclang') in code_tokenizer.py

Translate

Just provide the target and source langauges and the code, and we handle the rest :wink:

translate --src_lang python --tgt_lang java < input_code.cpp

Train or Evaluate

To train or evaluate the model, please refer to the original repository.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

transcode-1.2.0.tar.gz (81.1 kB view hashes)

Uploaded Source

Built Distribution

transcode-1.2.0-py3-none-any.whl (94.7 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page