You are on page 1of 36

Welcome to

CS 470/670 –
Introduction to
Artificial Intelligence

Spring 2016
Instructor: Marc Pomplun

January 26, 2016 Introduction to Artificial Intelligence 1


Lecture 1: What is Artificial Intelligence?
Instructor – Marc Pomplun
Office: S-3-171
Lab: S-3-135

Office Hours: Tuesdays 4:00pm – 5:30pm


Thursdays 7:00pm – 8:30pm

Phone: 287-6443 (office)


287-6485 (lab)
E-Mail: marc@cs.umb.edu

January 26, 2016 Introduction to Artificial Intelligence 2


Lecture 1: What is Artificial Intelligence?
The Visual Attention Lab

Eye movement research


January 26, 2016 Introduction to Artificial Intelligence 3
Lecture 1: What is Artificial Intelligence?
The EyeLink-2K System

January 26, 2016 Introduction to Artificial Intelligence 4


Lecture 1: What is Artificial Intelligence?
Example: Distribution of Visual Attention

January 26, 2016 Introduction to Artificial Intelligence 5


Lecture 1: What is Artificial Intelligence?
Selectivity in Complex Scenes

January 26, 2016 Introduction to Artificial Intelligence 6


Lecture 1: What is Artificial Intelligence?
Selectivity in Complex Scenes

January 26, 2016 Introduction to Artificial Intelligence 7


Lecture 1: What is Artificial Intelligence?
Selectivity in Complex Scenes

January 26, 2016 Introduction to Artificial Intelligence 8


Lecture 1: What is Artificial Intelligence?
Selectivity in Complex Scenes

January 26, 2016 Introduction to Artificial Intelligence 9


Lecture 1: What is Artificial Intelligence?
Selectivity in Complex Scenes

January 26, 2016 Introduction to Artificial Intelligence 10


Lecture 1: What is Artificial Intelligence?
Selectivity in Complex Scenes

January 26, 2016 Introduction to Artificial Intelligence 11


Lecture 1: What is Artificial Intelligence?
Modeling of Brain Functions

January 26, 2016 Introduction to Artificial Intelligence 12


Lecture 1: What is Artificial Intelligence?
Modeling of Brain Functions
layer l +1 unit and connection
in the interpretive network
unit and connection
in the gating network

unit and connection


in the top-down bias network
layer l

layer l -1

January 26, 2016 Introduction to Artificial Intelligence 13


Lecture 1: What is Artificial Intelligence?
Computer Vision:

January 26, 2016 Introduction to Artificial Intelligence 14


Lecture 1: What is Artificial Intelligence?
Human-Computer Interfaces:

January 26, 2016 Introduction to Artificial Intelligence 15


Lecture 1: What is Artificial Intelligence?
Now back to CS 470/670:
Course Kit:
Nils J. Nilsson, Artificial Intelligence: A New
Synthesis, Morgan Kaufmann 1998, ISBN 1-55860-
467-7.

On the Web:
http://www.cs.umb.edu/~marc/cs470/
(contains all kinds of course information and also my
slides in PPTX and PDF formats, updated after each
session)

January 26, 2016 Introduction to Artificial Intelligence 16


Lecture 1: What is Artificial Intelligence?
Your Evaluation

• 6 sets of exercises
software projects: 25%
non-programming questions: 10%

• midterm (75 minutes) 25%

• final exam (2.5 hours) 40%

January 26, 2016 Introduction to Artificial Intelligence 17


Lecture 1: What is Artificial Intelligence?
Grading
For the assignments, exams and your course grade,
the following scheme will be used to convert
percentages into letter grades:

 95%: A  86%: B+  74%: C+  62%: D+


 90%: A-  82%: B  70%: C  56%: D
 78%: B-  66%: C-  50%: D-

 50%: F

January 26, 2016 Introduction to Artificial Intelligence 18


Lecture 1: What is Artificial Intelligence?
Artificial Intelligence (AI)

January 26, 2016 Introduction to Artificial Intelligence 19


Lecture 1: What is Artificial Intelligence?
AI – The History
• AI is as old as computing, whose theory started in the
1930 with Alan Turing, Alonzo Church, and others
• 1941 Konrad Zuse, Germany, general purpose
computer
• 1943 Britain (Turing and others) Colossus, for
decoding
• 1945 ENIAC, US. John von Neumann a consultant
• 1956 Dartmouth Conference organized by John
McCarthy (inventor of LISP)
• The term Artificial Intelligence was coined at
Dartmouth, which was intended as a two month study.
January 26, 2016 Introduction to Artificial Intelligence 20
Lecture 1: What is Artificial Intelligence?
AI – The Achievements
• Computers land 200 ton jumbo jets unaided every
few minutes.
• Search systems like Google are not perfect but
provide very effective information retrieval.
• Robots cut slots for hip joints better than surgeons.
• The chess program Deep Blue beat world
champion Kasparov in 1997.
• Medical expert systems can outperform doctors in
many areas of diagnosis
• Self-driving cars are beginning to enter the market.
• IBM’s Watson beats humans at Jeopardy.
• Programs such as Siri communicate via natural
language.
January 26, 2016 Introduction to Artificial Intelligence 21
Lecture 1: What is Artificial Intelligence?
Artificial vs. Human Intelligence
Today’s computers can do many well-defined tasks
(for example, arithmetic operations), much faster and
more accurate than human beings.
However, the computers’ interaction with their
environment is not very sophisticated yet.
How can we test whether a computer has reached
the general intelligence level of a human being?
Turing Test: Can a computer convince a human
interrogator that it is a human?
But before thinking of such advanced kinds of
machines, we will start developing our own extremely
simple “intelligent” machines.
January 26, 2016 Introduction to Artificial Intelligence 22
Lecture 1: What is Artificial Intelligence?
Why AI?
One of major divisions in AI (and you can see it in the
definitions on the previous slide) is between
• Those who think AI is the only serious way of finding
out how we work (since opening heads does not yet
give much insight into this) and
• Those who want computers to do very smart
things, independently of how we work.

This is the important distinction between


Cognitive Scientists vs. Engineers.

January 26, 2016 Introduction to Artificial Intelligence 23


Lecture 1: What is Artificial Intelligence?
Symbolism vs. Connectionism
There is another major division in the field of Artificial
Intelligence:

• Symbolic AI represents information through


symbols and their relationships. Specific Algorithms
are used to process these symbols to solve
problems or deduce new knowledge.
• Connectionist AI represents information in a
distributed, less explicit form within a network.
Biological processes underlying learning, task
performance, and problem solving are imitated.
January 26, 2016 Introduction to Artificial Intelligence 24
Lecture 1: What is Artificial Intelligence?
Paradigms of Computation
You all know the Turing machine, conceived by Alan
Turing as a theoretical Model of automatic computation.
It uses a tape head that reads and writes symbols on
an infinite tape.
Based on the currently read symbol and the machine’s
current state, the head moves to the left or right or
writes a new symbol, and the state is updated.
These state transition rules constitute the program.
It is believed (but has not been proven) that this
machine can compute all functions that can be
computed in principle.
January 26, 2016 Introduction to Artificial Intelligence 25
Lecture 1: What is Artificial Intelligence?
Turing Machines
Turing machines inspired the construction of the first
computers, which were based on the von-Neumann
architecture.
Here, digital memory stores the program and data,
including the machine state.
A Central Processing Unit (CPU) sequentially
executes individual instructions in the program through
memory read and write operations.
This fundamental architecture is still shared by most of
today’s computers.

January 26, 2016 Introduction to Artificial Intelligence 26


Lecture 1: What is Artificial Intelligence?
Imperative Programming
This architecture is also reflected in most modern
programming languages such as Java, C, C++, C#,
Python, or Matlab.
Their programs consist of sequences of instructions,
each of which changes the system’s state, such as the
values of variables or other memory content.
Such languages are called imperative languages.
Object-oriented programming provides mechanisms
for encapsulation of functional program and data units
but is still based on the imperative paradigm.

January 26, 2016 Introduction to Artificial Intelligence 27


Lecture 1: What is Artificial Intelligence?
Lambda () Calculus
Roughly at the same time when Turing developed his
Turing machine, Alonzo Church devised a different
paradigm of computation, called lambda calculus.
It is based on anonymous functions described by
lambda expressions.
By mechanisms such as composition and recursion,
lambda expressions can represent complex
computations.
It can be shown that Turing machines and lambda
calculus have identical computational power, which is
believed to be universal (Church-Turing thesis, 1937).
January 26, 2016 Introduction to Artificial Intelligence 28
Lecture 1: What is Artificial Intelligence?
Lambda () Calculus
Lambda calculus provides a more abstract,
mathematical description of an algorithm.
Such descriptions are typically more concise and
elegant than those provided by Turing machines.
On the other hand, Turing-machine style computation
can be directly translated into hardware, which is much
more difficult for lambda calculus.
Nevertheless, there are programming languages that
are based on lambda calculus, and they are referred to
as functional languages.

January 26, 2016 Introduction to Artificial Intelligence 29


Lecture 1: What is Artificial Intelligence?
Functional Programming
The most striking feature of purely functional
programming is that there is no state.
This means that our variables are not variable, i.e.,
cannot change their values!
In other words, they are immutable and only represent
some constant value.
The execution of a program only involves the
evaluation of functions.
This sounds weird – what are the advantages and
disadvantages of functional programming?

January 26, 2016 Introduction to Artificial Intelligence 30


Lecture 1: What is Artificial Intelligence?
Functional Programming
The advantage of having no state is that functions have
no side effects.
Therefore, we can be sure that whenever we evaluate a
function with the same inputs, we will get the same
output, and nothing in our system changed due to this
evaluation.
This prevents most of the bugs that commonly occur in
imperative programming.
You will learn about other advantages during the next
few lectures…

January 26, 2016 Introduction to Artificial Intelligence 31


Lecture 1: What is Artificial Intelligence?
Functional Programming
The main problem with strictly preventing side effects is
that user input and output during program execution
become impossible.
To enable such user interaction, we have to sometimes
allow state changes. It is then important to separate
such “impure” code from the rest of the program.
There are many functional languages, with some being
as old as the earliest imperative ones.
Examples are: LISP, Scheme, Haskell, Erlang, R,
Clojure, Scala, OCaml, and F#.

January 26, 2016 Introduction to Artificial Intelligence 32


Lecture 1: What is Artificial Intelligence?
Functional Programming
Functional programming is not the best solution to
every problem, just like object-oriented programming is
not, either.
In the context of symbolic AI, you will see how
functional programming allows you to write very
concise, readable, and reusable code.
Even if you rarely or never use it again afterwards, it
will give you a different perspective on programming
and may change the way you program.

January 26, 2016 Introduction to Artificial Intelligence 33


Lecture 1: What is Artificial Intelligence?
Haskell and Frege
In this course, we will use Haskell, because its purity
forces you to use functional programming principles.
Specifically, we will use its dialect Frege, which
generates code for the Java Virtual Machine.
This way your programs can interact with Java
programs, especially the Isola game interface for our
tournament.

January 26, 2016 Introduction to Artificial Intelligence 34


Lecture 1: What is Artificial Intelligence?
Frege Resources
Free Haskell tutorials:
http://learnyouahaskell.com/
http://book.realworldhaskell.org/
Differences between Haskell and Frege:
https://github.com/Frege/frege/wiki/Differences-
between-Frege-and-Haskell

I recommend that you read Chapters 1 and 2 of “Learn


you a Haskell” and experiment with the language a bit.

January 26, 2016 Introduction to Artificial Intelligence 35


Lecture 1: What is Artificial Intelligence?
Frege Resources
You can play around with Frege online:
http://try.frege-lang.org/
Get the Frege compiler here:
https://github.com/Frege/frege
Here is a Frege plugin for Eclipse:
https://github.com/Frege/eclipse-plugin
You should definitely look at the plugin tutorial:
https://github.com/Frege/eclipse-plugin/wiki/fregIDE-
Tutorial
January 26, 2016 Introduction to Artificial Intelligence 36
Lecture 1: What is Artificial Intelligence?

You might also like