Adding cd to code blocks and a couple of other clarifications

This commit is contained in:
kungfujam 2015-10-01 11:56:34 +01:00
parent 1da99ab2e7
commit ea20bfc0aa

View File

@ -49,7 +49,7 @@
"\n", "\n",
" * `mkdir -p ~/mlpractical/repos-3rd`\n", " * `mkdir -p ~/mlpractical/repos-3rd`\n",
"\n", "\n",
"And now, let us set an MLP_WDIR environmental variable (MLP Working DIRectory) that will keep an absolute path of working dir pointing to `~/mlpractial`, **add the below line** to your `~/.bashrc` file (if it does not exists, create one!):\n", "And now, let us set an MLP_WDIR environmental variable (MLP Working DIRectory) that will keep an absolute path of working dir pointing to `~/mlpractial`, **add the below line** to your `~/.bashrc` file (if it does not exists, create one using a text editor! e.g. by running `gedit ~/.bashrc`):\n",
"\n", "\n",
"```\n", "```\n",
"export MLP_WDIR=~/mlpractical\n", "export MLP_WDIR=~/mlpractical\n",
@ -98,9 +98,10 @@
"\n", "\n",
"#### OpenBlas\n", "#### OpenBlas\n",
"\n", "\n",
"Enter again repos-3rd directory (`cd ~/mlpractical/repos-3rd) and copy into terminal the following commands (one at the time):\n", "Enter again repos-3rd directory and copy into terminal the following commands (one at the time):\n",
"\n", "\n",
"```\n", "```\n",
"cd ~/mlpractical/repos-3rd\n",
"OBDir=$MLP_WDIR/repos-3rd/OpenBLAS\n", "OBDir=$MLP_WDIR/repos-3rd/OpenBLAS\n",
"git clone git://github.com/xianyi/OpenBLAS\n", "git clone git://github.com/xianyi/OpenBLAS\n",
"cd OpenBLAS\n", "cd OpenBLAS\n",
@ -120,7 +121,8 @@
"\n", "\n",
"```\n", "```\n",
"source ~/.bashrc\n", "source ~/.bashrc\n",
"source ~/mlpractical/venv/bin/activate\n", "activate_mlp # This is the alias you set up in the bashrc\n",
"#source ~/mlpractical/venv/bin/activate\n",
"```\n", "```\n",
"\n", "\n",
"to rerun the bash start up script make sure the new environment variable is available in the current shell and then reactivate the virtual environment.\n", "to rerun the bash start up script make sure the new environment variable is available in the current shell and then reactivate the virtual environment.\n",
@ -146,19 +148,25 @@
"python setup.py install\n", "python setup.py install\n",
"```\n", "```\n",
"\n", "\n",
"Now use pip to install remaining packages: `scipy`, `matplotlib`, `argparse`, `nose`,\n", "Now use pip to install remaining packages: `scipy`, `matplotlib`, `argparse`, and `nose` by executing:\n",
"\n",
"```\n",
"pip install scipy matplotlib argparse nose\n",
"```\n",
"\n", "\n",
"### Getting the mlpractical repository\n", "### Getting the mlpractical repository\n",
"\n", "\n",
"Clone the course repository from the github, by navigating to `~/mlpractical` directory and typing:\n", "Clone the course repository from the github, by navigating to `~/mlpractical` directory and typing:\n",
"\n", "\n",
"```\n", "```\n",
"cd $MLP_WDIR\n",
"git clone https://github.com/CSTR-Edinburgh/mlpractical.git repo-mlp\n", "git clone https://github.com/CSTR-Edinburgh/mlpractical.git repo-mlp\n",
"```\n", "```\n",
"\n", "\n",
"When download is ready, enter the repo-mlp directory (`cd repo-mlp`) and start the actual interactive notebook session by typing:\n", "When download is ready, enter the repo-mlp directory and start the actual interactive notebook session by typing:\n",
"\n", "\n",
"```\n", "```\n",
"cd repo-mlp\n",
"ipython notebook\n", "ipython notebook\n",
"```\n", "```\n",
"\n", "\n",
@ -231,6 +239,9 @@
}, },
"outputs": [], "outputs": [],
"source": [ "source": [
"# Remove the below line if not running this code in an ipython notebook\n",
"# It's a special command allowing the notebook to display plots inline\n",
"%matplotlib inline\n",
"import matplotlib.pyplot as plt\n", "import matplotlib.pyplot as plt\n",
"\n", "\n",
"x = numpy.linspace(0.0, 2*numpy.pi, 100)\n", "x = numpy.linspace(0.0, 2*numpy.pi, 100)\n",
@ -381,7 +392,7 @@
"name": "python", "name": "python",
"nbconvert_exporter": "python", "nbconvert_exporter": "python",
"pygments_lexer": "ipython2", "pygments_lexer": "ipython2",
"version": "2.7.9" "version": "2.7.5"
} }
}, },
"nbformat": 4, "nbformat": 4,