DAT4 - General Assembly's Data Science course in Washington, DC

Related tags

Deep Learning DAT4
Overview

DAT4 Course Repository

Course materials for General Assembly's Data Science course in Washington, DC (12/15/14 - 3/16/15).

Instructors: Sinan Ozdemir and Kevin Markham (Data School blog, email newsletter, YouTube channel)

Teaching Assistant: Brandon Burroughs

Office hours: 1-3pm on Saturday and Sunday (Starbucks at 15th & K), 5:15-6:30pm on Monday (GA)

Course Project information

Monday Wednesday
12/15: Introduction 12/17: Python
12/22: Getting Data 12/24: No Class
12/29: No Class 12/31: No Class
1/5: Git and GitHub 1/7: Pandas
Milestone: Question and Data Set
1/12: Numpy, Machine Learning, KNN 1/14: scikit-learn, Model Evaluation Procedures
1/19: No Class 1/21: Linear Regression
1/26: Logistic Regression,
Preview of Other Models
1/28: Model Evaluation Metrics
Milestone: Data Exploration and Analysis Plan
2/2: Working a Data Problem 2/4: Clustering and Visualization
Milestone: Deadline for Topic Changes
2/9: Naive Bayes 2/11: Natural Language Processing
2/16: No Class 2/18: Decision Trees
Milestone: First Draft
2/23: Ensembling 2/25: Databases and MapReduce
3/2: Recommenders 3/4: Advanced scikit-learn
Milestone: Second Draft (Optional)
3/9: Course Review 3/11: Project Presentations
3/16: Project Presentations

Installation and Setup

  • Install the Anaconda distribution of Python 2.7x.
  • Install Git and create a GitHub account.
  • Once you receive an email invitation from Slack, join our "DAT4 team" and add your photo!

Class 1: Introduction

  • Introduction to General Assembly
  • Course overview: our philosophy and expectations (slides)
  • Data science overview (slides)
  • Tools: check for proper setup of Anaconda, overview of Slack

Homework:

  • Resolve any installation issues before next class.

Optional:

Class 2: Python

Homework:

Optional:

Resources:

Class 3: Getting Data

Homework:

  • Think about your project question, and start looking for data that will help you to answer your question.
  • Prepare for our next class on Git and GitHub:
    • You'll need to know some command line basics, so please work through GA's excellent command line tutorial and then take this brief quiz.
    • Check for proper setup of Git by running git clone https://github.com/justmarkham/DAT-project-examples.git. If that doesn't work, you probably need to install Git.
    • Create a GitHub account. (You don't need to download anything from GitHub.)

Optional:

  • If you aren't feeling comfortable with the Python we've done so far, keep practicing using the resources above!

Resources:

Class 4: Git and GitHub

  • Special guest: Nick DePrey presenting his class project from DAT2
  • Git and GitHub (slides)

Homework:

  • Project milestone: Submit your question and data set to your folder in DAT4-students before class on Wednesday! (This is a great opportunity to practice writing Markdown and creating a pull request.)

Optional:

  • Clone this repo (DAT4) for easy access to the course files.

Resources:

Class 5: Pandas

Homework:

Optional:

Resources:

  • For more on Pandas plotting, read the visualization page from the official Pandas documentation.
  • To learn how to customize your plots further, browse through this notebook on matplotlib.
  • To explore different types of visualizations and when to use them, Choosing a Good Chart is a handy one-page reference, and Columbia's Data Mining class has an excellent slide deck.

Class 6: Numpy, Machine Learning, KNN

  • Numpy (code)
  • "Human learning" with iris data (code, solution)
  • Machine Learning and K-Nearest Neighbors (slides)

Homework:

  • Read this excellent article, Understanding the Bias-Variance Tradeoff, and be prepared to discuss it in class on Wednesday. (You can ignore sections 4.2 and 4.3.) Here are some questions to think about while you read:
    • In the Party Registration example, what are the features? What is the response? Is this a regression or classification problem?
    • In the interactive visualization, try using different values for K across different sets of training data. What value of K do you think is "best"? How do you define "best"?
    • In the visualization, what do the lighter colors versus the darker colors mean? How is the darkness calculated?
    • How does the choice of K affect model bias? How about variance?
    • As you experiment with K and generate new training data, how can you "see" high versus low variance? How can you "see" high versus low bias?
    • Why should we care about variance at all? Shouldn't we just minimize bias and ignore variance?
    • Does a high value for K cause over-fitting or under-fitting?

Resources:

Class 7: scikit-learn, Model Evaluation Procedures

Homework:

Optional:

  • Practice what we learned in class today!
    • If you have gathered your project data already: Try using KNN for classification, and then evaluate your model. Don't worry about using all of your features, just focus on getting the end-to-end process working in scikit-learn. (Even if your project is regression instead of classification, you can easily convert a regression problem into a classification problem by converting numerical ranges into categories.)
    • If you don't yet have your project data: Pick a suitable dataset from the UCI Machine Learning Repository, try using KNN for classification, and evaluate your model. The Glass Identification Data Set is a good one to start with.
    • Either way, you can submit your commented code to DAT4-students, and we'll give you feedback.

Resources:

Class 8: Linear Regression

Homework:

Optional:

  • Similar to last class, your optional exercise is to practice what we have been learning in class, either on your project data or on another dataset.

Resources:

Class 9: Logistic Regression, Preview of Other Models

Resources:

Class 10: Model Evaluation Metrics

  • Finishing model evaluation procedures (slides, code)
    • Review of test set approach
    • Cross-validation
  • Model evaluation metrics (slides)
    • Regression:
      • Root Mean Squared Error (code)
    • Classification:

Homework:

Optional:

Resources:

Class 11: Working a Data Problem

  • Today we will work on a real world data problem! Our data is stock data over 7 months of a fictional company ZYX including twitter sentiment, volume and stock price. Our goal is to create a predictive model that predicts forward returns.

  • Project overview (slides)

    • Be sure to read documentation thoroughly and ask questions! We may not have included all of the information you need...

Class 12: Clustering and Visualization

  • The slides today will focus on our first look at unsupervised learning, K-Means Clustering!
  • The code for today focuses on two main examples:
    • We will investigate simple clustering using the iris data set.
    • We will take a look at a harder example, using Pandora songs as data. See data.

Homework:

  • Read Paul Graham's A Plan for Spam and be prepared to discuss it in class on Monday. Here are some questions to think about while you read:
    • Should a spam filter optimize for sensitivity or specificity, in Paul's opinion?
    • Before he tried the "statistical approach" to spam filtering, what was his approach?
    • How exactly does his statistical filtering system work?
    • What did Paul say were some of the benefits of the statistical approach?
    • How good was his prediction of the "spam of the future"?
  • Below are the foundational topics upon which Monday's class will depend. Please review these materials before class:
    • Confusion matrix: Kevin's guide roughly mirrors the lecture from class 10.
    • Sensitivity and specificity: Rahul Patwari has an excellent video (9 minutes).
    • Basics of probability: These introductory slides (from the OpenIntro Statistics textbook) are quite good and include integrated quizzes. Pay specific attention to these terms: probability, sample space, mutually exclusive, independent.
  • You should definitely be working on your project! Your rough draft is due in two weeks!

Resources:

Class 13: Naive Bayes

Resources:

Homework:

  • Download all of the NLTK collections.
    • In Python, use the following commands to bring up the download menu.
    • import nltk
    • nltk.download()
    • Choose "all".
    • Alternatively, just type nltk.download('all')
  • Install two new packages: textblob and lda.
    • Open a terminal or command prompt.
    • Type pip install textblob and pip install lda.

Class 14: Natural Language Processing

  • Overview of Natural Language Processing (slides)
  • Real World Examples
  • Natural Language Processing (code)
  • NLTK: tokenization, stemming, lemmatization, part of speech tagging, stopwords, Named Entity Recognition (Stanford NER Tagger), TF-IDF, LDA, document summarization
  • Alternative: TextBlob

Resources:

Class 15: Decision Trees

Homework:

  • By next Wednesday (before class), review the project drafts of your two assigned peers according to these guidelines. You should upload your feedback as a Markdown (or plain text) document to the "reviews" folder of DAT4-students. If your last name is Smith and you are reviewing Jones, you should name your file smith_reviews_jones.md.

Resources:

Installing Graphviz (optional):

  • Mac:
  • Windows:
    • Download and install MSI file
    • Add it to your Path: Go to Control Panel, System, Advanced System Settings, Environment Variables. Under system variables, edit "Path" to include the path to the "bin" folder, such as: C:\Program Files (x86)\Graphviz2.38\bin

Class 16: Ensembling

Resources:

Class 17: Databases and MapReduce

Resources:

Class 18: Recommenders

  • Recommendation Engines slides
  • Recommendation Engine Example code

Resources:

Class 19: Advanced scikit-learn

Homework:

Resources:

Class 20: Course Review

Resources:

Class 21: Project Presentations

Class 22: Project Presentations

You might also like...
Implementation of self-attention mechanisms for general purpose. Focused on computer vision modules. Ongoing repository.
Implementation of self-attention mechanisms for general purpose. Focused on computer vision modules. Ongoing repository.

Self-attention building blocks for computer vision applications in PyTorch Implementation of self attention mechanisms for computer vision in PyTorch

Scikit-learn compatible estimation of general graphical models
Scikit-learn compatible estimation of general graphical models

skggm : Gaussian graphical models using the scikit-learn API In the last decade, learning networks that encode conditional independence relationships

Implementation of Perceiver, General Perception with Iterative Attention, in Pytorch
Implementation of Perceiver, General Perception with Iterative Attention, in Pytorch

Perceiver - Pytorch Implementation of Perceiver, General Perception with Iterative Attention, in Pytorch Install $ pip install perceiver-pytorch Usage

a general-purpose Transformer based vision backbone

Swin Transformer By Ze Liu*, Yutong Lin*, Yue Cao*, Han Hu*, Yixuan Wei, Zheng Zhang, Stephen Lin and Baining Guo. This repo is the official implement

GLM (General Language Model)

GLM GLM is a General Language Model pretrained with an autoregressive blank-filling objective and can be finetuned on various natural language underst

Implementation of Perceiver, General Perception with Iterative Attention in TensorFlow
Implementation of Perceiver, General Perception with Iterative Attention in TensorFlow

Perceiver This Python package implements Perceiver: General Perception with Iterative Attention by Andrew Jaegle in TensorFlow. This model builds on t

Vector Neurons: A General Framework for SO(3)-Equivariant Networks
Vector Neurons: A General Framework for SO(3)-Equivariant Networks

Vector Neurons: A General Framework for SO(3)-Equivariant Networks Created by Congyue Deng, Or Litany, Yueqi Duan, Adrien Poulenard, Andrea Tagliasacc

BYOL for Audio: Self-Supervised Learning for General-Purpose Audio Representation
BYOL for Audio: Self-Supervised Learning for General-Purpose Audio Representation

BYOL for Audio: Self-Supervised Learning for General-Purpose Audio Representation This is a demo implementation of BYOL for Audio (BYOL-A), a self-sup

Comments
  • Question about -- In[21]: lm.predict([100, 25, 25]) -- in 08_linear_regression.ipynb

    Question about -- In[21]: lm.predict([100, 25, 25]) -- in 08_linear_regression.ipynb

    Hi!

    First of all, thanks for the great tutorial! :)

    Next, I was following the notes and when trying to run the code snippet

    In[21]: lm.predict([100, 25, 25]) 
    

    for my own problem I got the following error:

    /var/ml/python/local/lib/python2.7/site-packages/sklearn/utils/validation.py:386: DeprecationWarning: Passing 1d arrays as data is deprecated in 0.17 and willraise ValueError in 0.19. Reshape your data either using X.reshape(-1, 1) if your data has a single feature or X.reshape(1, -1) if it contains a single sample.
      DeprecationWarning)
    

    Adding additional pair of brackets solved it, meaning

    lm.predict([[100, 25, 25]])  
    

    I assume the implementation has changed for sklearn.linear_model?

    Reference: https://github.com/justmarkham/DAT4/blob/master/notebooks/08_linear_regression.ipynb

    opened by mlukjanska 3
  • small typo

    small typo

    seems like the choices are the same! http://nbviewer.ipython.org/github/justmarkham/DAT4/blob/master/notebooks/08_linear_regression.ipynb

    Confidence in our Model Question: Is linear regression a high bias/low variance model, or a low variance/high bias model?

    cap- 2015-07-05 at 22 49 52

    opened by davecampbell 1
Owner
Kevin Markham
Founder of Data School
Kevin Markham
A Peer-to-peer Platform for Secure, Privacy-preserving, Decentralized Data Science

PyGrid is a peer-to-peer network of data owners and data scientists who can collectively train AI models using PySyft. PyGrid is also the central serv

OpenMined 615 Jan 3, 2023
Bachelor's Thesis in Computer Science: Privacy-Preserving Federated Learning Applied to Decentralized Data

federated is the source code for the Bachelor's Thesis Privacy-Preserving Federated Learning Applied to Decentralized Data (Spring 2021, NTNU) Federat

Dilawar Mahmood 25 Nov 30, 2022
🛠 All-in-one web-based IDE specialized for machine learning and data science.

All-in-one web-based development environment for machine learning Getting Started • Features & Screenshots • Support • Report a Bug • FAQ • Known Issu

Machine Learning Tooling 2.9k Jan 9, 2023
Rafael Project- Classifying rockets to different types using data science algorithms.

Rocket-Classify Rafael Project- Classifying rockets to different types using data science algorithms. In this project we received data base with data

Hadassah Engel 5 Sep 18, 2021
(CVPR2021) ClassSR: A General Framework to Accelerate Super-Resolution Networks by Data Characteristic

ClassSR (CVPR2021) ClassSR: A General Framework to Accelerate Super-Resolution Networks by Data Characteristic Paper Authors: Xiangtao Kong, Hengyuan

Xiangtao Kong 308 Jan 5, 2023
An open source Python package for plasma science that is under development

PlasmaPy PlasmaPy is an open source, community-developed Python 3.7+ package for plasma science. PlasmaPy intends to be for plasma science what Astrop

PlasmaPy 444 Jan 7, 2023
Pseudo-rng-app - whos needs science to make a random number when you have pseudoscience?

Pseudo-random numbers with pseudoscience rng is so complicated! Why cant we have a horoscopic, vibe-y way of calculating a random number? Why cant rng

Andrew Blance 1 Dec 27, 2021
Aalto-cs-msc-theses - Listing of M.Sc. Theses of the Department of Computer Science at Aalto University

Aalto-CS-MSc-Theses Listing of M.Sc. Theses of the Department of Computer Scienc

Jorma Laaksonen 3 Jan 27, 2022
Udacity's CS101: Intro to Computer Science - Building a Search Engine

Udacity's CS101: Intro to Computer Science - Building a Search Engine All soluti

Phillip 0 Feb 26, 2022
A general 3D Object Detection codebase in PyTorch.

Det3D is the first 3D Object Detection toolbox which provides off the box implementations of many 3D object detection algorithms such as PointPillars, SECOND, PIXOR, etc, as well as state-of-the-art methods on major benchmarks like KITTI(ViP) and nuScenes(CBGS).

Benjin Zhu 1.4k Jan 5, 2023