CS63 Artificial Intelligence
Fall 2020


Announcements

This page is still under construction; some links are likely broken, and the schedule is likely to evolve. Class will start on Monday, September 7th with a live Zoom session (link will be sent via e-mail prior to first class). Recordings of classes will be posted when sensible (e.g. small group discussion does not produce useful videos). Course communications will be via Slack (you'll get an invite via e-mail before the first class).

Course Information

Schedule
  note: all times listed as EST
Class: Mon., Wed., Fri. 12:15 - 1:05PM
Lab: Friday 3:00 - 4:30PM

Contact Information
Professor: Ben Mitchell
Email: mitchell at cs dot swarthmore.edu
Office: Science Center 252 (but in practice, Zoom)
Office Hours: Tuesday 1:30-3:30pm
Wednesday 2:00-3:30pm
Friday 10:00-11:30am
And by appointment

Introduction

Artificial Intelligence (AI) is the branch of computer science that is concerned with the automation of 'intelligent' behavior. Intelligent behavior encompasses a wide range of abilities. As a result, AI has become a very broad field that includes search, game playing, reasoning, planning, computer vision, natural language processing, modeling human performance (cognitive science), machine learning, and robotics. This course will focus on a subset of these topics, specifically search and machine learning, while also drawing connections to cognitive science.

In search, we will see familiar techniques such as depth-first and breadth-first, as well as new techniques such as A*, minimax, and simulated annealing applied to AI problems. In machine learning, which is concerned with how to create programs that automatically learn from experience, we will explore reinforcement learning and neural networks, including 'deep learning'. The first half of the semester will focus on search, and the second half of the semester will focus on machine learning.

Goals for the course

Notes on Remote Learning

As you know, this course is being taught remotely due to the COVID-19 pandemic; this is going to mean things will work a bit differently than they would under ordinary circumstances. First and foremost, we all need to acknowledge the difficulties this will present, and that those difficulties will not be distributed equally. Second, however, we must all make a commitment to do our personal best to help ourselves and our peers to learn as much as we can in spite of these difficulties.

While there will be a number of 'practical' implications in terms of online interactions and tool use, the most important thing to be aware of going in is that we're all still learning about how to make remote classes work best. This means we need to pay deliberate attention to what we're doing and what impact it's having, so that through experimentation and feedback we can figure out what works best for all of us.

This also means that while there is a plan going in, I fully expect that we'll wind up changing the plan as we go. Even more than in a 'normal' semester, the information on this page is subject to change. Once again, it is the responsibility of all of us to help direct that change for the better, so please don't hesitate to let me know how things are going for you as we progress through the semester. We must, as my acting teacher once said, "prepare to improvise."

It's also important to note that, even more than usual, you are going to be responsible for your own learning. My job as an instructor is to help you learn, but it's up to you to actually do the learning. The things I will ask you to do this semester are all designed toward helping you learn, but I can't directly assess how much you've learned, so I'm left with indirect measurements (e.g. your performance on assignments and exams, etc.). Even more than in a normal semester, it's up to you to do things in a way that maximizes your learning, and that means not taking 'shortcuts' that circumvent the learning process. You can think of this as a sort of functional definition for cheating: anything that helps you learn is good, anything that helps you avoid having to learn is bad.


Grading

Grade weighting
10%Participation
15%Reading Journal
50%Labs
25%Final Project

Reading

Rather than using a single textbook, we will be using materials, mostly drawn from two books:

Since physical course reserves are not an option this semester, the library will be scanning the chapters we'll need, and I'll make them available to students. However, I will ask that you do not share them with others not enrolled in the class. Physical copies are available through the usual sources if you want one.

Our class meetings will be conducted on Zoom, and will be a mix of lecture and discussion. To be ready to participate in the discussion will require some preparation on your part. Most of this will consist of careful reading and reflection on the assigned reading through the use of a reading journal.

I recognize that attendance may be difficult for some students, so I will try to record and post lectures when sensible (i.e. if we're doing small-group discussions, there's not much point).

Preparation

You should check the class schedule and read any material that has been assigned before coming to class. You will get the most out of the reading if you approach it as follows:

Many of the readings are fairly short, but can contain mathematics or algorithms that require a moderate amount of study. Make your best effort to understand the material and bring any questions you have to class. Then we can have a productive discussion with examples and exercises to clarify the material. If you still have questions or confusion after class, I am always happy to discuss and clarify matters further during office hours.

Journal

To help focus your efforts and give us a basis for discussion, you will be provided with a short list of questions to answer for each week's reading. Reflecting on your responses to the questions will help give you a deeper understanding of the most important concepts surrounding each topic.

Your responses are due by 11:59pm the night before class where they will be discussed. No late responses for reading journals will be accepted.

In our first lab you will clone a reading journal repo containing several text files: one for the search readings, another for the machine learning readings, and a final one for the more philosophical issues we'll be reading about at the end of the semester. You will write your responses in the appropriate file and submit them via git (using add, commit, and push) before each class meeting when reading is assigned.

While these low-stakes writing assignments are technically informal, they must reflect a certain level of engagement and evidence of thinking seriously about the material. Responses will be graded using the following scale:

My grades and comments will be pushed to your grading repo each week. I expect that most entries will receive a CHECK, thus I will primarily comment on your journal to report a PLUS or a MINUS. You should expect to discuss the issues raised in your reading journal entries during class.

Copyright 2018 Jerod Weinman, 2019 Lisa Meeden, 2020 Ben Mitchell


Policies

Participation

In spite of the remote nature of the class, active participation and engagement remain critical to learning. There are several ways to demonstrate your participation, including attending class with your camera on, showing up for class prepared (e.g. having done the reading and given thought to questions you might want to ask) engaging in in-class discussions (please note that active and attentive listening is just as important as talking), working well with your lab partner, engaging in discussions outside of class time (e.g. via slack), and responding to the regular feedback surveys. I recognize that not all students are equally comfortable with all types of participation, and that students may also have difficulties related to remote learning that could restrict their ability to participate in certain ways (e.g. timezones, bandwidth, etc.). I do not expect all students to demonstrate all forms of participation equally, but I do expect all students to engage with the class and demonstrate at least some of these forms of participation on a regular basis.

Labs

Labs will be assigned on Friday, during the scheduled lab time, and will be due by the following Thursday before midnight. Even if you do not fully complete a lab, you should submit what you have done to receive partial credit.

For this semester, there will be a 24 hour 'grace period' after the due date to account for potential issues related to remote access and the pandemic. This means that you should still make every effort to get your lab turned in on time, but you won't be penalized if it's a little late. You don't need to use a 'late day' (see below) if your assignment is turned in during the grace period (but note that I reserve the right to re-think this policy if it's being abused).

You should work with a partner on all labs after lab 0. We will be using Teammaker [NOTE: not yet set up] to facilitate the creation of partnerships. If you and another student would like to partner together, simply select one another via Teammaker. If you would like to be assigned a random partner, you can select this option through Teammaker as well. For each lab assignment you must re-select partners. Thus you can try out a partnership one week, and then decide to try a different partnership the following week. However, there is no upper bound to how many times a given pair can work together, and there may be some added benefit to consistency in these uncertain times. Students are encouraged to consider scheduling (and timezones) when selecting partners, as you are expected to work together on all aspects of an assignment (i.e. the standard 'pair coding' model, not the 'you do A and I do B' model). Slack is a great place to discuss scheduling constraints and find partnerships that will work well for you.

You have five late days that you may use on any lab, for any reason. If you are using a late day, you must contact me by PM on Slack when you submit your lab.

Your late days will be counted at the granularity of full days and will be tracked on a per-student (NOT per-partnership) basis. That is, if you turn in an assignment five minutes after the deadline (including grace period), it counts as using one day. For partnered labs, using a late day counts towards the late days for each partner. In the rare cases in which only one partner has unused late days, that partner's late days may be used, barring a consistent pattern of abuse.

If you feel that you need an extension on an assignment or that you are unable to keep up with class for a week or more due to a medical condition (e.g., extended illness, concussion, hospitalization), remote location issue, or other emergency, you must contact the dean's office and your instructors. Faculty will coordinate with the deans to determine and provide the appropriate accommodations. Note that for illnesses, the College's medical excuse policy, states that you must be seen and diagnosed by the Worth Health Center if you would like them to contact your class dean with corroborating medical information. Obviously that's not going to work for students who are not on campus to begin with, but you should still contact the dean's office.

Note that lectures will be recorded, so you should be able to make up missed class time a bit more easily than usual; however, you won't be able to ask questions or participate in discussions when using a recording, so you may want to bring your questions to office hours. All students are still encouraged to attend class synchronously, but I understand that this may not always be possible for everyone this semester.

Academic Integrity

Academic honesty is required in all of your work. Under no circumstances may you hand in work done with (or by) someone else under your own name. Your code should never be shared with anyone; you may not examine or use code belonging to someone else, nor may you let anyone else look at or make a copy of your code. The only exception to this policy, is that you may freely share code with your lab partner.

You should not obtain solutions from students who previously took the course or copy code that can be found online. You may not share solutions after the due date of the assignment.

Failure to abide by these rules constitutes academic dishonesty and will lead to a hearing of the College Judiciary Committee. According to the Faculty Handbook: "Because plagiarism is considered to be so serious a transgression, it is the opinion of the faculty that for the first offense, failure in the course and, as appropriate, suspension for a semester or deprivation of the degree in that year is suitable; for a second offense, the penalty should normally be expulsion."

Discussing ideas and approaches to problems with others on a general level is fine (in fact, we encourage you to discuss general strategies with each other), but you should never read any other student's code or let another student read your code. All code you submit must be your own with the following permissible exceptions: code distributed in class and code given in the readings. In these cases, you should always include comments that indicate on which parts of the assignment you received help, and what your sources were.

Academic Accommodations

If you believe that you need accommodations for a disability, please contact the Office of Student Disability Services (Parrish 113W) or email studentdisabilityservices@swarthmore.edu to arrange an appointment to discuss your needs. As appropriate, the Office will issue students with documented disabilities a formal Accommodations Letter. Since accommodations require early planning and are not retroactive, please contact the Office of Student Disability Services as soon as possible. For details about the accommodations process, visit the Student Disability Service Website. You are also welcome to contact me privately to discuss your academic needs. However, all disability-related accommodations must be arranged through the Office of Student Disability Services.



Schedule

WEEK DAY ANNOUNCEMENTS TOPIC & READING LABS     
1

Sep 07

Introduction

Introduction to AI

  • M: (optional) What is AI? [R&N 1.1]
  • W: Roots of Artificial Intelligence [Mitchell Ch. 1]
  • F: AI Environments [R&N 2.3]
  • Journal questions

Lab 0: Python Tutorial and Maze Search

Sep 09

History of AI, Symbolic vs Subsymbolic

Sep 11

Roles of AI in society

2

Sep 14

State Space Search

Problem solving with search

  • M: Problem solving [R&N 3.1-3.3]
  • W: Uninformed search [R&N 3.4]
  • F: Informed search [R&N 3.5-3.6]
  • Journal questions

Lab 1: Informed Search for Puzzles

Sep 16

Uninformed Search

Sep 18

A* and heuristics

3

Sep 21

Local Search and Hill Climbing

Local search

Lab 2: Local Search for Touring Problems

Sep 23

Simuated Annealing and Stochastic Beam Search

Sep 25

Evolutionary Computation, GAs

4

Sep 28

Game playing

Game tree search

Lab 3: Minimax on Board Games

Sep 30

Minimax

Oct 02

Alpha-Beta pruning

5

Oct 05

Go and MCTS

Monte Carlo Search

Lab 4: MCTS General Game Solver

Oct 07

MCTS, continued

Oct 09

Classical AI vs Machine Learning

6

Oct 12

Percpetrons

Perceptrons and Neural Networks

  • M: Review pgs 22-32 on Perceptrons [Mitchell Ch. 1]
  • W: Neural Networks and the Rise of Machine Learning [Mitchell Ch. 2]
  • F: Videos on neural networks and backpropagation
  • Journal questions

Lab 5: ANNs with Backpropagation

Oct 14

Multilayer Networks

Oct 16

Deriving Backpropagation

7

Oct 19

Deep Learning

Deep Learning

Lab 6: Convolutional Nets

Oct 21

Convolutional Neural Networks

Oct 23

Recurrent Neural Networks

8

Oct 26

Reinforcement learning

Reinforcement Learning

  • M: Rewards for Robots [Mitchell Ch. 8], re-skim [Mitchell Ch. 9]
  • W: Beyond Games [Mitchell Ch. 10]
  • Journal questions

Lab 7: Cart Pole Balance

Oct 28

Q-learning, Function Approximation

Oct 30

Deep Q-learning

9

Nov 02

Evolutionary Computation, revisited

GAs and World Models

  • M: Genetic Algorithms Revisited [Mitchell_GA_ch1.pdf]
  • W: GAs for Neural Networks [Mitchell_GA_sec2.3.pdf]
  • F: World Models [look at Ha & Schmidhuber, but don't worry if you can't follow all the details]
  • Journal questions

Lab 8: Genetic Algorithms

Nov 04

Evolving Neural Networks

Nov 06

World Models: putting things together

10

Nov 09

Evaluating ML

Evaluating Machine Learning

  • M: Developing ML Systems [R&N Section 19.9 (p.704-713)]
  • W: Read the lecture notes (the books don't do a good enough job)
  • F: Machines that Learn [Mitchell Ch. 6]
  • Journal questions

Final Project

Nov 11

Experimental Design

Nov 13

Statistical Validation

11

Nov 16

Bias in AI and ML

Bias and Ethics in AI

  • M: AI Myth and Reality (PDF in Google Drive)
  • W: Ethical Theories (Quinn Ch. 2, or "cliffnotes", PDFs in Google Drive)
  • F: On Trustworthy and Ethical AI [Mitchell Ch. 7]
  • Journal questions

Final Project Checkpoint (writeup and 2-3 minute presentation during lab)

Nov 18

Ethical use of AI

Nov 20

Philosophy of AI

 

Nov 23

Thanksgiving Break

Nov 25

Nov 27

12

Nov 30

Real world applications

AI now and in the future

  • M: AI Spring [Mitchell Ch. 3]
  • W: Questions, Answers, and Speculations [Mitchell Ch. 16]
  • Journal questions

Final Project - reports and presentation on December 11th, 9am-noon

Dec 02

Future of AI

Dec 04

Summing up