33 Replies Latest reply on Oct 25, 2009 3:47 PM by Jeff Bellune

    Output file size

    1mousse1 Level 1

      I have been away from doing video for some time.  Been doing still photos.  In that medium I have learned the tricks of the trade on how to change the pixels per inch and compression levels to minimize the size of the final product for better performance over the internet.  My question is what games do you play with videos to minimize the end product file size?

        • 1. Re: Output file size
          Jim_Simon Level 8

          I've been using the F4V output for my web videos.  Looks pretty decent.

          • 2. Re: Output file size
            the_wine_snob Level 9

            What is your intended delivery scheme? If you are going to a player on the Internet, then Jim has given you a good place to start. If you are going to YouTube, then you have to play by their "rules du jour," and expect things to change next week. If you are going to Vimeo, then you have much more latitude and tiny file sizes are less of an issue. Also, if you have to fit things into streaming server limitations, and a Webmaster's design of a player, you will have to play by those rules, whether FLV, or .MP4/H.264, etc.

             

            Good luck,

             

            Hunt

            • 3. Re: Output file size
              1mousse1 Level 1

              I am not getting responses in line with what I expected.  I am new to this and I am using Adobe Premiere Pro which I have been told is level one.  So given that, how do I control the output of this program such that I can have an influence over the final file size?

               

              For right now it is intended for Youtube.  But what variables can I control when constructing the video in Adobe Premiere Pro (V1) and also exporting the finished product which affect the final size of the finished product file size?

              • 4. Re: Output file size
                the_wine_snob Level 9

                For YouTube, you will need to first gather their specs.. Note that these change far too often for anyone to know what they are at this instant. There specs. will direct you.

                 

                The two main choices will be H.264 MP4, or FLV, or at least they were. YouTube is a moving target and regardless of what you supply/upload, it will be re-encoded by YouTube. Again, regardless of what you upload, the resulting quality will very likely suffer.

                 

                Good luck,

                 

                Hunt

                • 5. Re: Output file size
                  Bill Gehrke Most Valuable Participant

                  Sorry but I can not remember much about APP 1.  But, basically after you select the format that is compatible with Youtube you reduce the bandwidth and image size to the minimum that produces an acceptable image..

                   

                  Edit:  Hunt is a faster typist than I am.

                  • 6. Re: Output file size
                    the_wine_snob Level 9

                     

                     

                    Hunt

                    • 7. Re: Output file size
                      Bill Gehrke Most Valuable Participant

                      Not that I am interested in posting to Youtube but this thread got me curious.  The only limits I found that they have is 2 GB file size and 10 minutes length.  They take what ever you send within those limits and re-encode to a 16:9 window that is 640 x 360 pixels.  But if you want the best quality send in the largest 16:9 aspect ratio file within the limits.

                       

                      My question is does Premiere Pro 1 have either of those two formats, I really doubt the h.264/MPEG4 existed at that time.

                       

                      Does APP 1 even support 16:9?

                      • 8. Re: Output file size
                        the_wine_snob Level 9

                        Bill,

                         

                        Those are good questions.

                         

                        One way "around" things coud be to use QuickTime Pro (US$39 upgrade/unlock) to convert another Export format/CODEC to H.264.

                         

                        Just a thought,

                         

                        Hunt

                        • 9. Re: Output file size
                          1mousse1 Level 1

                          OK.  Lets start over.  I appreciate all the offers to help but I have been out of this stuff long enough that I am having a problem communicating my problem and understanding the answers.  I created a short 1.5 minute video clip which resulted in a 444,263 KB , avi file.  That was one humongous file to upload to Youtube.  They converted it into a .MPG3 file of around 9 MBs.  To me that is still a huge file for 1.5 minutes of video.  What things can I do to control the size of the output file?  What things can I do when generating the video that influence the size of the output file?  So far I am importing videos from a camcorder which is brought in as an .avi from an analog video camera.  I am mixing in sound in either .wav or .mpg3 format.  I throw in some title graphics.  I thought it was a simple production.  Please bare with me.  I am trying to bootstrap up from near zero.

                          • 10. Re: Output file size
                            Jim_Simon Level 8

                            What things can I do when generating the video that influence the size of the output file?

                             

                            There are only two factors that determine final file size.  Duration, and bitrate.  To make any given output smaller, either make it shorter, or reduce the bitrate.

                            • 11. Re: Output file size
                              1mousse1 Level 1

                              What is considered a minimum bit rate for viewing on a computer monitor over the internet?  What is gained by exceeding this bit rate for things to be viewed on a computer monitor.   I understand for photos that 72dpi is standard for video on computer monitors (high res is changing that).  In addition there is the compression factor which influences the quality of the picture.  So for a .jpg at 72dpi the resulting output file size is highly influenced by the compression factor applied to the file.   The smaller the file size the faster it is displayed.  The time it takes to download and display the end product highly influences the viewing pleasure perceived by the end user, the viewer.  Can I influence the output of a video in a similar way?

                              • 12. Re: Output file size
                                Jim_Simon Level 8

                                What is considered a minimum bit rate for viewing on a computer monitor over the internet?

                                 

                                That depends on the codec used.  The F4V files I create have an average bitrate of 1500 kbps.  MPEG 2 would require a much higher bitrate to get the same quality.

                                • 13. Re: Output file size
                                  shooternz Level 6

                                  9mbs is a piddling small file for 1.5 minutes of  video.  What is your concern?  (ie.Quality , file size....)

                                   

                                  Add this to the elements you can control that  influence file size...dimension of the picture  eg 960 x 720 vs 480 x 360 vs 240 x 180 etc

                                  • 14. Re: Output file size
                                    John Currie Level 1

                                    1mousse1

                                     

                                    All suggestions from previous posts seem fine. Try a seach of the Adobe web site http://www.adobe.com/?

                                     

                                    As a starting point go to Support/Knowledgebase/ and input search criteria "video file size" you will them find 10+ pages of links to information concerning properties/variables that govern amongst other elements, the file size.

                                     

                                    John

                                     

                                     

                                     

                                    • 15. Re: Output file size
                                      1mousse1 Level 1

                                      Thanks to all for your time and patience.  I am now off to do the research suggested by John.  From all the comments received it is now clear to me that I have suffered in the field of creating movies because I have failed to keep myself and my software up to date in this changing world.  Time for me to go study and perhaps spend some money.  Again, Thanks to all for you time and patience.

                                      • 16. Re: Output file size
                                        Jim_Simon Level 8

                                        elements you can control that  influence file size...dimension of the picture

                                         

                                        That actually won't have any effect on file size, only quality.  Duration and bitrate are the only determinants of file size.  How many bits per second x how many seconds = file size.

                                        • 17. Re: Output file size
                                          John Currie Level 1

                                          Jim

                                           

                                          A direct quote from the second link given in post #14 above:

                                           

                                          http://www.adobe.com/devnet/dreamweaver/articles/add_video_02.html

                                           

                                          "The video's display size has a direct effect on the resulting file size: a smaller display size requires a smaller video file, and a larger display size requires a larger video file. You can customize the display size, but you should always constrain the height and width to make sure the video's aspect ratio (ratio of width to height) doesn't change.

                                          The video's bitrate also has an effect on quality and file size. A higher bitrate results in higher quality and a larger file."

                                           

                                          Further link three in post #14 above states:

                                           

                                          http://kb2.adobe.com/cps/312/312640.html

                                           

                                          "Calculating image size in Adobe Premiere

                                          To calculate the size in kilobytes (K) of one frame of uncompressed video, use the following formula:

                                          Frame size K = ([Pixel Width x Pixel Height x Bit Depth] / 8) / 1024

                                          Where 8 represents an 8-bit byte, and 1024 equals the number of bytes per kilobytes. For example, the size in kilobytes of an uncompressed frame of full-size (640 x 480), 24-bit video is:

                                          Frame size K = ([640 x 480 x 24] / 8) / 1024 = 900K

                                           

                                          To determine the file size of one second of uncompressed video, multiply the image size by the number of frames per second (fps). For example, one second of uncompressed, full-size, full-speed (30 fps), 24-bit video is:

                                          900K x 30 = 27 MB

                                          To determine how compression affects file size, divide the file size by the compression ratio. For example, a 10:1 compression ratio will make a 27 MB file 2.7 MB."

                                           

                                          I believe frame size does reflect in file size.

                                           

                                          ie Shooternz is correct.

                                           

                                          John

                                          • 18. Re: Output file size
                                            Jim_Simon Level 8

                                            "The video's display size has a direct effect on the resulting file size:

                                             

                                            Given the same bitrate and duration, that is simply not correct.

                                             

                                            Try it.

                                            • 19. Re: Output file size
                                              Jim_Simon Level 8

                                              To determine the file size of one second of uncompressed video

                                               

                                              First, I don't believe we're talking about Uncompressed here.  Second, Uncompressed isn't constrained by a fixed bitrate.  It can't be.  Uncompressed uses as many bits as needed to encode the frame.  So a bigger frame size with larger bit depths will of course use a higher bitrate, which is solely responsible for the increased file size (given a constant duration).

                                              • 20. Re: Output file size
                                                Stan Jones Adobe Community Professional & MVP

                                                mousse, I think you are asking the wrong question, but I think the resources John points to will be very useful.  It is the wrong question because a larger filesize in one format may be poorer quality than a smaller filesize in another.  And all that matters for your immediate purpose (upload to YouTube) is what format at what size/datarate will achieve your quality goal.

                                                 

                                                For the moment, focus on what formats you have in your version of Premiere that YouTube recommends.  Start here:

                                                 

                                                http://www.google.com/support/youtube/bin/answer.py?hl=en&answer=55744

                                                 

                                                If you don't have mp4, use wmv.  (You set your project up for your source format/size.  You export to the frame size/format/datarate you want to upload to YouTube.)

                                                 

                                                Be sure when viewing, that you are using the YouTube high quality option.  It may take longer for that to be available after uploading.

                                                • 21. Re: Output file size
                                                  John Currie Level 1

                                                  Wrong, read the post

                                                   

                                                  John

                                                  • 22. Re: Output file size
                                                    John Currie Level 1

                                                    Again, wrong, wrong, wrong. Read the quoted reference. You are wrong.

                                                     

                                                    John

                                                    • 23. Re: Output file size
                                                      Jeff Bellune Adobe Community Professional

                                                      "The video's display size has a direct effect on the resulting file size: a smaller display size requires a smaller video file, and a larger display size requires a larger video file.

                                                      John,

                                                       

                                                      You are misinterpreting what this is saying.  That's not a reflection on you; it is worded very badly.

                                                       

                                                      The reason that a smaller display size requires a smaller video file (notice that it doesn't say that it produces a smaller video file!) is because you can use a lower bit rate with a smaller display size and still get a good quality picture.  If you used that same low bit rate with a larger frame size, the final video would have serious quality issues.  With larger frame sizes, you need a higher bit rate, and that's what makes the file size larger.

                                                       

                                                      -Jeff

                                                      • 24. Re: Output file size
                                                        Dag Norum Level 2

                                                        Please also take a moment to think about the word "bitrate", which means bits per second (or kilobits per second or bytes per second or kilobytes per second).

                                                         

                                                        That means that if you give x amount of bits (kb, B, kB) per second to a video, the file size just MUST be x times number of seconds, no matter pixel size of the frame.

                                                         

                                                        Jeff (and shooternz) explained the quality aspect, Jim explained (well, pointed at) the math.

                                                         

                                                        To repeate, bitrate is one thing only: Amount of data per second, and that HAS to determine the file-size. Try it as Jim said.

                                                         

                                                        PS! Easiest to try with CBR (constant bitrate)

                                                         

                                                        Dag

                                                        • 25. Re: Output file size
                                                          John Currie Level 1

                                                          Hi

                                                           

                                                          Jim Simon post #16

                                                           

                                                          "

                                                          elements you can control that  influence file size...dimension of the picture

                                                           

                                                          That actually won't have any effect on file size, only quality.  Duration and bitrate are the only determinants of file size.  How many bits per second x how many seconds = file size."

                                                           

                                                          This was the post by Jim Simon that I thought was incorrect, I still believe it to be incorrect.  Hence my post, and I believe it to be incumbent on those who think they know better to speak up, for the benefit of the greater community - with clarity and not muddy waters that are already obscure .

                                                           

                                                          Frame size is reflected in file size regardless to references to bitrate later.  There are at least three parameters involved, namely bitrate, length of video and yes, frame size. Constant bitrate/variable bitrate change as you will, if the frame size goes up, so will the file size for a given bitrate and length of video.

                                                           

                                                          Jeff - you answered this already, the larger the frame size, to achieve the same quality, you require a higher bitrate, leading to a higher file size.

                                                           

                                                          Dag - no question, the bitrate affects file size, along with length of video and frame size.

                                                           

                                                          Stan - I think you have found the middle course here, you have identified what the OP wanted to find out.

                                                           

                                                          John

                                                           

                                                           

                                                           

                                                           

                                                           

                                                           

                                                           

                                                          • 26. Re: Output file size
                                                            Jeff Bellune Adobe Community Professional

                                                            Frame size is reflected in file size regardless to references to bitrate later.  There are at least three parameters involved, namely bitrate, length of video and yes, frame size.

                                                            No.  This is simply wrong.  If the bit rate is constant, and the duration is constant, then a 320x240 frame size will have the exact same file size as a 1920x1080 frame size.  Try it for yourself.

                                                             

                                                            -Jeff

                                                            • 27. Re: Output file size
                                                              John Currie Level 1

                                                              Jeff

                                                               

                                                              "Calculating image size in Adobe Premiere

                                                              To calculate the size in kilobytes (K) of one frame of uncompressed video, use the following formula:

                                                              Frame size K = ([Pixel Width x Pixel Height x Bit Depth] / 8) / 1024

                                                              Where 8 represents an 8-bit byte, and 1024 equals the number of bytes per kilobytes. For example, the size in kilobytes of an uncompressed frame of full-size (640 x 480), 24-bit video is:

                                                              Frame size K = ([640 x 480 x 24] / 8) / 1024 = 900K

                                                              To determine the file size of one second of uncompressed video, multiply the image size by the number of frames per second (fps). For example, one second of uncompressed, full-size, full-speed (30 fps), 24-bit video is:

                                                              900K x 30 = 27 MB

                                                              To determine how compression affects file size, divide the file size by the compression ratio. For example, a 10:1 compression ratio will make a 27 MB file 2.7 MB. "

                                                               

                                                              This is a quote from Adobe http://kb2.adobe.com/cps/312/312640.html

                                                               

                                                              Are you saying this is not correct?

                                                               

                                                              John

                                                               

                                                               

                                                               

                                                               

                                                              • 28. Re: Output file size
                                                                Jeff Bellune Adobe Community Professional

                                                                John,

                                                                 

                                                                The key word in your example is "uncompressed".  If you are dealing with uncompressed video, that means that each and every pixel in the frame has to be stored in the file.  The bigger the frame, the more pixels there are to be stored, and the bigger the file size.

                                                                 

                                                                That's not true for compressed video like MPEG2 or H.264.  Every pixel in every frame doesn't exist - most of the pixels are represented mathematically by the codec.  For compressed video, the file size is determined by the bit rate and the duration of the video.  Frame size has nothing to do with it.  The codec will adjust the quality of the video to maintain the specified bit rate.

                                                                 

                                                                The science of temporal compression is complex.  Google for documents about MPEG and H.264 encoding and you will find that many of them belong in a graduate-level mathematics class.

                                                                 

                                                                For video editors, it's simple: when using a codec that relies on temporal compression, bit rate and duration determine file size.  Nothing else matters.

                                                                 

                                                                -Jeff

                                                                • 29. Re: Output file size
                                                                  John Currie Level 1

                                                                  Jeff

                                                                   

                                                                  An example:

                                                                   

                                                                  bitrate B (measured in kilobytes per second say)

                                                                   

                                                                  duration of video T (measured in seconds)

                                                                   

                                                                  File Size F = B x T ( measured in kilobytes)

                                                                   

                                                                  Let's say B = 3000 (kB/s) and T = 5min = 300 seconds

                                                                   

                                                                  Hence file size F = 3000 x 300 = 900000 kB

                                                                   

                                                                  OK? Think we are agreed up to this point.

                                                                   

                                                                  From the previously quoted Adobe source to calculate file size:

                                                                   

                                                                  Frame size K = ([640 x 480 x 24] / 8) / 1024 = 900 kB (for 640 x 480 frame size)

                                                                   

                                                                  Hence one second of uncompressed video for this frame size at 30 fps and 24 bit depth is

                                                                  900 x 30 = 27000 kB

                                                                   

                                                                  Therefore 300 seconds worth of uncompressed video = 300 x 27000 = 8100000 kB file size.

                                                                   

                                                                  Now, this is where the compression codec comes in, if you want 900000kB of file size, as has already been stipulated by bitrate and duration, you must adjust the compression ratio of the codec accordingly to match, loosing quality probably in the process, depending on the method of compression and algorithm employed.

                                                                   

                                                                  The compression ratio required in this example is 8100000/900000 = 9 to 1 for a frame size of 640 x 480.

                                                                   

                                                                  If you wanted 320 x 240 frame size, the compression ratio would be 9/4 = 2.25 to 1 giving, probably, better quality.

                                                                   

                                                                  This ignores container overheads and audio etc

                                                                   

                                                                  John

                                                                  • 30. Re: Output file size
                                                                    Jeff Bellune Adobe Community Professional

                                                                    John,

                                                                     

                                                                    All of what you said is correct, but as Jim Simon pointed out in post #19, we're not dealing with uncompressed here.  Even high-end studios avoid uncompressed video as final delivery format.  The on-topic question is about controlling file size using some form of compression.  All of the main disc and web delivery codecs use temporal compression, and those file sizes are strictly determined by bit rate and duration and nothing else.

                                                                     

                                                                    If you want to talk about whether a certain file size that results from a certain bit rate will produce acceptable quality given the frame size of the video, then that's a topic for a different thread.

                                                                     

                                                                    -Jeff

                                                                    • 31. Re: Output file size
                                                                      John Currie Level 1

                                                                      Jeff

                                                                       

                                                                      Your views on the undernoted would be appreciated.

                                                                       

                                                                      Recapping the example in post #29

                                                                       

                                                                      File size F = B x T

                                                                       

                                                                      Lets say bitrate B = 3000 (kB/s) and duration T = 5min = 300 seconds

                                                                       

                                                                      Hence file size F = 3000 x 300 = 900000 kB

                                                                       

                                                                      So returning to the previous example, instead of adjusting the Compression Ratio from 9 to 2.25, maintain the original compression ratio based on the original 3000 kB/s bitrate, that is 9. This means that when the Frame Size is now adjusted down from 640 x 480 to 340 x 240, the bitrate can go down in the same proportions. Namely from 3000 kB/s to 750 kB/s. This then reflects in the file size reducing accordingly to 225000 kB, showing a drop in file size in direct proportion to reducing frame dimensions.

                                                                       

                                                                      I believe this addresses the original poster's request for guidance on file size parameters and shows a direct relationship between file size and frame size and also incorporates temporal compression considerations.

                                                                       

                                                                       

                                                                       

                                                                      John

                                                                       

                                                                       

                                                                       

                                                                      PS

                                                                       

                                                                      Mathematically this can be expressed as:

                                                                       

                                                                      Rearranging the Adobe File Size equation and introducing a codec compression variable:

                                                                       

                                                                      File size F = (Frame Size K x Frame rate (fps)) x T

                                                                                                              C

                                                                       

                                                                      Where K = ([Pixel Width x Pixel Height x Bit Depth] / 8) / 1024

                                                                       

                                                                      and C = compression ratio of the codec

                                                                       

                                                                       

                                                                       

                                                                      Therefore  F = B x T = (Frame Size K x Frame rate (fps)) x T ( T not equal to 0 )

                                                                                                                             C

                                                                       

                                                                      Therefore B = (Frame Size K x Frame rate (fps))

                                                                                                              C

                                                                      or

                                                                       

                                                                      B (is proportional to) Frame Size

                                                                       

                                                                       

                                                                      This shows mathematically that B the bitrate is directly proprtional to the Frame Size assuming Frame rate and Compression Ratio are held constant. Even if the Compression Ratio is not held constant, but allowed to vary through the compression process, the average/mean/notional Bitrate used to calculate the file size in the equation F = Bmean x T can still be considered to be a function of the Frame Size. This would be achieved by:

                                                                       

                                                                      F = The Sum of  (B1 x T1 + B2 x T2 + … Bn x Tn) = Bmean x T

                                                                       

                                                                      Again, this ignores container overheads and audio etc

                                                                      • 32. Re: Output file size
                                                                        Dag Norum Level 2

                                                                        John,

                                                                         

                                                                        I'm not Jeff, but...

                                                                         

                                                                        Your math is fine, showing quite clearly that if you select smaller pixel-size you can use smaller bitrate and get the "same" picture quality (at least per pixel).

                                                                         

                                                                        Now, what Jim, Jeff and I have tried to point out is that when a compressor is SET to use a certain bitrate, the pixel-size will not matter when it comes to file-size because the compressor can not use more bits per second than what's given no matter pixel-size. Then the File size F = B x T is the "rule" (given CBR).

                                                                         

                                                                        Dag

                                                                        • 33. Re: Output file size
                                                                          Jeff Bellune Adobe Community Professional

                                                                          What Dag said.

                                                                           

                                                                          -Jeff