shini-tm / neural_sketch

neural sketch project, currently in generative regex, list transformation (deepcoder), and text editing (robustfill) domains
0 stars 0 forks source link

NEURAL SKETCH PROJECT

This is the code used for the ICML 2019 paper Learning to Infer Program Sketches.

Usage:

A user should only have to go into the train folder, the eval folder, and the plot folder. train and eval folders have train and eval scripts for each domain.

the train folder is where the training scripts are. You should run from the top level directory, with the --pretrain flag, the first time you run. ex:

anaconda-project run python main_supervised_deepcoder.py --pretrain

To fully train the SketchAdapt system, first train the synthesizer (referred to as the dc_model in the codebase):

python train/deepcoder_train_dc_model.py

and pretrain the sketch generator:

python train/main_supervised_deepcoder.py --pretrain

Then train the sketch generator:

python train/main_supervised_deepcoder.py

Evaluation can be run with:

python eval/evaluate_deepcoder.py

NB: On the MIT openmind computer cluster, the *.sh files are used to schedule jobs. I usually do the following:

sbatch execute_gpu.sh python main_supervised_deepcoder.py --pretrain

THINGS TO NOTE