Hi! I'm a computer engineer and programming instructor myself and I'd like to say that this series is fantastic and original! I haven't seen other sources cover this type of content but it's very relevant and refreshing! I actually learned something myself with the lossy and dictionary compression mentioned in this episode which I didn't expect. Keep up the great work!
This video contains an explanation of Huffman coding that was more concise AND more understandable than the explanation given in my university Communication Systems course. I'd pay ACTUALLY DISGUSTING amounts of money for a Crash Course Electrical Engineering.
I knew about Huffman coding from my University Communication Systems course, but I agree, this was way more concise. It's not called Crash Course for nothing. :P
"But >20 KHz sounds affects the overall sounds through harmonic effects" says a lot of audiophiles who reject emperical measurement of the overpriced equipment they buy/sell/brag about to other audiophiles they've convinced to reject emperical measurement. Not to say >20 KHz harmonics don't affect the overall sound in the perceptible range. Just that a lot of people who make that claim would ignore any measurements that back that up because they'd also refute any claims made about special cables, grounding boxes, or magnetized beads they payed out the nose to include in an overpriced and underperforming sound room.
Every episode has an underlaid tone that no one with cheap speakers can hear. (No such tone is there, but you'll just bet they'll all claim they can hear it.)
There are snobby a-holes in everything subject. Like food enthusiasts who will bash everything that isn't caviar-encrusted lobster (or whatever), while the rest of us are just like "I don't care, just gimme a cheeseburger".
Excellent video, but you forgot to mention that often the more complex compression algorythms are, the more charge for the CPU there will be for decoding: for eg, h.265 video codec for Ultra HD is 4x more efficient in file size, but requires at least x4 processor power to decode and x4 time to encode than h.264. Time to encode and CPU performance to decode is important too subject in compression :P
Would have been good to get a mention on Shannon entropy and limits of information compression. There are universal truths to be found when probing these limits, where information crosses into the realms of probability and uncertainty. Its interesting stuff.
It's also a 12-minute video. In fact, I'm usually one for going "but what about..." on these videos but I thought this presented a really good selection of fundamentals and current applications.
i am a computer engineer myself I guarantee this is A-class material which is hard to come by young people should make maximum use of this information And cheers to crash course computer science jai hind
It's actually funny, because going on subreddits like "/r/headphones" they don't bash lossy compressions at all. Sure they archive in flac, but they don't mind listening to songs on Spotify that uses lossy compression because they admit most of us can't hear the difference anyway.
The reason your voice on the phone sounds like it does has nothing to do with lossy compression; it's the narrow frequency range of 300Hz - 3kHz which gives the traditional phone sound. Also, MP3 compression doesn't eliminate "frequencies" (eg Ultrasonic) that humans can't hear... this is such a common misconception of the Fourier analysis. Think about it, audio files with a sample rate of 44-48kHz (eg CDs, iTunes) don't even physically allow for ultrasonic frequencies due to their Nyquist limit. I am all for conceptual explanations, but there's no need to make untrue statements... it just means everyone gets the complete wrong idea about audio.
No. For example, reducing the sample rate will lower the Nyquist limit (ie. the upper limit of the bandwidth), thus reducing the amount of data, but it isn't data / lossy compression. It would be like lowering the resolution or contrast on an image file. It's not data compression. Lossy compression specifically relates to algorithms that detect repeated information, and removes the information which has a lower occurrence or significance to perception. In relation to audio, this is done using a manipulation of the fact that the tuned receptors in our ears are stimulated rather coarsely (critical bands), and we can rather crudely simplify a repeated waveform (eg. a harmonically generated sound) before we perceive a loss of quality. Turbulent sounds (eg. fricatives, or cymbals) are the first thing we notice as being degraded, since there is no repetition.
Are you just arguing semantics? Reducing resolution (or decimation/downsampling) would align to the definition of lossy compression. Where do you get your definition from?
Hmmm.. i suppose you could argue that technically, any reduction of the amount or integrity of information (eg downsampling, reducing bit rate, etc) is a form of lossy compression, but i don't think this is helpful. Lossy compression is only ever meaningfully used to describe encoding techniques such as MPEG or JPEG. "Downsampling" is an unambiguous term, which is treated independently from compression. If someone told me that they applied lossy compression to a picture, but they had simply reduced the image size , I would say that this person has not understood lossy compression.
You had to squeeze that in somehow, didn't you? You had to let the prestigious TH-cam commenting section know, you - are a computer sceince major. Well congratulations! I'm sure they're prepping your virgins as we speak.
I think this is my favorite Crash Course series. I am taking computer science, so it's always nice to see something that I am familiar with, but even better when the topic is about something I have not studied yet.
5:36 "We'll need to append it to the front of the image data like this..." There's a word for that! 'prepend' en.oxforddictionaries.com/definition/prepend
so gosh darn good. I covered 4 2h lcts w/o getting some of these data, & there is nothing missing either. I deduced some of it - but 4 lects in I shouldnt have to. So gr8.
You know what I love most about you, you don't modulate your voice in that annoying way some other, **Cough** Mr. Green **cough** I can't watch anything presented by that guy.
It would be cool if Crash Course did a PC Build for this topic at the end... I'm not sure if that has to do with computer science or not, but still, it would be fun to watch.
This was one of the coolest episodes this far. It explained so many phenomena we see everyday while using computers! And now I know how to explain to my little sister (who's completely clueless about computers) why a JPG file is smaller than a PNG one. =)
I'll stick with WAVs and BMPs, thanks. I will only use MP3s and JPGs when absolutely necessary or when quality doesn't matter (which is rare). There are some things you simply do not compromise the quality on, whether you can see/hear the finer nuances or not. Lossless compression ONLY over here, if ever.
*Are all those compressions methods available in our Famous WinRAR* ? Or are we supposed to use another one that is more specialised ?? Can you suggest... ?
I don't think I've ever had to wait for more than a second for any email attachments to download. I don't know it that says more about my internet connection or the emails I get.
According to the speed test I just ran I download at 47.4 Mbps so ~6 MB/s which means it'd take just over three seconds to download. Which is more than the second I claimed in my comment, but still not very long at all.
Found it weird that you grouped blocks of two different colors before you just make a pallete. There's 3 colors so thats 9 bytes + 16 * 2 bits = 13 bytes. I guess it was to show off the binary tree thing but the example seemed a bit off.
9:14 interessante que quando mostra s 2 fotos uma do lado da outra eles colocaram 2 fotos iguais sem ser um jpeg, ai quando mostraram antes é ALTAMENTE VISÍVEL a diferença, se seus olhos não estão funcionando corretamente, no minimo renomeie a foto que mudou para não colocar as 2 iguais...
La foto que que utilizó antes de la comparación fue con otro método. En el video mencionó que en la foto anterior era como 1/10 de la data y la comparación era con una usando como 1/3. (The photo she used before the comparison was using another method. In the video she mentioned that the previous picture used about 1/10 of the data and the comparison was using about 1/3)
In reality, at least for me, Huffman (or any "grossly" variable length codes) are a pain. They are not really critical and a much simpler encoding scheme can be used. They do save a little storage space but not much compared to some simpler schemes.
I was watching SILICON VALLEY then i started wondering what is compression i know the basic idea but how do we implement it.. Then another movement i am here 😂
I like to read, but I find this animated way of getting first layer of information about the subject highly effective. If one is interested he can dig deeper using the visual model from the course.
Can zooming technique be used to compress data for transmision. For example a 300 pixel by 300 pixel zoom down to 3 pixel by 3 pixel size but instead of digital we use true color raster image formats or png. Same for sound and voice we use some wave in graphical image and zoom it down mili second wave at milivolt scale for encoding we could save billion dollar in airtime a day
You have several wrong statements in this video. One that I will mention that is way off is you stated without compression, streaming videos on TH-cam would not be possible. First of all, compression is only effective if the originally stored data format is INefficient. If you have code that generates output in an efficient manner, then little or no compression is needed. For example, if a camera ONLY outputs JPG files at reasonable filesizes (about 0.3 bytes per pixel), then no additional compression is needed as those are probably small enough to send via internet to family and friends and should have good quality. Another wrong thing you said is smaller data files (as a result of greater compression) result in more lost data and worse quality. That is not necessarily true. Algorithm A might compress a file 10:1 whereas algorithm B might compress that same (input) file 12:1, however B might be better quality with LESS lost data. It depends on the quality of the compression algorithm (and other factors). You cannot make a blanket statement that smaller compressed file are of worse (lower) quality than larger ones cuz that is not always true (although it is many times (usually) true). Also data compression is a mathematical thing, not Computer Science. A compression algorithm can be defined on paper mathematically, without even one line of computer code. Whether or not it is implemented on a computer is irrelevant to the fact that it was defined mathematically. Downvoted for inaccuracy.
only today i learnt that DFTBA in her intro means dont forget to be awesome
Hi! I'm a computer engineer and programming instructor myself and I'd like to say that this series is fantastic and original! I haven't seen other sources cover this type of content but it's very relevant and refreshing! I actually learned something myself with the lossy and dictionary compression mentioned in this episode which I didn't expect. Keep up the great work!
"That might sound like magic, but it's actually computer science."
Listen here Carrie Anne, COMPUTER SCIENCE IS MAGIC!
"Where I'm from, science and magic are one, and the same." ~THOR; 2011
Thongalinchavu kadha ra pandhi
You are a perfect example of what the Internet should be like. Thank you for the videos!
This video contains an explanation of Huffman coding that was more concise AND more understandable than the explanation given in my university Communication Systems course. I'd pay ACTUALLY DISGUSTING amounts of money for a Crash Course Electrical Engineering.
I knew about Huffman coding from my University Communication Systems course, but I agree, this was way more concise. It's not called Crash Course for nothing. :P
'Hate mail from the audiophiles' needs to be a podcast.
"But >20 KHz sounds affects the overall sounds through harmonic effects" says a lot of audiophiles who reject emperical measurement of the overpriced equipment they buy/sell/brag about to other audiophiles they've convinced to reject emperical measurement. Not to say >20 KHz harmonics don't affect the overall sound in the perceptible range. Just that a lot of people who make that claim would ignore any measurements that back that up because they'd also refute any claims made about special cables, grounding boxes, or magnetized beads they payed out the nose to include in an overpriced and underperforming sound room.
Every episode has an underlaid tone that no one with cheap speakers can hear. (No such tone is there, but you'll just bet they'll all claim they can hear it.)
Aka "Placebo" effect.
There are snobby a-holes in everything subject. Like food enthusiasts who will bash everything that isn't caviar-encrusted lobster (or whatever), while the rest of us are just like "I don't care, just gimme a cheeseburger".
audiophiles are like the wine~tasters of solonoid magnets, heh heh
MP3 also takes advantage of the fact that the human hear can't hear soft sounds after loud ones, so the soft ones are removed.
Invaluable crash courses. Many thanks!
If you keep crashing we suggets you retake you driving test stay safe on the roads
With the Huffman tree example you can get twice as much compression by compressing each colour separately than in pairs (15B storage instead of 30B)
Pied piper is the only loss-less compression I know, thanks to richard’s middle-out compression algorithm 😂😂😂😂
Excellent video, but you forgot to mention that often the more complex compression algorythms are, the more charge for the CPU there will be for decoding: for eg, h.265 video codec for Ultra HD is 4x more efficient in file size, but requires at least x4 processor power to decode and x4 time to encode than h.264.
Time to encode and CPU performance to decode is important too subject in compression :P
most modern cpus and gpus have dedicated decoding and even encoding logic onboard so performance has become less of a concern
This series is a lot better than my University lectures
Retro iPod. The fact that there is such a thing means I'm getting old.
Damn I love this series so much! This is such a banger baseline for anyone with a passing interest in computers!
4:34 Ahhh! You made a zombie stick figure!
In all seriousness, thank you for this excellent video! Great content! Can't wait to learn more from you.
Hahahahahahahahahhahahahahahahhahaahhahhahahaahahahhahaha i saw and made a smell in my panties vey SpOoKy aaaaaahhhhhhhhhhhhh
"Any sufficiently advanced compression technique is indistinguishable from magic."
3:03 This entire series I guessed it was 'don't forget to be amazing' 😂
Finally, the answer!
Would have been good to get a mention on Shannon entropy and limits of information compression. There are universal truths to be found when probing these limits, where information crosses into the realms of probability and uncertainty. Its interesting stuff.
It's also a 12-minute video. In fact, I'm usually one for going "but what about..." on these videos but I thought this presented a really good selection of fundamentals and current applications.
Mmm...Shannon-Fano trees. Yum!
The next episode will be dedicated to that. They announced it on Patreon.
Awesome ! :)
i am a computer engineer myself
I guarantee this is A-class material which is hard to come by
young people should make maximum use of this information
And cheers to crash course computer science
jai hind
It's actually funny, because going on subreddits like "/r/headphones" they don't bash lossy compressions at all.
Sure they archive in flac, but they don't mind listening to songs on Spotify that uses lossy compression because they admit most of us can't hear the difference anyway.
this course is great, very clear
Joke's on you, Carrie Anne: FLAC isn't uncompressed; it's lossless.
These videos are so easy to listen to, yet so informative. Great job.
2:39 hahahahahaahhaha look at bottom right corber hahaha big funmy
It should be noted that the concept of compression was pioneered by Huffman in the 50s and it predates computer science.
The reason your voice on the phone sounds like it does has nothing to do with lossy compression; it's the narrow frequency range of 300Hz - 3kHz which gives the traditional phone sound.
Also, MP3 compression doesn't eliminate "frequencies" (eg Ultrasonic) that humans can't hear... this is such a common misconception of the Fourier analysis. Think about it, audio files with a sample rate of 44-48kHz (eg CDs, iTunes) don't even physically allow for ultrasonic frequencies due to their Nyquist limit.
I am all for conceptual explanations, but there's no need to make untrue statements... it just means everyone gets the complete wrong idea about audio.
Well said!
No.
For example, reducing the sample rate will lower the Nyquist limit (ie. the upper limit of the bandwidth), thus reducing the amount of data, but it isn't data / lossy compression.
It would be like lowering the resolution or contrast on an image file. It's not data compression.
Lossy compression specifically relates to algorithms that detect repeated information, and removes the information which has a lower occurrence or significance to perception. In relation to audio, this is done using a manipulation of the fact that the tuned receptors in our ears are stimulated rather coarsely (critical bands), and we can rather crudely simplify a repeated waveform (eg. a harmonically generated sound) before we perceive a loss of quality.
Turbulent sounds (eg. fricatives, or cymbals) are the first thing we notice as being degraded, since there is no repetition.
Are you just arguing semantics? Reducing resolution (or decimation/downsampling) would align to the definition of lossy compression. Where do you get your definition from?
Hmmm.. i suppose you could argue that technically, any reduction of the amount or integrity of information (eg downsampling, reducing bit rate, etc) is a form of lossy compression, but i don't think this is helpful.
Lossy compression is only ever meaningfully used to describe encoding techniques such as MPEG or JPEG. "Downsampling" is an unambiguous term, which is treated independently from compression.
If someone told me that they applied lossy compression to a picture, but they had simply reduced the image size , I would say that this person has not understood lossy compression.
In the context of learning and to avoid misconceptions, I agree with you.
Very helpful, I will definitely have the extra hand when school starts again in September!
Please make a crashcourse about machine learning (AI).
I assume there'll be a few videos about it later in the CS series. But I agree, a whole series about AI would be awesome!
Yesh please!
Agreed.
Machine Learning and A.I are vastly different things, those shouldn't be confused.
Isn't Machine Learning a subset of AI?
Hoffman is the man!
So cool! Thanks for this series!
"That might sound like majic, but it's actually computer science!"
As a computer science major, I agree.
*magic c:
You had to squeeze that in somehow, didn't you? You had to let the prestigious TH-cam commenting section know, you - are a computer sceince major.
Well congratulations! I'm sure they're prepping your virgins as we speak.
But behind those magics has very extensive mathematical theorem.
*magic
This comment exists just to say you’re a compsci meme major why?
Note that audio compression should not be confused with data compression of audio.
This series is gorgeous
The most interesting and useful for me among the others
I think this is my favorite Crash Course series. I am taking computer science, so it's always nice to see something that I am familiar with, but even better when the topic is about something I have not studied yet.
5:36 "We'll need to append it to the front of the image data like this..."
There's a word for that! 'prepend'
en.oxforddictionaries.com/definition/prepend
You go girl, excellent.
you can still see it's a dog, but the image is ruffer..... anyone? :D
"You! Get out!" ;) Seriously though, that was kinda funny. Was also thinking: "I'll be here all week! Try the veal!"
David Chipman where's the last one from again?
Think it's a old vaudville phrase. (Edit follows) Turns out it's from New York.
So are you saying that the compression technique is barking up the wrong tree?
your not funny. boooo.
Compresssion is great
thank your very much I learned a lot of things watching this episode!
This series is so awesome...very nicely done
Dope. You guys rock
so gosh darn good. I covered 4 2h lcts w/o getting some of these data, & there is nothing missing either. I deduced some of it - but 4 lects in I shouldnt have to. So gr8.
“Knock, knock.”
“Who’s there?”
very long pause….
“Java.”
not anymore
"C++"
“Knock, knock.”
“Who’s there?”
really, not for nearly a decade.
+Creuilcreuil_ So, that program has a racing condition bug due to C++'s poor multithreading?
James Flaum "KnockWho'sGoKnockThereLang"
Brilliant. Thank you!
Thank you so much for the information.
Great crash course!!
Thanks for the video !
Lossy audio compressors: The bass clef instrumentalist's worst enemy.
You know what I love most about you, you don't modulate your voice in that annoying way some other, **Cough** Mr. Green **cough** I can't watch anything presented by that guy.
I love this series!!!!!
My brain literally throbbing trying to keep up with the video
It would be cool if Crash Course did a PC Build for this topic at the end... I'm not sure if that has to do with computer science or not, but still, it would be fun to watch.
Thanks - really good explanation - very understandable!
Nice video! Thanks.
Prefix-free is sooooo cool..
Help help im being compressed
shadowfirekarp 😂
Jelp jelp
Me aswell
It's ok when we expand you you'll be the same
RubyMetro not if you expand to a larger size
I have to say I love how clear you speak - I can speed up the video to 1.5X and still understand everything!
*grabs popcorn and awaits for the comments about being "jif", not "gif"*
Gustavo Coelho even though it's phonetic spelling is usally the same as the extension in discussions.
This is PBS digital studios and we stay zhaif around here.
Ha! Caught one!
I've noticed less and less people pronouncing it as "jif".
This is a good thing.
To bloody hell with all the peanutbutterheads, it's hard-G Gif
So, is TH-cam's video compression the reason that we can't see the saccadic movement of the eyes?
Really really really good episode. Learned so much!
This was one of the coolest episodes this far. It explained so many phenomena we see everyday while using computers! And now I know how to explain to my little sister (who's completely clueless about computers) why a JPG file is smaller than a PNG one. =)
6:42 "Your hearing is not perfect." Throwing the truth-bombs.
Thanks
I'll stick with WAVs and BMPs, thanks. I will only use MP3s and JPGs when absolutely necessary or when quality doesn't matter (which is rare). There are some things you simply do not compromise the quality on, whether you can see/hear the finer nuances or not. Lossless compression ONLY over here, if ever.
*Are all those compressions methods available in our Famous WinRAR* ?
Or are we supposed to use another one that is more specialised ??
Can you suggest... ?
I've seen the glitch effect you demonstrated a lot when we lose TV signal.
Cool Sounds,😁
"The answer is compression, which literally squeezes data into a smaller size."
In my notebook: compression = smaller font 1s and 0s.
These videos are really so helpful, thank you for putting them together!
The quartet could be compessed to the null set.
I really like these videos. I am using them with my GCSE Computer Science classes. They are great for revision and intervention. Thank-you.
I already know all you teach, I just enjoy watching you talk
Thank you.
Amazing
I like competer science sometimes, thanks crash corse
"I have a killer collection on my retro ipod"
Dankpods has entered the chat
I feel Google Fiber would be a lot more popular if it weren't for compression.
I couldn't tell the different because the video was overcompressed but I'll try again. Frick.
you should have gotten richard hendricks to teach this episode
I love this course, absolutely love it. I'm laughing and all. Thanks, Carrie Anne.
You just had to add a dad joke at the end 🙂
I don't think I've ever had to wait for more than a second for any email attachments to download. I don't know it that says more about my internet connection or the emails I get.
Huntracony
PowerPoint attachments can be 20 MB big and they take time to download.
According to the speed test I just ran I download at 47.4 Mbps so ~6 MB/s which means it'd take just over three seconds to download. Which is more than the second I claimed in my comment, but still not very long at all.
Your connection is faster than most who are connected at DSL speeds. And there are people out there who are still on dial-up.
I only use middle-out compression
How long until internet speeds are good enough to the point where we only rarely use compression?
Found it weird that you grouped blocks of two different colors before you just make a pallete. There's 3 colors so thats 9 bytes + 16 * 2 bits = 13 bytes. I guess it was to show off the binary tree thing but the example seemed a bit off.
You missed middle-out-compression. I was looking forward to your explanation on how it works!
pied piper wont allow them to publish their secret
சிறப்பு
9:14
interessante que quando mostra s 2 fotos uma do lado da outra eles colocaram 2 fotos iguais sem ser um jpeg, ai quando mostraram antes é ALTAMENTE VISÍVEL a diferença, se seus olhos não estão funcionando corretamente, no minimo renomeie a foto que mudou para não colocar as 2 iguais...
La foto que que utilizó antes de la comparación fue con otro método. En el video mencionó que en la foto anterior era como 1/10 de la data y la comparación era con una usando como 1/3.
(The photo she used before the comparison was using another method. In the video she mentioned that the previous picture used about 1/10 of the data and the comparison was using about 1/3)
Do I look like I know what a JPEG is? I just want a picture of a gat-danged hot dog!
In reality, at least for me, Huffman (or any "grossly" variable length codes) are a pain. They are not really critical and a much simpler encoding scheme can be used. They do save a little storage space but not much compared to some simpler schemes.
I was watching SILICON VALLEY then i started wondering what is compression i know the basic idea but how do we implement it.. Then another movement i am here 😂
I like to read, but I find this animated way of getting first layer of information about the subject highly effective. If one is interested he can dig deeper using the visual model from the course.
How we can justify compression?
Is there no middle out method
Can zooming technique be used to compress data for transmision. For example a 300 pixel by 300 pixel zoom down to 3 pixel by 3 pixel size but instead of digital we use true color raster image formats or png. Same for sound and voice we use some wave in graphical image and zoom it down mili second wave at milivolt scale for encoding we could save billion dollar in airtime a day
Do people still use skype?
unfortunately
Thank you so much! Wow this is complicated. I have to hand it to the nerds, they work hard at obscure techniques.
"USB, I'm your father", "Noooo"...?
What's the rest of that shirt?
When in doubt google is your best friend... :)
I've been wanting to see the rest for a while now
Its just a usb stick and a floppy disk. The floppy is the father. You probably get the rest. if u want to see the whole one, google it ;3
Fun fact : in that scene DV actually says "no, i'm your father" and not "luke, i am your father"
Thank you Carrie Anne, for being good at simplifying complicated things
You have several wrong statements in this video. One that I will mention that is way off is you stated without compression, streaming videos on TH-cam would not be possible. First of all, compression is only effective if the originally stored data format is INefficient. If you have code that generates output in an efficient manner, then little or no compression is needed. For example, if a camera ONLY outputs JPG files at reasonable filesizes (about 0.3 bytes per pixel), then no additional compression is needed as those are probably small enough to send via internet to family and friends and should have good quality.
Another wrong thing you said is smaller data files (as a result of greater compression) result in more lost data and worse quality. That is not necessarily true. Algorithm A might compress a file 10:1 whereas algorithm B might compress that same (input) file 12:1, however B might be better quality with LESS lost data. It depends on the quality of the compression algorithm (and other factors). You cannot make a blanket statement that smaller compressed file are of worse (lower) quality than larger ones cuz that is not always true (although it is many times (usually) true).
Also data compression is a mathematical thing, not Computer Science. A compression algorithm can be defined on paper mathematically, without even one line of computer code. Whether or not it is implemented on a computer is irrelevant to the fact that it was defined mathematically.
Downvoted for inaccuracy.