Skip to content

An example script for setting up your Python, ML & DL related environment on cluster

Notifications You must be signed in to change notification settings

statsml/cluster-setup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cluster-setup

How-to

When you install the cuda GPU library and tensorflow, please check wheather they are compatible. You also should check python default version and pip default version.

SSH login cluser:

ssh `username@hostaddress`

Install git on the cluster

apt-get install git

Setup from the scrtip

. `cluster-setup.sh`

SSH tricks & FAQ

1. screen

Sometimes you want to run some scripts via command line, and you may close the command line and check the results later. Then you can use screen.

  • Start a screen
screen -S `your-preferred-screen-name`
  • Use ctrl+A, ctrl+D to leave the screen.

  • Check results later

screen -r `your-preferred-screen-name`
  • Kill a screen
screen -S  `your-preferred-screen-name` -X quit
  • Alternative: tmux

2. error from matplotlib

Source

You want to save image, but you may get _tkinter.TclError: no display name and no $DISPLAY environment variable. You can simply run the following command before running your code:

export MPLBACKEND="agg"

3. cuda9 not compatible for tensorflow

sudo apt autoremove cuda

use cuda8 instead

sudo apt-get install cuda-8-0

4. split data larger than 25MB to update to GitHub

  • help
man split
  • Command
split --byte="20M" `file_name` `prefix for the splitted file`

or

split -b 20m `file_name` `prefix for the splitted file`

e.g.

split --byte="25M" `largefile` `part`
  • post process move the spliited files to a folder file_name
mv prefix* `./file_name`

e.g.

mv part* `./largefile`
  • merge
cat * > `file_name`

Authors

References

  • CS231n: Google Cloud Tutorial. link

About

An example script for setting up your Python, ML & DL related environment on cluster

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published