- Install Python 3.6.x or above (the current version is
3.8.x
). - Note that lower versions of Python will not be compatible to this course.
- Login to Github (create an account if you do not have one).
- Create a new repository called
cs329
and make it PRIVATE. - From the
[Settings]
menu, add the TAs as collaborators of this repository.- Sarah Fillwock:
sfillwo
. - Liyan Xu:
lxucs
.
- Sarah Fillwock:
- Install PyCharm on your local machine.
- The following instructions assume that you have "PyCharm 2019.3 Professional Edition".
- You can get the professional version by applying for the academic license.
- Add your Github account:
- Go to
[Preferences] - [Version Control] - [Github]
. - Click the
+
button, and enter your Github ID and password. - If you are using two-factor authentication, click
[Use Token]
and login with your personal access token.
- Go to
- Create a new project:
- Click
[Get from Version Control]
and choose[GitHub]
on the left menu. - Select the
cs329
repository and clone it. Make sure the directory name iscs329
.
- Click
- Setup the interpreter:
- Go to
[Preferences] - [Project: cs329] - [Project Interpreter]
. - Click the gear button on the righthand side and select
Add
. - In the prompted window, select
[Virtualenv Environment]
and choosePython 3.6.x
as the base interpreter.
- Go to
- Install a package:
- Go to
[Preferences] - [Project: cs329] - [Project Interpreter]
. - Click the
+
button at the bottom. - Search and install for the
numpy
package.
- Go to
- Create a new package:
- Open a terminal in PyCharm.
- Install Jupyter Notebook by entering the following command (this is another way of installing a package):
pip install jupyter
- Enter the following command to launch Jupyter Notebook:
(venv) $ jupyter notebook
- On the web-browser where it is launched, choose the
src/quiz/
directory. - Create a new notebook called
quiz0.ipynb
and run the code inquiz0.py
. - If it prompts
[10 14 18]
, your notebook runs successfully.
- From PyCharm, add the followings to git by right clicking on those files and choosing
[Git] - [Add]
:quiz/quiz0.ipynb
quiz/quiz0.py
- Once the files are added to git, they should turn into green. If not, restart PyCharm and add the files again.
- Create a file called
.gitignore
under thecs329
directory and copy the followings:.idea/ venv/ **/.ipynb_checkpoints/
- Commit and push your changes to Github:
- Right click on
cs329
, choose[Git] - [Commit Directory]
, enter a commit message (e.g., "Submit quiz 0."), and click the[Commit and Push]
button. - Make sure ones in
.gitignore
are not getting pushed to Github.
- Right click on
- Check if the above files are properly pushed to your Github respoistory.
- Submit the address of your
cs329
repository (e.g., https://github.com/your_id/cs329.git) to https://canvas.emory.edu/courses/71182/assignments/294068