{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "\n", "\n", "\n", "\"Open\n", "\n" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "# Initializing course environment" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## 1 Install Python and the needed external packages\n", "\n", "### (alternative a) Install full anaconda distribution\n", "\n", "* This is the recommended alternative\n", "* Will take about 3.3 gigabytes of disk space\n", "* Download the anaconda installer for your OS (64bits, Python 3) from https://www.anaconda.com/download\n", "* Install anaconda\n", " * **Linux:** On command line run `bash nameofthedownloadedfile`\n", " * **Windows:** Execute the installer you downloaded\n", "* Follow the instructions of the installer\n", "* Takes about 3 minutes\n", "* **windows:** In the anaconda navigator, start the conda prompt.\n", "* Verify that your installation is complete by downloading the script [versions.py](https://raw.githubusercontent.com/saskeli/data-analysis-with-python-summer-2019/master/versions.py) and run it with `python3 versions.py`.\n", "\n", "### (alternative b) Install miniconda and Python packages\n", "* This alternative is not recommended\n", "* Will take about 2.3 gigabytes of disk space\n", "* Download miniconda installer (64bits, Python 3) from https://conda.io/miniconda.html\n", "* Run the installer\n", " * **Linux:** On the command line run `bash nameofthedownloadedfile`\n", " * **Windows:** Execute the downloaded installler\n", "* Activate the miniconda environment\n", " * **Linux and MacOS:** `source /miniconda/install/location/bin/activate`\n", " * **Windows:** Start the anaconda command prompts\n", "* Download the [requirements.txt](https://raw.githubusercontent.com/saskeli/data-analysis-with-python-summer-2019/master/requirements.txt) file\n", "* Install the required packages with `conda install --yes --file requirements.txt`\n", " This may take awhile. (About 1 min 30 s on fast network)" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## 2 Log in to the course\n", "\n", "* Go to the [exercise page](https://tmc.mooc.fi/org/hy/courses/488) of the course\n", "* If you don't already have an account on this server, press the signup button\n", "* Use your student number as the organizational id, if you want to get credits from this course.\n", " Note for old-timers: it is not enough, that you have your student number as your user name in TMC, \n", " in fact, that is not even recommended anymore.\n", "* Choose organization Helsingin yliopisto\n", "* Choose course Data Analysis with Python Summer 2019" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## 3 Install TMC client\n", "\n", "* TMC requires a fairly modern java 8 or later to work properly.\n", " * open jdk 1.8.0_212 for example works\n", " * as do all 11.x and 12.x versions i've seen.\n", " * you can try to install and run tmc and update your java install if logging in with the cli fails.\n", "* Follow the instructions on the following page to install TMC client \n", " https://github.com/testmycode/tmc-cli\n", "* Note that on this course we use the command line version of TMC, not netbeans or any other IDE. So, you need to know the basics of command line use in the terminal/command prompt\n", "* Go to a folder where you want to download the exercises, and issue command `tmc login`\n", "* If it asks for a server address, then your TMC client is outdated. Re-install the client. Note, that the installation script was updated very recently (12.3.2019). So, if you had problems with it, you might want to try again.\n", "* Provide login details, and use organization slug `hy`\n", "* Then issue command `tmc download hy-data-analysis-with-python-summer-2019` to download the exercises\n", "* Important commands:\n", " * `tmc` to show help message\n", " * `tmc test` to test your solution locally\n", " * `tmc submit` to submit your solution to the server for grading\n", "* The above github page of the tmc-client also contains instructions on the use of the client" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Note for windows users\n", "\n", "As there is no installer, you get the tmc cli client by downloading the latest `.jar` file from releases. To actually run the tmc cli you issue the exact commands below but substituting `tmc` with `java -jar .jar` as specified [here](https://github.com/testmycode/tmc-cli#manual-installation). \n", "\n", "You may want to alias the `java -jar .jar` -part of the command so that just the command `tmc` works on windows as well. This can be done according to [these instructions](https://superuser.com/questions/1134368/create-permanent-doskey-in-windows-cmd).\n", "\n", "* Create a `aliases.cmd` file\n", "* Add the following to the file:\n", " ```\n", " @echo off\n", " doskey tmc=java -jar $*\n", " ```\n", "* In [`regedit`](https://support.microsoft.com/en-us/help/4027573/windows-10-open-registry-editor), browse to `HKEY_CURRENT_USER\\Software\\Microsoft\\Command Processor`\n", "* Create a new registry key-value pair of type `REG_EXPAND_SZ`, with name `AutoRun` and the path to the aliases file as value\n", "* Now the `tmc` alias should always be added when a new console is opened\n", "\n", "Thanks to @Eeero for the step-by-step instructions." ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "\n", "\n", "\n", "\"Open\n" ] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.6.8" }, "varInspector": { "cols": { "lenName": 16, "lenType": 16, "lenVar": 40 }, "kernels_config": { "python": { "delete_cmd_postfix": "", "delete_cmd_prefix": "del ", "library": "var_list.py", "varRefreshCmd": "print(var_dic_list())" }, "r": { "delete_cmd_postfix": ") ", "delete_cmd_prefix": "rm(", "library": "var_list.r", "varRefreshCmd": "cat(var_dic_list()) " } }, "types_to_exclude": [ "module", "function", "builtin_function_or_method", "instance", "_Feature" ], "window_display": false } }, "nbformat": 4, "nbformat_minor": 2 }