Skip to main content
Participant
June 7, 2019
質問

Why is file size of smart objects unnecessarily big?

  • June 7, 2019
  • 返信数 5.
  • 7822 ビュー

I have always liked non-destructive editing and smart objects can play a big part in this. One issue I have is file sizes when working with smart object layers - they are always much bigger than then they should be. My conclusion is the Photoshop .psd file stores an unnecessary rendered copy of each smart object layer.

To demonstrate the issue try this:

1. Open a file as a smart object and save.

Look at the file size, you would expect a small overhead to the size of the original file but it is about twice the size.

2. Make it a linked smart object (right click on the layer "Relink to file ..." and select the original file)

Our psd file now  contains just a link to the external original file, no actual real data that cant be derived from the original file - but it is still quite big!

3. Duplicate the linked smart object layer, save.

Twice no real data should be virtually nothing - it has grown again.

4. Now drastically shrink the image size, e.g. to 1% width and height  (Image -> Image size … ) and save.

Look at the file size - it is minute!

Try some other image sizes. You will find what ever size you set  the file size thus produced roughly tracks the image area. Hence my conclusions, the .psd file is unnecessarily storing a rendered version of each layer.

Even if it is slower to open up a file, I would very much like an option to create any rendered views needed on file opening and not storing them.

(Have I missed such an option?)

Regards,

Mark.

返信数 5

JJMack
Community Expert
Community Expert
June 7, 2019

mjr1342  wrote

I have always liked non-destructive editing and smart objects can play a big part in this. One issue I have is file sizes when working with smart object layers - they are always much bigger than then they should be. My conclusion is the Photoshop .psd file stores an unnecessary rendered copy of each smart object layer.

You conclusion is simply wrong.  If Photoshop did not have pixels for an image layer.  The layer would be empty. Additionally wrong because smart object layer can share object. So many smarty object layers may be sharing the same smart object pixels.  Each smart object layer has an associated transform for it object or shared object. These transforms transform the pixels rendered for the smart objects for how the layer uses the image. The transform Scales positions and distort the object for that layer.  So a Picture package PSD my have one smart objects shared by 10 smart object layers. So the Pixels rendered for the smart object are transformed by the ten layer transform to sizes and  positions the image to the ten image locations.  Each layer has it own transform and transformed image pixels  the PSD has only one copy of the pixels rendered for the object they are required. Without Pixels the layers will have not have any pixel content they will be empty.

JJMack
c.pfaffenbichler
Community Expert
Community Expert
June 7, 2019
You conclusion is simply wrong.

I think the approach the OP wishes to see implemented is possible for image editing in principle, tough probably not in Photoshop. 

Something like Illustrator where a placed image is actually a reference to a separate file and its position, scale etc.

Of course this poses challenges for painting, clone stamping etc. and efficiency.

JJMack
Community Expert
Community Expert
June 7, 2019

I don't even like linked Smart Object but I'm sure they have their place is some developed project work-flows.  At least the Smart object pixels rendered and stored in the PSD can recover the image should the master Master object file become corrupt, deleted or lost so that it can not be re-linked or updated.  I would not like to see any additional external file introduced.  I feel they need to be embedded in the PSD. IMO Place is even messed up.

JJMack
davescm
Community Expert
Community Expert
June 7, 2019

Photoshop does indeed store a rendered layer for each duplicated smart object. If the duplicated smart object contains 52 layers - the internals are not duplicated, the file size only increases by the rendered size.

Why do you believe that this is an issue?

Dave

c.pfaffenbichler
Community Expert
Community Expert
June 7, 2019

And if Photoshop had to place, transform and Filter all the SO-instances’ pixel content anew when opening a file that could take a while …  

mjr1342作成者
Participant
June 7, 2019

Thanks for your multiple thoughts c.pfaffenbichler.

Compatibility with other applications is something I was not considering, I only use Photoshop and Lightroom (thinking about it I don't know if Lightroom needs these rendered layers).

BTW I don't normally use linked smart objects, only used that in experimenting and it demonstrates  the issue well so mentioned it above.

In the real world an example is I had an 85M pixel stitched image - 0.5GB smart object .psd to start with (16 bit RGB). I was expecting using SO duplicates would help me out, but after using 3 smart object duplicates, I ended up over the 2GB so could not even save as .psd, had to use .psb!

Thinking of changes my camera soon and may end up with ~50M pixels per image, I can easily see if I want to stick with non-destructive editing I will be looking at typically 1GB plus an edit. That will soon add up to lots of disk space seems.

For me when I use Photoshop (as opposed to quick edits in lightroom), I open a file and edit for quite a while (often hours!) so file opening time is a low priority.

I was thinking of a feature request, but thought it better to sound out on this forum first, I will await a while for other input first.

c.pfaffenbichler
Community Expert
Community Expert
June 7, 2019

Anyway, you may want to post a Feature Request over at

Photoshop Family Customer Community

As mentioned earlier I see no benefit in the approach you envision (maybe one could call it »procedural referencing«?) for Photoshop at current, but others may share your opinion and some Adobe employee/s might chime in.

c.pfaffenbichler
Community Expert
Community Expert
June 7, 2019

As an aside: One thing that can make a huge difference in certain cases is whether the SO is flattened or layered.

c.pfaffenbichler
Community Expert
Community Expert
June 7, 2019
Even if it is slower to open up a file, I would very much like an option to create any rendered views needed on file opening and not storing them.

I disagree, that every instance of the Smart Object is actually rendered looks like a necessity for some things,

• like opening in older versions (or other editors) or

• addressing Layers in layout applications like Indesign or Illustrator or

• opening an image with missing linked Smart Objects,

so it seems beneficial to me.

To me file size consideration seems negligible compared to the potential opening-time-differences.

Edit: And the calculating effort could become very high if the SO-instances are not only transformed but also have multiple Filters applied to them which would all have to be calculated anew on opening if the results were not already stored in the file.

Participant
October 10, 2020

I think this feature will quit useful as optimization the document size, it can have more benifits at transfering on network or versioning. Imagine just a slighly change like position or scale, or want to compairing with multiple background, you have to save as a huge size of document. But I don't think ‘.PSD’ can implement this, because it compatibility. Maybe the future ".PSP" can. It will make a document more like an project. BTW, like AfterEffect can add multi effects that just like filters, but it can cached or using Hardware acceleration to quick previewing it. On the use of image files, I think shouldn't be waste on packing it all if you are not sending to anyone. Is not about how much disk space that you have, but about use it in a right way and not just simply duplicated.