8 Pages

lecture29

Course: CS 6448, Fall 2009
School: Colorado
Rating:
 
 
 
 
 

Word Count: 1825

Document Preview

where Credit Credit is Due Lecture 29: Test-Driven Development Kenneth M. Anderson Object-Oriented Analysis and Design CSCI 6448 - Spring Semester, 2003 Some of the material for this lecture is taken from Test-Driven Development by Kent Beck; as such some of this material is copyright Addison Wesley, 2003 April 22, 2003 University of Colorado, 2003 2 Goals for this lecture Introduce the concept of...

Register Now

Unformatted Document Excerpt

Coursehero >> Colorado >> Colorado >> CS 6448

Course Hero has millions of student submitted documents similar to the one
below including study guides, practice problems, reference materials, practice exams, textbook help and tutor support.

Course Hero has millions of student submitted documents similar to the one below including study guides, practice problems, reference materials, practice exams, textbook help and tutor support.
where Credit Credit is Due Lecture 29: Test-Driven Development Kenneth M. Anderson Object-Oriented Analysis and Design CSCI 6448 - Spring Semester, 2003 Some of the material for this lecture is taken from Test-Driven Development by Kent Beck; as such some of this material is copyright Addison Wesley, 2003 April 22, 2003 University of Colorado, 2003 2 Goals for this lecture Introduce the concept of Test-Driven Development (TDD) Present an example Test-Driven Development The idea is simple No production code is written except to make a failing test pass Implication You have to write test cases before you write code April 22, 2003 University of Colorado, 2003 3 April 22, 2003 University of Colorado, 2003 4 Writing Test Cases First This means that when you first write a test case, you may be testing code that does not exist And since that means the test case will not compile, obviously the test case fails After you write the skeleton code for the objects referenced in the test case, it will now compile, but also may not pass So, then you write the simplest code that will then make the test case pass TDD Life Cycle The life cycle of test-driven development is Quickly add a test Run all tests and see the new one fail Make a simple change Run all tests and see them all pass Refactor to remove duplication This cycle is followed until you have met your goal; note that this cycle simply adds testing to the add functionality; refactor loop of refactoring covered last week April 22, 2003 University of Colorado, 2003 6 April 22, 2003 University of Colorado, 2003 5 TDD Life Cycle, continued Kent Beck likes to perform TDD within a Testing Framework, such as JUnit, within such frameworks failing tests are indicated with a red bar passing tests are shown with a green bar Example Background: Multi-Currency Money Lets design a system that will allow us to perform financial transactions with money that may be in different currencies e.g. if we know that the exchange rate from Swiss Francs to U.S. Dollars is 2 to 1 then we can calculate expressions like 5 USD + 10 CHF = 10 USD As such, the TDD life cycle is sometimes described as red bar/green bar/refactor April 22, 2003 University of Colorado, 2003 7 or 5 USD + 10 CHF = 20 CHF April 22, 2003 University of Colorado, 2003 8 Starting From Scratch Lets start developing such an example How do we start? TDD recommends writing a list of things we want to test This list can take any format, just keep it simple Example $5 + 10 CHF = $10 if rate is 2:1 $5 * 2 = $10 April 22, 2003 University of Colorado, 2003 9 First Test The first test case looks a bit complex, lets start with the second 5 USD * 2 = 10 USD First, we write a test case public void testMultiplication() { Dollar five = new Dollar(5); five.times(2); assertEquals(10, five.amount) } April 22, 2003 University of Colorado, 2003 10 Discussion on Test Case public void testMultiplication() { Dollar five = new Dollar(5); five.times(2); assertEquals(10, five.amount) Whats Next? We need to update our test list The test case revealed some things about Dollar that we will want to clean up We are representing the amount as an integer, which will make it difficult to represent values like 1.5 USD; how will we handle rounding of factional amounts? Dollar.amount is public; violates encapsulation What about side effects?; we first declared our variable as five but after we performed the multiplication it now equals ten } What benefits does this provide? target class plus some of its interface we are designing the interface of the Dollar class by thinking about how we would want to use it We have made a testable assertion about the state of that class after we perform a particular sequence of operations April 22, 2003 University of Colorado, 2003 11 April 22, 2003 University of Colorado, 2003 12 Update Testing List The New List 5 USD + 10 CHF = 10 USD $5 * 2 = $10 make amount private Dollar side-effects? Money rounding? First version of Dollar Class public class Dollar { public Dollar(int amount) { } public void times(int multiplier) { } public int amount; } Now our test compiles and fails! April 22, 2003 University of Colorado, 2003 14 Now, we need to fix the compile errors no class Dollar, no constructor, no method times, no field amount April 22, 2003 University of Colorado, 2003 13 Too Slow? Note: we did the simplest thing to make the test compile; now we are going to do the simplest thing to make the test pass Is this process too slow? Yes, as you get familiar with the TDD life cycle you will gain confidence and make bigger steps No, taking small simple steps avoids mistakes; beginning programmers try to code too much before invoking the compiler; they then spend the rest of their time debugging! April 22, 2003 University of Colorado, 2003 15 How do we make the test pass? Heres one way public void times(int multiplier) { amount = 5 * 2; } The test now passes, we received a green bar! Now, we need to refactor to remove duplication But where is the duplication? Hint: its between the Dollar class and the test case April 22, 2003 University of Colorado, 2003 16 Refactoring To remove the duplication of the test data and the hard-wired code of the times method, we think the following We are trying to get a 10 at the end of our test case and weve been given a 5 in the constructor and a 2 was passed as a parameter to the times method So, lets hook things up April 22, 2003 University of Colorado, 2003 17 First version of Dollar Class public class Dollar { public Dollar(int amount) { this.amount = amount; } public void times(int multiplier) { amount = amount * multiplier; } public int amount; } Now our test compiles and passes, and we didnt have to cheat! April 22, 2003 University of Colorado, 2003 18 One loop complete! Before writing the next test case, we update our testing USD list 5 + 10 CHF = 10 USD $5 * 2 = $10 make amount private Dollar side-effects? Money rounding? One more example Lets address the Dollar Side-Effects item and then move on to general lessons So, lets write the next test case When we called the times operation our variable five was pointing at an about whose amount equaled ten; not good the times operation had a side effect which was to change the value of a previous created value object Think about it, as much as you might like to, you cant change a 5 dollar bill into a 500 dollar bill; the 5 dollar bill remains the same throughout multiple financial transactions 19 April 22, 2003 University of Colorado, 2003 20 April 22, 2003 University of Colorado, 2003 Next test case The behavior we want is public void testMultiplication() { Dollar five = new Dollar(5); Dollar product = five.times(2); assertEquals(10, product.amount); product = five.times(3); assertEquals(15, product.amount); assertEquals(5, five.amount); Test fails The test fails because it wont compile; We need to change the signature of the times method; previously it returned void and now it needs to return Dollar public Dollar times(int multiplier) { amount = amount * multiplier; return null; } Note: the last assert is redundant; it is implicitly shown to be true by the second assert; I decided to make it explicit April 22, 2003 University of Colorado, 2003 21 } The test compiles but still fails; as Kent Beck likes to say Progress! April 22, 2003 University of Colorado, 2003 22 Test Passes To make the test pass, we need to return a new Dollar object whose amount equals the result of the multiplication public Dollar times(int multiplier) { return new Dollar(amount * multiplier); } Discussion of the Example There is still a long way to go only scratched the surface But we saw the life cycle performed twice we saw the advantage of writing tests first we saw the advantage of keeping things simple we saw the advantage of keeping a testing list to keep track of our progress Test Passes; Cross Dollar Side Effects? off the testing list; second loop complete! (there was no need to refactor in this case); April 22, 2003 University of Colorado, 2003 23 Plus, as we write new code, we will know if we are breaking things because our old test cases will fail if we do; if the old tests stay green, we can proceed with confidence April 22, 2003 University of Colorado, 2003 24 Principles of TDD Testing List keep a record of where you want to go; Beck keeps two lists, one for his current coding session and one for later; You wont necessarily finish everything in one go! Principles of TDD, continued Assert First How do you write a test case? By writing its assertions first! Test First Write tests before code, because you probably wont do it after Writing test cases gets you thinking about the design of your implementation; does this code structure make sense? what should the signature of this method be? April 22, 2003 University of Colorado, 2003 25 Suppose you are writing a client/server system and you want to test an interaction between the server and the client Suppose that for each transaction, some string has to have been read from the server and that the socket used to talk to the server should be closed after the transaction Lets write the test case April 22, 2003 University of Colorado, 2003 26 Assert First public void testCompleteTransaction { assertTrue(reader.isClosed()); assertEquals(abc, reply.contents()); Assert First, continued public v...

Find millions of documents on Course Hero - Study Guides, Lecture Notes, Reference Materials, Practice Exams and more. Course Hero has millions of course specific materials providing students with the best way to expand their education.

Below is a small sample set of documents:

Colorado - CS - 3308
Lab #1 Installing a System Due Friday, September 6, 2002Name: Lab Time: Grade: /10The Steps of Installing a System Today you will install a software package. Implementing a software system is only part of a software engineers job. Once implemente
Colorado - CS - 3308
Lab #3 Automating Installation & Introduction to Make Due in Lab, September 17, 2003Name: Lab Time: Grade: Error Checking In this lab you will be writing a shell script to automate the installation of a system. The system that your shell script wil
Colorado - CS - 3308
Lab #7 Testing Due In Lab, October 22, 2003 Name: Lab Time: Grade: Testing Today you will be testing a program to expose failures. In Homework 7, you familiarized yourself with the operation of a quick sort program, quick-okay. Now that you know the
Colorado - CS - 3308
Lab #10 XML and XSLT Due in Lab, December 3, 2003 Name: Lab Time: Grade: /10In this lab, you will gain experience working with XML and XSLT. XML is a language for creating markup languages. A markup language is any language that includes both text
Colorado - CS - 3308
Notes on Using gdb, the GNU Debugger Benjamin Zorn (with small modications by Kenneth M. Anderson for CSCI 3308)A symbolic debugger can make writing and debugging programs much easier. The GNU debugger can be used to debug programs compiled with the
Colorado - CS - 3308
Software Testing Notebook Worksheet #1 Functional Testing Due: October 31, 2003 Name: Lab Time: Grade: /75On my honor, as a University of Colorado at Boulder student, I have neither given nor received unauthorized assistance on this work. Signature
Colorado - CS - 3308
Software Testing Notebook Worksheet #2 Structural Testing Due: Friday, November 7, 2003 Name: Lab Time: Grade: /50On my honor, as a University of Colorado at Boulder student, I have neither given nor received unauthorized assistance on this work. S
Colorado - CS - 3308
Software Testing Notebook Worksheet #3 Automating Testing & Fixing Bugs Due: November 14, 2003 Name: Lab Time: Grade: /75On my honor, as a University of Colorado at Boulder student, I have neither given nor received unauthorized assistance on this
Colorado - CS - 5828
Todays LectureThe Mythical Man-MonthKenneth M. Anderson Foundations of Software Engineering CSCI 5828 - Spring Semester, 2001 (Guest Lecture) Discuss first four chapters of The Mythical Man-Month The Tar Pit The Mythical Man-Month The Surgica
Colorado - CS - 5828
Todays Lecture Discuss Software Life CyclesSoftware Life CyclesKenneth M. Anderson Foundations of Software Engineering CSCI 5828 - Spring Semester, 2001 (Guest Lecture) Why do we need them? What types exist? Code and Fix (hacking) Waterfa
Colorado - CS - 5828
Todays Lecture The Cathedral and the BazaarKenneth M. Anderson Foundations of Software Engineering CSCI 5828 - Spring Semester, 2001 Guest Lecture Discuss Background of the Paper Discuss Raymonds Rules Open Discussion on the Open-Source Approach
Colorado - CS - 5828
Todays Lecture Extreme ProgrammingKenneth M. Anderson Foundations of Software Engineering CSCI 5828 - Spring Semester, 2001 Guest Lecture Discuss aspects of the Extreme Programming Model As presented in Extreme Programming Explained: Embrace Chan
Colorado - CS - 3308
Lab #2 Find and Grep Due in Lab, September 8, 2004 Name: Lab Time: Grade: Find The nd command is used to locate les in a le system. The nd command starts at a single directory and descends recursively into all of its subdirectories to locate les. The
Colorado - CS - 3308
Lab #3 Automating Installation & Introduction to Make Due in Lab, September 15, 2004Name: Lab Time: Grade: Error Checking In this lab you will be writing a shell script to automate the installation of a system. The system that your shell script wil
Colorado - CS - 3308
Todays Lecture Lecture 2: No Silver BulletKenneth M. Anderson Software Methods and Tools CSCI 3308 - Fall Semester, 2004August 27, 2004 University of Colorado, 2004 2Discuss No Silver Bullet paper Brooks reflections on it after nine years
Colorado - CS - 3308
Todays Lecture Lecture 6: Build ManagementKenneth M. Anderson Software Methods and Tools CSCI 3308 - Fall Semester, 2004September 10, 2004 University of Colorado, 2004 2Discuss Build Management Introduce makeBuild ManagementDuring the impleme
Colorado - CS - 3308
Todays Lecture Lecture 7: Make MacrosKenneth M. Anderson Software Methods and Tools CSCI 3308 - Fall Semester, 2004Brief review of make Explore make macros in more detailNote: when you see macro think variableBrooks Corner: The Mythical Man-Mont
Colorado - CULTER - 06
CU Mountain006 Research StationWinter 2 Ecology
Colorado - ASTR - 5770
New InflationAmy Bender 05/03/2006Inflation Basics Perturbations from quantum fluctuations of scalar field Fluctuations are: Gaussian Scale Invariant Spectrum (almost) k3P(k) ~ constant Adiabatic Scalar & Tensor Matter/radiation anisotrop
Colorado - ASTR - 5770
HST Key Project on the Extragalactic Distance ScalePresentation by Alaine Ginocchio May 5, 2006HST Key ProjectMeasuring an accurate value of H0 was one of the motivating reasons for building NASA/ESA Hubble Space Telescope (HST).Measurement
Colorado - ASTR - 5770
Holographic Dark EnergyPreety Sidhu 5 May 2006Black Holes and Entropy Black holes are maximal entropy objects Entropy of a black hole proportional to surface area of event horizon Max entropy for volume of space goes as bounding surface area, n
Colorado - ASTR - 5770
The Sunyaev-Zeldovich EffectJason Glenn APSHistorical Perspective Physics of the SZ Effect -Previous Observations & Results Bolocam Imminent Experiments Future Work ReferencesCMB discovered in 1964 by Penzias and Wilson COBE 1989: perfect blackbo
Wisconsin - CS - 0601
Proximal Plane ClassificationKDD 2001 San Francisco August 26-29, 2001Glenn Fung & Olvi MangasarianData Mining InstituteUniversity of Wisconsin - Madison Second Annual Review June 1, 2001Key ContributionsFast new support vector machine class
Wisconsin - REV - 0601
Proximal Plane ClassificationKDD 2001 San Francisco August 26-29, 2001Glenn Fung & Olvi MangasarianData Mining InstituteUniversity of Wisconsin - Madison Second Annual Review June 1, 2001Key ContributionsFast new support vector machine class
St. Johns River Community College - CS - 0601
Proximal Plane ClassificationKDD 2001 San Francisco August 26-29, 2001Glenn Fung & Olvi MangasarianData Mining InstituteUniversity of Wisconsin - Madison Second Annual Review June 1, 2001Key ContributionsFast new support vector machine class
Wisconsin - CS - 0600
Concave Minimization for Support Vector Machine ClassifiersUnlabeled Data Classification & Data SelectionGlenn Fung O. L. MangasarianPart 1: Unlabeled Data Classifications ssssGiven a large unlabeled dataset Use a k-Median clustering al
Wisconsin - REV - 0600
Concave Minimization for Support Vector Machine ClassifiersUnlabeled Data Classification & Data SelectionGlenn Fung O. L. MangasarianPart 1: Unlabeled Data Classifications ssssGiven a large unlabeled dataset Use a k-Median clustering al
St. Johns River Community College - CS - 0600
Concave Minimization for Support Vector Machine ClassifiersUnlabeled Data Classification & Data SelectionGlenn Fung O. L. MangasarianPart 1: Unlabeled Data Classifications ssssGiven a large unlabeled dataset Use a k-Median clustering al
Wisconsin - ECE - 756
Linear Programming and CPLEXTing-Yuan Wang Advisor: Charlie C. ChenDepartment of Electrical and Computer Engineering University of Wisconsin-MadisonFeb. 22 2000CPLEX Optimization Options: Primal, Dual Simplex Methods Network Flow Problems MI
St. Johns River Community College - ECE - 756
Linear Programming and CPLEXTing-Yuan Wang Advisor: Charlie C. ChenDepartment of Electrical and Computer Engineering University of Wisconsin-MadisonFeb. 22 2000CPLEX Optimization Options: Primal, Dual Simplex Methods Network Flow Problems MI
Wisconsin - ECE - 03
Artifact and Textured region Detection- Vishal BangardOutline Need for artifact and textured region detection Aim of the project Techniques used in the imaging world Approaches used Results ConclusionWhy do artifact detection ? A lot of
Wisconsin - ECE - 738
Artifact and Textured region Detection- Vishal BangardOutline Need for artifact and textured region detection Aim of the project Techniques used in the imaging world Approaches used Results ConclusionWhy do artifact detection ? A lot of
St. Johns River Community College - ECE - 03
Artifact and Textured region Detection- Vishal BangardOutline Need for artifact and textured region detection Aim of the project Techniques used in the imaging world Approaches used Results ConclusionWhy do artifact detection ? A lot of
St. Johns River Community College - ECE - 738
Artifact and Textured region Detection- Vishal BangardOutline Need for artifact and textured region detection Aim of the project Techniques used in the imaging world Approaches used Results ConclusionWhy do artifact detection ? A lot of
Wisconsin - ECE - 03
Unequal Error Protection for Video Transmission over Wireless ChannelsECE738 Project PresentationChang, Hong Hong 05/09/20031OutlineUnequal Error Protection/ Unequal Loss Protection Problem Formulation Channel Model RS code Theoretical Res
Wisconsin - ECE - 738
Unequal Error Protection for Video Transmission over Wireless ChannelsECE738 Project PresentationChang, Hong Hong 05/09/20031OutlineUnequal Error Protection/ Unequal Loss Protection Problem Formulation Channel Model RS code Theoretical Res
St. Johns River Community College - ECE - 03
Unequal Error Protection for Video Transmission over Wireless ChannelsECE738 Project PresentationChang, Hong Hong 05/09/20031OutlineUnequal Error Protection/ Unequal Loss Protection Problem Formulation Channel Model RS code Theoretical Res
St. Johns River Community College - ECE - 738
Unequal Error Protection for Video Transmission over Wireless ChannelsECE738 Project PresentationChang, Hong Hong 05/09/20031OutlineUnequal Error Protection/ Unequal Loss Protection Problem Formulation Channel Model RS code Theoretical Res
Wisconsin - ECE - 03
Portraiture MorphingPresented by Fung, Chau-ha JeniceOutline Problem Statement Prior Art: Portraiture Morphing Approaches Results Conclusion Future WorksProblem Statement Image morphing = Image metamorhposis Creating a smooth transfor
Wisconsin - ECE - 738
Portraiture MorphingPresented by Fung, Chau-ha JeniceOutline Problem Statement Prior Art: Portraiture Morphing Approaches Results Conclusion Future WorksProblem Statement Image morphing = Image metamorhposis Creating a smooth transfor
St. Johns River Community College - ECE - 03
Portraiture MorphingPresented by Fung, Chau-ha JeniceOutline Problem Statement Prior Art: Portraiture Morphing Approaches Results Conclusion Future WorksProblem Statement Image morphing = Image metamorhposis Creating a smooth transfor
St. Johns River Community College - ECE - 738
Portraiture MorphingPresented by Fung, Chau-ha JeniceOutline Problem Statement Prior Art: Portraiture Morphing Approaches Results Conclusion Future WorksProblem Statement Image morphing = Image metamorhposis Creating a smooth transfor
Wisconsin - ECE - 03
ECE 738 ProjectBrain segmentation and Phase unwrapping in MRI dataJongHoon LeeOutline Nature of fast MRI: EPI & Field Inhomogeneity Background problem Image Distortion Specific problems a) Brain Segmentation b) Phase Unwrapping Goal Appro
Wisconsin - ECE - 738
ECE 738 ProjectBrain segmentation and Phase unwrapping in MRI dataJongHoon LeeOutline Nature of fast MRI: EPI & Field Inhomogeneity Background problem Image Distortion Specific problems a) Brain Segmentation b) Phase Unwrapping Goal Appro
St. Johns River Community College - ECE - 03
ECE 738 ProjectBrain segmentation and Phase unwrapping in MRI dataJongHoon LeeOutline Nature of fast MRI: EPI & Field Inhomogeneity Background problem Image Distortion Specific problems a) Brain Segmentation b) Phase Unwrapping Goal Appro
St. Johns River Community College - ECE - 738
ECE 738 ProjectBrain segmentation and Phase unwrapping in MRI dataJongHoon LeeOutline Nature of fast MRI: EPI & Field Inhomogeneity Background problem Image Distortion Specific problems a) Brain Segmentation b) Phase Unwrapping Goal Appro
Wisconsin - ECE - 03
ECE738 Presentation of Project SurveyA survey of image-based biometric identification methods: Face, finger print, iris, and othersPresented by: David LinOutline Problems and motivations Different identification methods Face Recognition Fing
Wisconsin - ECE - 738
ECE738 Presentation of Project SurveyA survey of image-based biometric identification methods: Face, finger print, iris, and othersPresented by: David LinOutline Problems and motivations Different identification methods Face Recognition Fing
St. Johns River Community College - ECE - 03
ECE738 Presentation of Project SurveyA survey of image-based biometric identification methods: Face, finger print, iris, and othersPresented by: David LinOutline Problems and motivations Different identification methods Face Recognition Fing
St. Johns River Community College - ECE - 738
ECE738 Presentation of Project SurveyA survey of image-based biometric identification methods: Face, finger print, iris, and othersPresented by: David LinOutline Problems and motivations Different identification methods Face Recognition Fing
Wisconsin - ECE - 03
A survey of Face Recognition TechnologyWei-Yang Lin May 07, 2003Road Map Introduction Challenge in Face Recognition variation in pose Variation in illumination Some recently works in FRT DiscussionIntroduction FRT is a research area span
Wisconsin - ECE - 738
A survey of Face Recognition TechnologyWei-Yang Lin May 07, 2003Road Map Introduction Challenge in Face Recognition variation in pose Variation in illumination Some recently works in FRT DiscussionIntroduction FRT is a research area span
St. Johns River Community College - ECE - 03
A survey of Face Recognition TechnologyWei-Yang Lin May 07, 2003Road Map Introduction Challenge in Face Recognition variation in pose Variation in illumination Some recently works in FRT DiscussionIntroduction FRT is a research area span
St. Johns River Community College - ECE - 738
A survey of Face Recognition TechnologyWei-Yang Lin May 07, 2003Road Map Introduction Challenge in Face Recognition variation in pose Variation in illumination Some recently works in FRT DiscussionIntroduction FRT is a research area span
Wisconsin - ECE - 03
Medical Image Registration: A SurveyAiming LuOutline Introduction Transformation Algorithms Visualization Validation ConclusionIntroduction Image registration matching two images so that corresponding coordinate points in the two images
Wisconsin - ECE - 738
Medical Image Registration: A SurveyAiming LuOutline Introduction Transformation Algorithms Visualization Validation ConclusionIntroduction Image registration matching two images so that corresponding coordinate points in the two images
St. Johns River Community College - ECE - 03
Medical Image Registration: A SurveyAiming LuOutline Introduction Transformation Algorithms Visualization Validation ConclusionIntroduction Image registration matching two images so that corresponding coordinate points in the two images
St. Johns River Community College - ECE - 738
Medical Image Registration: A SurveyAiming LuOutline Introduction Transformation Algorithms Visualization Validation ConclusionIntroduction Image registration matching two images so that corresponding coordinate points in the two images
Wisconsin - ECE - 03
Detecting Artifacts and Textures in Wavelet Coded ImagesRajas A. Sambhare ECE 738, Spring 2003 Final ProjectJanuary 12, 2009Motivation Wavelet based image coders like JPEG 2000 lead to new types of artifacts when used at small bit-rates Bloc
Wisconsin - ECE - 738
Detecting Artifacts and Textures in Wavelet Coded ImagesRajas A. Sambhare ECE 738, Spring 2003 Final ProjectJanuary 12, 2009Motivation Wavelet based image coders like JPEG 2000 lead to new types of artifacts when used at small bit-rates Bloc
St. Johns River Community College - ECE - 03
Detecting Artifacts and Textures in Wavelet Coded ImagesRajas A. Sambhare ECE 738, Spring 2003 Final ProjectJanuary 12, 2009Motivation Wavelet based image coders like JPEG 2000 lead to new types of artifacts when used at small bit-rates Bloc