{"id":17031362,"url":"https://github.com/breandan/tf-sru","last_synced_at":"2026-05-13T05:32:20.065Z","repository":{"id":128783521,"uuid":"112149122","full_name":"breandan/tf-sru","owner":"breandan","description":"TF SRU implementation. Part of the ICLR 2018 Reproducibility Challenge: www.cs.mcgill.ca/~jpineau/ICLR2018-ReproducibilityChallenge.html","archived":false,"fork":false,"pushed_at":"2017-12-03T05:23:42.000Z","size":3,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-01-28T00:41:54.548Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/breandan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-11-27T04:56:46.000Z","updated_at":"2018-01-06T20:40:54.000Z","dependencies_parsed_at":"2023-04-15T22:33:00.037Z","dependency_job_id":null,"html_url":"https://github.com/breandan/tf-sru","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/breandan%2Ftf-sru","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/breandan%2Ftf-sru/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/breandan%2Ftf-sru/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/breandan%2Ftf-sru/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/breandan","download_url":"https://codeload.github.com/breandan/tf-sru/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245020314,"owners_count":20548156,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-14T08:23:54.154Z","updated_at":"2026-05-13T05:32:15.046Z","avatar_url":"https://github.com/breandan.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# tf-sru\n\n## Progress so far\n\n- [x] Setup GCE instance for training\n  - [X] Obtain GCP approval for additional GPUs\n- [X] Reproduce author's SRU implementation\n- [X] Reproduce classification model\n- [ ] Reproduce question answering model\n- [X] Reproduce langauge model\n- [ ] Reproduce translation model\n- [ ] Reproduce speech model\n- [ ] Rewrite in TensorFlow\n\n\n## Steps taken to reproduce language model:\n\n*Reproduced on Intel x86_64 with NVIDIA K80 GPU running Ubuntu 17.04.*\n\n1. Install CUDA 8.0 following [NVIDIA Installation Guide](http://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html).\n2. Install Anaconda for Python 2.7: `conda create -n py27 python=2.7 anaconda`.\n3. Activate new conda environment: `source activate py27`\n4. Clone source repo: `git clone https://github.com/taolei87/sru`\n5. Install requirements: `pip install -r sru/requirements.txt`.\n6. Download LSTM training data: `git clone https://github.com/yoonkim/lstm-char-cnn`\n7. Export required paths: `export LD_LIBRARY_PATH=/usr/local/cuda/lib64 \u0026\u0026 export PYTHONPATH=./sru`\n8. Run LM training example: `python sru/language_model/train_lm.py --train lstm-char-cnn/data/ptb/train.txt --test lstm-char-cnn/data/ptb/test.txt --dev lstm-char-cnn/data/ptb/valid.txt`\n\n## Steps taken to reproduce classification:\n\n1. Install CUDA 8.0 following [NVIDIA Installation Guide](http://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html).\n2. Install Anaconda for Python 2.7: `conda create -n py27 python=2.7 anaconda`.\n3. Activate new conda environment: `source activate py27`\n4. Clone source repo: `git clone https://github.com/taolei87/sru`\n5. Install requirements: `pip install -r sru/requirements.txt`.\n8. Install PyTorch: `conda install pytorch torchvision cuda80 -c soumith`\n6. Download the dataset from  https://github.com/harvardnlp/sent-conv-torch/tree/master/data\n7. Download a pre-trained word embedding such as word2vec from https://github.com/mmihaltz/word2vec-GoogleNews-vectors or lexVec from https://github.com/alexandres/lexvec (in text format, not binary)\n8. Export required paths: `export LD_LIBRARY_PATH=/usr/local/cuda/lib64 \u0026\u0026 export PYTHONPATH=./sru`\n9. Run the classification example: python train_classifier2.py --path PATH_TO_DATASET \n--embedding PATH_TO_WORD_EMBEDDING --max_epoch 10 --cv 0\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbreandan%2Ftf-sru","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbreandan%2Ftf-sru","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbreandan%2Ftf-sru/lists"}