The assignments will be published to this repository. All assignments will be Jupyter Notebooks. That you have to complete.
The rough workflow is:
- You clone this repository.
- Edit the exercises.
- Push it to your private repository.
- I fetch your code when the assignment is due. (Every Wednesday at 12:00 pm)
- You fetch the latest assignments from this repository.
It is required to use private git repositories. The university offers free private repositories here or you can get GitHub repositories for free as a student.
First clone this repository:
$ git clone --origin upstream https://github.com/BildverarbeitungSS20/Hausaufgaben
Get into the new folder
$ cd Hausaufgaben
Add your remote
$ git remote add origin <your git repo url>
Please clear the notebook's output before committing. Otherwise the repository size can get pretty big. You can use [https://github.com/kynan/nbstripout][nbstripout] which is already a dependency of this repository. Set it up using:
nbstripout --install
Otherwise you manually clean the output with Cell -> All Output -> Clear
.
To get the latest assignments into your repository see how to sync a fork.
Paste a link to your repository into the MyCampus assignment box. Make sure that we have read rights on your repository.
Please give us read access to your repository. Add stsundermann
and goehring
on Github
or ssundermann
as well as drgoehring
on FU GitLab.
Now choose either the Docker container or PyCharm to set up your environment
There exists a script for a docker image. All the libraries we will use are included in this image. It is recommended to use the image, but you are free to setup the environment for yourself.
First install docker on your computer.
Build the image:
$ ./docker_build.sh
The build script will create a user with your username and uid inside the image. It may take some minutes until the image is built.
If you don't have a bash you can manually edit the Dockerfile.sample
.
See the docker documentation for details
To run the image:
$ ./docker_start.sh
Now visit localhost:8888. Jupyter Notebook should be ready to use.
Open the repository in PyCharm. Wait for indexing to complete and open up any assignment notebook file.
PyCharm will now complain because no interpreter is configured. In the warning press Add interpreter
and choose Python 3 inside a virtual environment.
Once again, wait for PyCharm to set up your environment and indexing. Open up the terminal inside PyCharm (it is important to open up the terminal after PyCharm created your virtual environment, if unsure open a new terminal tab) inside PyCharm and install the dependencies:
pip3 install --upgrade -r requirements.txt
Start jupyter lab:
jupyter lab
Now visit localhost:8888. Jupyter Notebook should be ready to use.