Pages: [1] 2   Go Down

Author Topic: I'm stuck in a very stupid situation, Please help!  (Read 8393 times)

aaronchan

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 617
I'm stuck in a very stupid situation, Please help!
« on: August 31, 2017, 05:07:51 am »

Dear all,

I'm trying to submit a photo contest online.
Since I have to upload the image on their website, there are some rules for the image files:
File has to be between 5-10MB
File has to be in JPG

OK, so one of my pictures has a huge white background,
after converting it to JPG, it only has 2.9MB. (included sRGB icc profile)
But it's already 4000x5000 pixel.

I have contacted the CS of this contest and they said I will need to mainipulate the file size in some way........

Is there anyway to increase the file size but not effect my image itself?


Thanks
Aaron

Otto Phocus

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 655
Re: I'm stuck in a very stupid situation, Please help!
« Reply #1 on: August 31, 2017, 05:44:54 am »

Good luck with this, I did not know that having an image that was too small would be a concern.

I am interested in learning the solution to this problem also.
Logged
I shoot with a Camera Obscura with an optical device attached that refracts and transmits light.

francois

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 13769
Re: I'm stuck in a very stupid situation, Please help!
« Reply #2 on: August 31, 2017, 06:07:15 am »

I may not understand the issue but if you only need to increase the file size, then crank up the JPEG compression quality when you convert to JPEG (something like 85% in Photoshop).
Logged
Francois

kers

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 4388
    • Pieter Kers
Re: I'm stuck in a very stupid situation, Please help!
« Reply #3 on: August 31, 2017, 06:21:58 am »

the white background is easy to compress instead of saying   :
white white white white white white white white white white white white  .... 
the jpeg code will be something like       100000 times white      much smaller


so if the size 4000px is not a problem and you want to send in the best possible quality  - you can compress the image less in jpeg  ( in photoshop 100% is best jpeg quality)
Hope this helps,


Pieter Kers
Logged
Pieter Kers
www.beeld.nu/la

aaronchan

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 617
Re: I'm stuck in a very stupid situation, Please help!
« Reply #4 on: August 31, 2017, 06:23:24 am »

the white background is easy to compress instead of saying   :
white white white white white white white white white white white white  .... 
the jpeg code will be something like       100000 times white      much smaller


so if the size 4000px is not a problem than you can compress the image less in jpeg  ( in photoshop 100% is best jpeg quality
Hope this helps,


Pieter Kers

Hi,

When I save as JPG, I've set the quality to 12 already which is the highest........ :(

Mark D Segal

  • Contributor
  • Sr. Member
  • *
  • Offline Offline
  • Posts: 12512
    • http://www.markdsegal.com
Re: I'm stuck in a very stupid situation, Please help!
« Reply #5 on: August 31, 2017, 07:57:07 am »

From all of the above it seems that the only option left is to create a duplicate image file and try upsizing it by resampling to various pixel volumes within the allowed range and check for image quality. It will likely be best with the resampling (PPI) that takes the file to the bottom limit of what they accept.
Logged
Mark D Segal (formerly MarkDS)
Author: "Scanning Workflows with SilverFast 8....."

kirkt

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 604
Re: I'm stuck in a very stupid situation, Please help!
« Reply #6 on: August 31, 2017, 08:20:19 am »

A simple fix is to add a very small, practically unnoticeable amount of monochromatic noise.  For example, in PS, add a new layer above your existing image and use Filter > Noise > Add Noise...  Use something like 3-5% (or even lower) and monochromatic.  You can use a mask on this layer to add the noise only to the white area, so the image content does not get noise applied.  The amount of noise you add does not need to be that great, just enough to get the JPEG compression scheme to see that the background is not a large area of contiguous, identical blocks of color.

Save the file with JPEG quality maximum ("12" in PS, or 100%). 

As an example, I created a 5000x4000 px white document in PS (8bit, sRGB).  I saved the document with JPEG max - the file size was 128 kB.  I added 5% monochromatic gaussian noise and saved again - file size 11.4 MB.  With 2% noise, I get a file size of 8 MB.  Etc. 

You can adjust the percentage of noise and the opacity of the noise layer to tweak the file size, as well as changing the JPEG compression quality.  You can also apply a Gaussian blur to the noise layer to change (smooth) the distribution of discretely different pixels, essentially making the white area with noise more uniform - this will make JPEG compression more efficient and decrease the file size and break up any discrete noise that you may see at 100% zoom when viewing.

This should give you the flexibility to target the file size you need.

As a bonus, a small amount of noise, or "grain," sometimes improves the impression of image acutance - maybe your image will serendipitously get this little boost from adding noise too!

kirk
« Last Edit: August 31, 2017, 08:33:01 am by kirkt »
Logged

Mark D Segal

  • Contributor
  • Sr. Member
  • *
  • Offline Offline
  • Posts: 12512
    • http://www.markdsegal.com
Re: I'm stuck in a very stupid situation, Please help!
« Reply #7 on: August 31, 2017, 08:36:34 am »

JPEG doesn't support layers as far as I remember. What happens to the file size when you flatten it to save as JPEG?
Logged
Mark D Segal (formerly MarkDS)
Author: "Scanning Workflows with SilverFast 8....."

kirkt

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 604
Re: I'm stuck in a very stupid situation, Please help!
« Reply #8 on: August 31, 2017, 09:21:06 am »

JPEG doesn't support layers as far as I remember. What happens to the file size when you flatten it to save as JPEG?

When you save as a JPEG it flattens the image (and, if working in 16bit for editing purposes, converts to 8bit).  The numbers I was citing for file size were the JPEG files resulting from the exercise.  I assumed the OP knew this.

If you need to preserve the edibility, save a PSD with layers you can switch on and off (the various noise layers you are experimenting with) and do a "Save As..." to JPEG to output each JPEG with its specific noise layer enabled.  Using PS's "Layer Comps" feature would be helpful if you are experimenting with a bunch of different levels of noise, each on its own layer.  In PS CC you can use the "Export > Layer Comps to Files..." feature to export all of the comps to their own files, in a single batch.

Layer Comps are just saved states of, in this case, combinations of layer visibility.  So, you could enable the background and NoiseLayer01 and save that as a comp; then disable Noise Layer01 and enable NoiseLayer02 (with the background enabled) and save this as another comp, etc.  This way you have generated all of the combinations of the background and the various noise layers using comps and then you can export each comp (each combination) as a JPEG, all in a batch.  You can even repeat the process, but change the amount of JPEG compression for the batch.  Etc.  Then compare the results visually and for desired file size.

kirk

kirk
« Last Edit: August 31, 2017, 09:31:00 am by kirkt »
Logged

kers

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 4388
    • Pieter Kers
Re: I'm stuck in a very stupid situation, Please help!
« Reply #9 on: August 31, 2017, 09:29:31 am »

Well Aaron, it is indeed a stupid situation if your image has to be at least 5MB.
I would try to get it through at 3MB since this rule is only meant to certify they get the quality they need   and you already do that.
it is like with all rules- they are invented for a certain task but sometimes have an unintended life of their own.
cheers, PK


Logged
Pieter Kers
www.beeld.nu/la

Daverich

  • Full Member
  • ***
  • Offline Offline
  • Posts: 164
Re: I'm stuck in a very stupid situation, Please help!
« Reply #10 on: August 31, 2017, 01:08:33 pm »

Is there any chance that the file size requirement is the minimum size the file has to be when it's open and not the size of the .jpg? That is, they want a minimum resolution for whatever purpose they're going to use it for? As has been pointed out in previous posts, .jpg files size varies wildly depending on the content of the file so by specifying a .jpg size they would be getting images in much different resolutions. In my experience when submitting images to contests they are way more likely to specify a Maximum .jpg size that can be sent due to transmission and storage concerns. Mandating a Minimum .jpg size makes no sense. Is it possible you've misunderstood the contest requirements? And if you've talked to them about it they've misunderstood what you were asking?
« Last Edit: August 31, 2017, 01:43:55 pm by Daverich »
Logged

aaronchan

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 617
Re: I'm stuck in a very stupid situation, Please help!
« Reply #11 on: August 31, 2017, 02:15:48 pm »

Is there any chance that the file size requirement is the minimum size the file has to be when it's open and not the size of the .jpg? That is, they want a minimum resolution for whatever purpose they're going to use it for? As has been pointed out in previous posts, .jpg files size varies wildly depending on the content of the file so by specifying a .jpg size they would be getting images in much different resolutions. In my experience when submitting images to contests they are way more likely to specify a Maximum .jpg size that can be sent due to transmission and storage concerns. Mandating a Minimum .jpg size makes no sense. Is it possible you've misunderstood the contest requirements? And if you've talked to them about it they've misunderstood what you were asking?

Each applicant can only enter once in each cycle.Each submission must consist of a series of up to 10 images and captions, Project Statement, Biography and Personal Data. Images uploaded to the competition website must be a minimum of 5 megabytes and not exceed the maximum size of 10 megabytes, in JPEG/JPG format. If your work is voted to the shortlist of finalists, you will be asked to submit a high-resolution version of all images within 7 days of notification.



Their website has a script to detect your file size before upload


Sent from my iPhone using Tapatalk

Tim Lookingbill

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 2436
Re: I'm stuck in a very stupid situation, Please help!
« Reply #12 on: August 31, 2017, 02:39:11 pm »

Try Photoshop's "Save For Web" compression options.

It has more refined file size controls over "Save As..." jpeg and has better quality compression in rendering fine detail (I've tested this).

Also check the real file size after saving to disk by doing a "get info" or however your OS implements this. I've found the MB size is often different from the readouts in Photoshop "Save As..." and SFW.
Logged

Daverich

  • Full Member
  • ***
  • Offline Offline
  • Posts: 164
Re: I'm stuck in a very stupid situation, Please help!
« Reply #13 on: August 31, 2017, 02:50:15 pm »

Each applicant can only enter once in each cycle.Each submission must consist of a series of up to 10 images and captions, Project Statement, Biography and Personal Data. Images uploaded to the competition website must be a minimum of 5 megabytes and not exceed the maximum size of 10 megabytes, in JPEG/JPG format. If your work is voted to the shortlist of finalists, you will be asked to submit a high-resolution version of all images within 7 days of notification.



Their website has a script to detect your file size before upload


Sent from my iPhone using Tapatalk

Just for the heck of it I took a random image of mine that didn't contain much in the way of solid colors and sized it so that I got a .jpg that fit within the contest requirements. An 8x12 @360 PPI of the image is 35 megs when it's open and 6.9 megs on disk as a highest quality .jpg. Basically, the image is high resolution already, I can't imagine a contest wanting something higher unless they were going to make large prints of the winners. Sizing the same image to 8x12 @150 PPI gives me an open file size of 6 megs which to me is low resolution and yet would fall within the contest specifications. Whether they were trying to stay with low resolution or high resolution files to start with, it just makes no sense to specify the size of the .jpg as a way to accomplish that because as you've already shown, the resolution of the image could be anything when it's open based on the content of the image. Just my 2 cents.
Logged

BradSmith

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 772
Re: I'm stuck in a very stupid situation, Please help!
« Reply #14 on: August 31, 2017, 08:48:51 pm »

What if your double or triple its pixel dimensions in photoshop or in the export dialog from Lightroom?  In other words, create many more pixels.  Maybe this still won't get a final jpg bigger than 5Mb because you'll mainly be increasing all those pure white pixels.  But it is easy to do and therefore, worth a try.
Brad
Logged

NAwlins_Contrarian

  • Full Member
  • ***
  • Offline Offline
  • Posts: 225
Re: I'm stuck in a very stupid situation, Please help!
« Reply #15 on: September 01, 2017, 12:37:23 am »

I was going to suggest almost exactly what kirkt suggested: add a slight amount of noise. Also, as I think he at least implied, you probably want it to be luminance noise, not color noise, which I think most people see as much more objectionable-looking. However, I was going to suggest you mask off or something and add it only to the all-white areas. That should provide a substantially greater increase in the data needed to record the image as a JPEG than would a similar noise increase in the other parts of the image--without adding noise to them.
Logged

joofa

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 544
Re: I'm stuck in a very stupid situation, Please help!
« Reply #16 on: September 01, 2017, 12:44:06 pm »

Dear all,

I'm trying to submit a photo contest online.
Since I have to upload the image on their website, there are some rules for the image files:
File has to be between 5-10MB
File has to be in JPG

OK, so one of my pictures has a huge white background,
after converting it to JPG, it only has 2.9MB. (included sRGB icc profile)
But it's already 4000x5000 pixel.

I have contacted the CS of this contest and they said I will need to mainipulate the file size in some way........

Is there anyway to increase the file size but not effect my image itself?


Here is an experiment that I did and it worked for me. Basically, I patched a JPEG file with extra zeros at the end. I did on a Mac, but the same exact commands below can be repeated on Linux. And equivalent commands may be used on Windows.

Enter the following 2 commands in a Terminal window:

(1) Create a dummy 'zeros file':
dd if=/dev/zero bs=1 count=1048576 > zeros.bin   (Change the number 1048576 to whatever size you want. Here I created 1MB dummy file.)

(2) Patch an original JPEG and zeros file into a new bloated file:
cat original.jpg zeros.bin > bloated.jpg

It worked with Preview and Gimp. Didn't try other programs. But, I would think they would also work.

Good thing with this method is that no quality degradation needs to happen (say by adding noise or other disruptive procedures.)
« Last Edit: September 01, 2017, 12:54:04 pm by joofa »
Logged
Joofa
http://www.djjoofa.com
Download Photoshop and After Effects plugins

Tim Lookingbill

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 2436
Re: I'm stuck in a very stupid situation, Please help!
« Reply #17 on: September 01, 2017, 03:08:38 pm »

Yes! This IS a stupid situation. All this just to enter a stupid photo contest.
Logged

Doug Gray

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 2197
Re: I'm stuck in a very stupid situation, Please help!
« Reply #18 on: September 01, 2017, 05:42:36 pm »

I was going to suggest almost exactly what kirkt suggested: add a slight amount of noise. Also, as I think he at least implied, you probably want it to be luminance noise, not color noise, which I think most people see as much more objectionable-looking. However, I was going to suggest you mask off or something and add it only to the all-white areas. That should provide a substantially greater increase in the data needed to record the image as a JPEG than would a similar noise increase in the other parts of the image--without adding noise to them.
I agree completely with both of you. It would take surprisingly little noise to reach the size requirement and, since it's added in while the image is still 16 bits, you'll often get a better jpeg
Logged

joofa

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 544
Re: I'm stuck in a very stupid situation, Please help!
« Reply #19 on: September 01, 2017, 05:54:07 pm »

I agree completely with both of you. It would take surprisingly little noise to reach the size requirement and, since it's added in while the image is still 16 bits, you'll often get a better jpeg

I don't understand that why go through the exercise of adding noise. I already gave a solution to bloat the file size to any desired number without compromising on quality at all. It is a couple of messages above.
« Last Edit: September 01, 2017, 06:05:12 pm by joofa »
Logged
Joofa
http://www.djjoofa.com
Download Photoshop and After Effects plugins
Pages: [1] 2   Go Up