lcbm / cs-machine-learning

:robot: my graduation's machine learning class activities.

Home Page:https://www.cesar.school

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

πŸ€– Machine Learning Course Repo

License Chat

πŸš€ Getting Started

First of all, you will need to clone this repository:

$ git clone https://github.com/lcbm/cs-machine-learning.git

Instead of having you go through the hassle of downloading a bunch of dependencies to your system and dealing with all sorts of conflicts, configurations and so on... we will be using Docker! If this is new to you, don't worry - we will guide you through the process 😜

Feeling curious? Here's an awesome list with a ton of Docker resources, for you to take a look!

🐳 Docker installation and usage

Requirements

Okay, maybe you will have go through some software installation... but I promise that it will only be these two and that after installing Docker and Docker-compose, you won't ever have worry about project dependencies conflicting with system ones anymore 🀩

To install them, please follow the instructions in the links below:

note: if you're using a Linux system, please take a look at Docker's post-installation steps for Linux!

Building and running

Once you have Docker and Docker-compose, change your current working directory to this repository then build and run the container:

# change current working directory
$ cd <path/to/cs-machine-learning>

# start the container in the background of your terminal
$ docker-compose up --detach

At this point, Jupyter Notebook will be running at: http://localhost:8888

πŸ“¦ Installing new packages

There are a few ways you may install packages to the container. It'll depend on your goal and needs.

Pip

If you need to do update or add packages via pip, execute the following command inside your jupyter notebook:

import sys

# install a pip package in the current Jupyter kernel
!{sys.executable} -m pip install <package>

note: the ! notation is used to run pip directly as a shell command from the notebook. Also, take a look here to see why you should NOT use !pip install <package>.

Conda

If you need to do update or add packages via conda, execute the following command inside your jupyter notebook:

import sys

# install a conda package in the current Jupyter kernel
!conda install --yes --prefix {sys.prefix} <package>

note: the ! notation is used to run conda directly as a shell command from the notebook. Also, take a look here to see why you should NOT use !conda install --yes <package>.

System

To add or update system packages, you will need root user permissions. To achieve this, use the following command:

# execute the container's shell
$ docker exec -it --user root tensorflow_notebook /bin/bash

# install a package to the system the container runs on
$ sudo apt install <package>

πŸ‘‹ Wrapping up

Once you're done, you may remove what was created by docker-compose up:

# change current working directory
$ cd <path/to/cs-graph-theory/pyspark>

# stop containers and removes containers, networks, volumes, and images created by `docker-compose up`
$ docker-compose down

🀝 Contributing

If you are interested in helping contribute to the project, please take a look at our Contributing Guide.

πŸ“ License

Copyright Β© 2020-present, CS Machine Learning Contributors. This project is ISC licensed.

About

:robot: my graduation's machine learning class activities.

https://www.cesar.school

License:ISC License


Languages

Language:Jupyter Notebook 100.0%