Created
November 27, 2015 05:21
-
-
Save mrdrozdov/41c0a71a0ed47f81b1e9 to your computer and use it in GitHub Desktop.
NYU SSH Tips
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### | |
| # Prerequisites | |
| 1. Sign Up for CIMS account | |
| 2. Request a data folder | |
| 3. Request extra space | |
| ### | |
| # Tips | |
| # Setup SSH (no longer need password) | |
| http://www.courant.nyu.edu/webapps/content/systems/userservices/netaccess/sshkeys | |
| # Use rsync to keep directories in sync on mac | |
| brew install fswatch | |
| fswatch -o <dir-to-watch> | xargs -n1 -I{} rsync -a <local-dir> <usr>@<host>:<remote-dir> | |
| # Concrete example | |
| fswatch -o ./ | xargs -n1 -I{} rsync -a ./ apd283@access.cims.nyu.edu:/home/apd283/Developer/sandbox-rsync | |
| ### | |
| # From Local Machine | |
| # SSH into CIMS Machine | |
| ssh apd283@access.cims.nyu.edu -A | |
| ### | |
| # From CIMS Machine | |
| # SSH into GPU Machine | |
| ssh apd283@cuda2.cims.nyu.edu -A | |
| ### | |
| # On GPU Machine | |
| # Load CUDA | |
| module load cuda-5.0 | |
| # Load Python 2.7 | |
| module load python-2.7 | |
| # List Available Modules | |
| module avail | |
| # List Graphics Cards | |
| ./bin/linux/release/deviceQuery | |
| ### | |
| # Stanford NLP Snippets | |
| cat {00,01,02,03,04,05,06,07,08,09,10,11,12,13,14,15,16,17,18}/* | grep "( (S" | wc -l | |
| cat {19,20,21}/* | grep "( (S" | wc -l | |
| cat {22,23,24}/* | grep "( (S" | wc -l | |
| # Regex to read TreeBank line by line | |
| ^[^\s](?:(?!^[^\s]).|\n)+ | |
| source & explained: http://stackoverflow.com/questions/3850074/regex-until-but-not-including | |
| (?: # Match the following but do not capture it: | |
| (?!lazy) # (first assert that it's not possible to match "lazy" here | |
| . # then match any character | |
| )* # end of group, zero or more repetitions. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment