VS Code

Overview

VS Code is a free editor from Microsoft, which is open source and support many useful extensions. 

It may be a good alternative to terminal based editors (like vim, nano and Emacs) for some of our users.

Benefits

Using VS Code 

IMPORTANT: don't run computations in VS Code!

Use VS Code only to edit scripts, use linting, etc.

Only run calculations using srun/sbatch

Download and Install

Download and install it on your local machine: download

Setting Up Remote Connections to HPC cluster

More details here: https://code.visualstudio.com/docs/remote/ssh

Login using ssh key

Host greene.hpc.nyu.edu  HostName greene.hpc.nyu.edu  User <netid>  ForwardAgent yes  IdentityFile <path to ssh key>

How to Connect VS Code to a Greene Compute Node

Sometimes users want to connect their VS Code GUI to a compute node, such as to launch a Jupyter Notebook file on Greene. This requires several steps to properly route through Greene's login nodes to the compute nodes in use. Please follow these instructions to connect and run VSCode server on Greene compute node:

ssh greene-compute

More settings

VS Code has many more settings and options. Explore!

Additional notes

High CPU load on login node from VS Code

You may notice (please check with 'top') that your VS Code connection causes 'node' process running from your user to use a lot of CPU resources. One of the reason leading to that - large number of files within your home directory. Try to remove conda and pip environments from the home directory and check if this will resolve the issue.

Python