Applied SSHs: Part 2
This follows from the previous post. When I’m doing big computations, I usually would like to run tasks on a cloud or server machine. However before I deploy my production code, I still need to do some ‘local testing’. Sometimes this ‘local testing’ requires a large CPU or GPU, which unfortunately is unavailable on laptops (I use mini HP laptops for work). I do, however, have my MLBox, which is a PC that tmikey and I built with the following specifications:
- AMD Ryzen 7 3700X Processor
- Gigabyte GeForce RTX 2060 Super Gaming OC 8G
- HyperX HX432C16PB3K2/32 Predator DDR4 32 GB (Kit 2 x 16 GB), 3200 MHz CL16 DIMM XMP
This is usually big enough for me to play around with my models, but I do have access to other supercomputers if needs be. Here is a picture of it:
Anyway, to make it easy for local testing, I usually setup remote access to Jupyter notebooks hosted on server and use it on my browser on my laptop. So first we have to setup a jupyter notebook server on the remote machine:
jupyter notebook --no-browser --port=port_number
Then on your local machine, tunnel in:
ssh -N -f -L port_number:localhost:port_number username@server_address
or just
ssh -N -f -L port_number:localhost:port_number server_alias
if you’ve set it up in ~/.ssh/config
.
Now type in localhost:port_number
in your local browser to use your remote notebook!