105
Computer Science & Music Sean Bechhofer University of Manchester @seanbechhofer Animation 14 Awards Day, July 2014

Animation 14: Computer Science and Music

  • Upload
    seanb

  • View
    253

  • Download
    4

Embed Size (px)

DESCRIPTION

Slides from a keynote talk at the University of Manchester UK Schools Computer Animation Competition in July 2014. http://animation14.cs.manchester.ac.uk/festival/

Citation preview

Page 1: Animation 14: Computer Science and Music

Computer Science & MusicSean Bechhofer

University of Manchester !

@seanbechhofer !

Animation 14 Awards Day, July 2014

Page 2: Animation 14: Computer Science and Music

Computer Science isn't just about

Computers

Page 3: Animation 14: Computer Science and Music

Name That Tune!

Page 4: Animation 14: Computer Science and Music

Name That Tune!

Page 5: Animation 14: Computer Science and Music

Name That Tune!

Page 6: Animation 14: Computer Science and Music

Name That Tune!

Page 7: Animation 14: Computer Science and Music

Name That Tune!

Page 8: Animation 14: Computer Science and Music
Page 9: Animation 14: Computer Science and Music

Track 1

Page 10: Animation 14: Computer Science and Music
Page 11: Animation 14: Computer Science and Music

Track 2

Page 12: Animation 14: Computer Science and Music
Page 13: Animation 14: Computer Science and Music
Page 14: Animation 14: Computer Science and Music
Page 15: Animation 14: Computer Science and Music
Page 16: Animation 14: Computer Science and Music

Cool! How does it work?

Page 17: Animation 14: Computer Science and Music

How would you describe

me?

Page 18: Animation 14: Computer Science and Music

Tall

48

Page 19: Animation 14: Computer Science and Music

48

Scottish

Tall

Page 20: Animation 14: Computer Science and Music

Tall

48

Scottish

Computer Scientist

Page 21: Animation 14: Computer Science and Music

48

Scottish

Computer Scientist

Guitarist

Tall

Page 22: Animation 14: Computer Science and Music

48

Scottish

Computer Scientist

Guitarist

Tall

Manchester (City)

Page 23: Animation 14: Computer Science and Music

Tall

48

Scottish

Computer Scientist

Guitarist

Scuba DiverManchester (City)

Page 24: Animation 14: Computer Science and Music

48

Scottish

Computer Scientist

Guitarist

Tall

Manchester (City)Scuba Diver

Page 25: Animation 14: Computer Science and Music

Tall48ScottishComputer ScientistGuitarist

Scuba Diver

Features

Manchester (City)

Page 26: Animation 14: Computer Science and Music

These features allow us to identify people. We can do the same with sound or music

Page 27: Animation 14: Computer Science and Music

Feature ExtractionWe can analyse a piece of music to find out

what sounds are happening at different times

!

Low frequencies: e.g. Bass Mid frequencies: e.g. Vocals

High frequencies: e.g. Cymbals This gives us a Spectrogram

Page 28: Animation 14: Computer Science and Music
Page 29: Animation 14: Computer Science and Music
Page 30: Animation 14: Computer Science and Music
Page 31: Animation 14: Computer Science and Music

Signature

Page 32: Animation 14: Computer Science and Music
Page 33: Animation 14: Computer Science and Music

Computer Music Files

Page 34: Animation 14: Computer Science and Music

mp3?

Page 35: Animation 14: Computer Science and Music

“Motion Picture Experts Group Phase

1 Audio Layer III”

Let's stick with mp3...

Page 36: Animation 14: Computer Science and Music

Sound = Waves

Page 37: Animation 14: Computer Science and Music

Turning waves into numbers

-4, 0, 4, 7, 6, 3, 0, -1, 1, 3, 4, 3, -1, -5, -8, -7, -5, -1, 0, -2, -4, -5, -4

Page 38: Animation 14: Computer Science and Music

Numbers!

0000000 49 44 33 03 00 00 00 04 1b 55 54 4c 45 4e 00 00!

0000010 00 0f 40 00 01 ff fe 33 00 30 00 35 00 30 00 31!

0000020 00 33 00 41 50 49 43 00 01 02 9e 00 00 00 69 6d!

0000030 61 67 65 2f 6a 70 65 67 00 03 00 ff d8 ff e0 00!

0000040 10 4a 46 49 46 00 01 01 00 00 01 00 01 00 00 ff!

0000050 db 00 43 00 05 03 04 04 04 03 05 04 04 04 05 05!

0000060 05 06 07 0c 08 07 07 07 07 0f 0b 0b 09 0c 11 0f!

0000070 12 12 11 0f 11 11 13 16 1c 17 13 14 1a 15 11 11!

0000080 18 21 18 1a 1d 1d 1f 1f 1f 13 17 22 24 22 1e 24!

0000090 1c 1e 1f 1e ff db 00 43 01 05 05 05 07 06 07 0e!

00000a0 08 08 0e 1e 14 11 14 1e 1e 1e 1e 1e 1e 1e 1e 1e!

Page 39: Animation 14: Computer Science and Music

Lots of Numbers!

Over 44,000 samples per second for high quality audio

That's 31.5 MB for a 3-minute song Only 250 songs on an 8Gb music

player.

Page 40: Animation 14: Computer Science and Music
Page 41: Animation 14: Computer Science and Music

Lots of Numbers!

Over 44,000 samples per second for high quality audio

That's 31.5 MB for a 3-minute song Only 250 songs on an 8Gb music

player.

Page 42: Animation 14: Computer Science and Music

Throw some numbers away!

Page 43: Animation 14: Computer Science and Music

High Quality

Page 44: Animation 14: Computer Science and Music

Low Quality

Page 45: Animation 14: Computer Science and Music

What's in the picture?

Page 46: Animation 14: Computer Science and Music
Page 47: Animation 14: Computer Science and Music
Page 48: Animation 14: Computer Science and Music
Page 49: Animation 14: Computer Science and Music
Page 50: Animation 14: Computer Science and Music
Page 51: Animation 14: Computer Science and Music
Page 52: Animation 14: Computer Science and Music
Page 53: Animation 14: Computer Science and Music

Another volunteer!

Page 54: Animation 14: Computer Science and Music

Lossy Encoding

My nm s Sn nd m Cmptr Scntst t th nvrsty f Mnchstr. !

lk t ply th gtr. lk t g scb dvng nd shrks r my fvrt nmls.

111 letters

Page 55: Animation 14: Computer Science and Music

Lossy Encoding

My name is Sean and I'm a Computer Scientist at the University of Manchester. !

I like to play the guitar. I like to go scuba diving and sharks are my favourite animals.

170 letters

Page 56: Animation 14: Computer Science and Music

Lossy Encoding

Original = 170 letters, New = 111 letters !

65% smaller! !

Imagine if we had to pay £1 per letter! !So this is “cheaper”, but we might need

some extra effort to read it

Page 57: Animation 14: Computer Science and Music

Lossy Encoding

ae i ea a I a oue iei a e Uiei o aee. I ie o a e uia. I ie o o ua ii a a ae aouie aia.

53 letters

Page 58: Animation 14: Computer Science and Music

Lossy Encoding

My name is Sean and I'm a Computer Scientist at the University of Manchester. !

I like to play the guitar. I like to go scuba diving and sharks are my favourite animals.

170 letters

Page 59: Animation 14: Computer Science and Music

Good

FastCheap

Trade Offs: Pick Any Two!

Page 60: Animation 14: Computer Science and Music

Everyday Encoding

r u gng to the gig?

I <3 daft punk!

not if i c u first :-)

yeah shld be gr8

me 2! c u l8r

lol ;-)

Page 61: Animation 14: Computer Science and Music

How high can you hear?

Page 62: Animation 14: Computer Science and Music

How high?

1.Everybody stand up! 2.You will hear a tone play. 3.When you can no longer hear the tone, sit down!

This is an experiment, not a competition — no cheating!

Page 63: Animation 14: Computer Science and Music

Spot the Difference!

Page 64: Animation 14: Computer Science and Music

Perceptual Encoding

Page 65: Animation 14: Computer Science and Music

Fewer Numbers

0000000 49 44 33 03 00 00 00 04 1b 55 54 4c 45 4e 00 00!

0000010 00 0f 40 00 01 ff fe 33 00 30 00 35 00 30 00 31!

0000020 00 33 00 41 50 49 43 00 01 02 9e 00 00 00 69 6d!

0000030 61 67 65 2f 6a 70 65 67 00 03 00 ff d8 ff e0 00!

0000040 10 4a 46 49 46 00 01 01 00 00 01 00 01 00 00 ff!

0000050 db 00 43 00 05 03 04 04 04 03 05 04 04 04 05 05!

0000060 05 06 07 0c 08 07 07 07 07 0f 0b 0b 09 0c 11 0f!

0000070 12 12 11 0f 11 11 13 16 1c 17 13 14 1a 15 11 11!

0000080 18 21 18 1a 1d 1d 1f 1f 1f 13 17 22 24 22 1e 24!

0000090 1c 1e 1f 1e ff db 00 43 01 05 05 05 07 06 07 0e!

00000a0 08 08 0e 1e 14 11 14 1e 1e 1e 1e 1e 1e 1e 1e 1e!

Page 66: Animation 14: Computer Science and Music

High Quality

Page 67: Animation 14: Computer Science and Music

mp3

Page 68: Animation 14: Computer Science and Music
Page 69: Animation 14: Computer Science and Music
Page 70: Animation 14: Computer Science and Music

“It's hard to make predictions, particularly about the future.”

Niels Bohr (1885-1962)

Page 71: Animation 14: Computer Science and Music

Mark Zuckerberg

Page 72: Animation 14: Computer Science and Music

2004

2005

2006

2007

2008

2009

2010

2011

2012

2013

0 350 700 1050 1400

1230

1056

845

608

360

145

58

12

6

1

Million Monthly users

Page 73: Animation 14: Computer Science and Music
Page 74: Animation 14: Computer Science and Music
Page 75: Animation 14: Computer Science and Music
Page 76: Animation 14: Computer Science and Music
Page 77: Animation 14: Computer Science and Music
Page 78: Animation 14: Computer Science and Music
Page 79: Animation 14: Computer Science and Music
Page 80: Animation 14: Computer Science and Music
Page 81: Animation 14: Computer Science and Music

If you liked that, you'll

like this!

Page 82: Animation 14: Computer Science and Music

Listens

Page 83: Animation 14: Computer Science and Music
Page 84: Animation 14: Computer Science and Music
Page 85: Animation 14: Computer Science and Music
Page 86: Animation 14: Computer Science and Music
Page 87: Animation 14: Computer Science and Music

Popularity

One Direction

Metallica

Daft Punk

Page 88: Animation 14: Computer Science and Music

Popularity

One Direction

Metallica

Daft Punk 3.4 million listeners

2.5 million listeners

0.7 million listeners

Page 89: Animation 14: Computer Science and Music

Popularity

One Direction

Metallica

Daft Punk

233 million listens 2.5 million listeners173 million listens 3.4 million listeners36 million listens 0.7 million listeners

?

Page 90: Animation 14: Computer Science and Music

This works for lots of stuff!

Page 91: Animation 14: Computer Science and Music
Page 92: Animation 14: Computer Science and Music
Page 93: Animation 14: Computer Science and Music
Page 94: Animation 14: Computer Science and Music
Page 95: Animation 14: Computer Science and Music
Page 96: Animation 14: Computer Science and Music

Inside &

Outside

Page 97: Animation 14: Computer Science and Music

Mona Lisa Leonardo da Vinci

1503-1505 Louvre Museum

Page 98: Animation 14: Computer Science and Music

Who's like me?

Page 99: Animation 14: Computer Science and Music

Friends?

Page 100: Animation 14: Computer Science and Music

Patterns

Page 101: Animation 14: Computer Science and Music

Patterns

Page 102: Animation 14: Computer Science and Music

Patterns

Page 103: Animation 14: Computer Science and Music

Computer Science isn't just about Computers

We can't predict what the impact of new technologies will be

Sharks are great!

Eat lots of broccoli!

Things to Remember

Page 104: Animation 14: Computer Science and Music

Thank you!

The best way to predict the future is to invent it

— Alan Kay

Page 105: Animation 14: Computer Science and Music

Image Credits• Daft Punk: https://www.flickr.com/photos/caesarsebastian/1031975612/ • Red Army: https://www.flickr.com/photos/patsemchism/345981835 • Constellation: http://commons.wikimedia.org/wiki/File:Ursa_major_constellation_map.png • Great Wave: Public domain, Katsushika Hokusai (葛飾北斎)

• Etihad: http://en.wikipedia.org/wiki/File:City_Of_Manc_Stadium.jpg • Hammerhead Shark: https://www.flickr.com/photos/barrypeters/4242623174/ • Oceanic White Tip: https://www.flickr.com/photos/michaelaston/2062803551 • Ear: https://www.flickr.com/photos/tbisaacs/3911558890/ • Fraunhofer: http://www.mp3-history.com/ • Niels Bohr: http://www.clipartsfree.net/clipart/89-niels-bohr-clipart.html • Mark Zuckerberg: http://www.fotopedia.com/items/flickr-2326586665 • Cassette Tapes: https://www.flickr.com/photos/cass_ette/4571540478 • One Direction: http://en.wikipedia.org/wiki/File:One_Direction_at_the_Logies_Awards_2012.jpg • Metallica: http://en.wikipedia.org/wiki/File:Metallica_London_2008-09-15_Kirk_and_James.jpg • CD Rack: http://en.wikipedia.org/wiki/File:CD_rack.JPG • Books: https://www.flickr.com/photos/meeli/2854849909 • Beans: http://en.wikipedia.org/wiki/File:No_name_sans_nom_beans_feves.jpg • Video Games: http://commons.wikimedia.org/wiki/File:Videogameretaildisplay.jpg • Broccoli: http://commons.wikimedia.org/wiki/File:Basket_of_broccoli_in_Singapore_market.jpg • Mona Lisa: Public Domain • Other Images: Sean Bechhofer