Merging/joining into single object massively increases file size / Fills all available memory. #111564

Closed
opened 2023-08-26 19:58:10 +02:00 by Mark-Deamer-1 · 12 comments

System Information
Operating system: WIndows 10 22H2
Graphics card: Nvidia RTX 4090

Blender Version
Broken: 3.62 2023-08-16 16:43 Hash:e53e55951e7a
Worked: Not Sure.

Short description of error

Exact steps for others to reproduce the error
Based on the default startup or an attached .blend file (as simple as possible).

I am currently trying to move our teams process away from Maya to Blender, we deal with a massive amount of CAD data for numerous car manufactures. I've screen captured a simplified version of our workflow to see if it is a bug or if I'm doing something stupid. I'll outline the steps.

Undo's disabled.
Import 1.02gb FBX file.
Unparent parts from empties and apply all transforms. ( No increase in memory usage. )
Join similar textured meshes, as more meshes are joined memory usage increases ( in some cases on larger files filling the entire system memory )
Purge all orphaned data and save.
As you can see just these simple operation increase the file size from 2.11gb to 46.7gb, I've tried everything I can think of to find the leak/unused data but I am at a loss.
Reopen Save and as you can see 46.7gb of system memory used but only 2.11gb is my data, this is where it gets odd and I believe Blender is saving a ton of orphaned data or just garbage ( Remember undo's are disabled and I use Clean-ups constantly. )
Export to an .obj and the file drops back down to 2.48gb, reopen in blender and all the data is the same and nothing is missing but the file is back to 2.04gb again ! The export and reimport flushes all the unwanted data but is a pain to keep doing. Any help would be appreciated. Link below to the screen capture, couldn't get it smaller than 1.2gb at 4k Sorry.

https://1drv.ms/v/s!AoarOZXHLMNWirJ5XDDjIchwGRp2VA?e=fWChO1

A link to a zip below as Onedrive only seems to stream in 1080p

https://1drv.ms/u/s!AoarOZXHLMNWirJ6OKSxqjOvCXjFCg?e=IyhFk2

**System Information** Operating system: WIndows 10 22H2 Graphics card: Nvidia RTX 4090 **Blender Version** Broken: 3.62 2023-08-16 16:43 Hash:e53e55951e7a Worked: Not Sure. **Short description of error** **Exact steps for others to reproduce the error** Based on the default startup or an attached .blend file (as simple as possible). I am currently trying to move our teams process away from Maya to Blender, we deal with a massive amount of CAD data for numerous car manufactures. I've screen captured a simplified version of our workflow to see if it is a bug or if I'm doing something stupid. I'll outline the steps. Undo's disabled. Import 1.02gb FBX file. Unparent parts from empties and apply all transforms. ( No increase in memory usage. ) Join similar textured meshes, as more meshes are joined memory usage increases ( in some cases on larger files filling the entire system memory ) Purge all orphaned data and save. As you can see just these simple operation increase the file size from 2.11gb to 46.7gb, I've tried everything I can think of to find the leak/unused data but I am at a loss. Reopen Save and as you can see 46.7gb of system memory used but only 2.11gb is my data, this is where it gets odd and I believe Blender is saving a ton of orphaned data or just garbage ( Remember undo's are disabled and I use Clean-ups constantly. ) Export to an .obj and the file drops back down to 2.48gb, reopen in blender and all the data is the same and nothing is missing but the file is back to 2.04gb again ! The export and reimport flushes all the unwanted data but is a pain to keep doing. Any help would be appreciated. Link below to the screen capture, couldn't get it smaller than 1.2gb at 4k Sorry. https://1drv.ms/v/s!AoarOZXHLMNWirJ5XDDjIchwGRp2VA?e=fWChO1 A link to a zip below as Onedrive only seems to stream in 1080p https://1drv.ms/u/s!AoarOZXHLMNWirJ6OKSxqjOvCXjFCg?e=IyhFk2
Mark-Deamer-1 added the
Severity
Normal
Type
Report
Status
Needs Triage
labels 2023-08-26 19:58:11 +02:00

Hi, i can't download videos or attached file. Can you share it via google disk / youtube? And please, try to avoid 10 minute videos.

Hi, i can't download videos or attached file. Can you share it via google disk / youtube? And please, try to avoid 10 minute videos.
Iliya Katushenock added the
Interest
Modeling
label 2023-08-27 00:43:39 +02:00
Author

Hi Bud,

Cut down vid uploaded to Youtube, you should still see the issue, and a screengrab of file sizes as they increase and decrease.

https://youtu.be/Cul9-aLxwKk

Regards.
Mark.

Hi Bud, Cut down vid uploaded to Youtube, you should still see the issue, and a screengrab of file sizes as they increase and decrease. https://youtu.be/Cul9-aLxwKk Regards. Mark.
Member

One thing is that from the video those objects doesn't seem to be all merged completely...

Can't seem to think of a explanation other than if it's saving BMesh which I doubt. Will ping developers.

One thing is that from the video those objects doesn't seem to be all merged completely... Can't seem to think of a explanation other than if it's saving `BMesh` which I doubt. Will ping developers.
YimingWu added
Status
Needs Info from Developers
and removed
Status
Needs Triage
labels 2023-08-27 15:03:44 +02:00
Author

I only merged a few sets of items just to show the issue, if I'd carried on and merged all items by material then the saved uncompressed blend file would have been 118gb.

Regards.
Mark.

I only merged a few sets of items just to show the issue, if I'd carried on and merged all items by material then the saved uncompressed blend file would have been 118gb. Regards. Mark.

@Mark-Deamer-1 You seem unable to provide an example file?

@Mark-Deamer-1 You seem unable to provide an example file?
Member

What would be useful to compare is the data layers (shape keys, vertex groups and attributes) of the joined mesh to the data layers of the individual parts that have been joined together.

If, for example, each imported mesh had a uniquely named UV map, then the joined mesh would have every one of those UV maps, but each would be expanded to contain the full set of data of the joined mesh. Similarly, if one of the imported meshes had 100 shape keys, the joined mesh would also have all of those 100 shape keys, but each shape key would have expanded to contain the full data of the joined mesh. I don't know by how much, but a situation like this could greatly increase file size.

What would be useful to compare is the data layers (shape keys, vertex groups and attributes) of the joined mesh to the data layers of the individual parts that have been joined together. If, for example, each imported mesh had a uniquely named UV map, then the joined mesh would have every one of those UV maps, but each would be expanded to contain the full set of data of the joined mesh. Similarly, if one of the imported meshes had 100 shape keys, the joined mesh would also have all of those 100 shape keys, but each shape key would have expanded to contain the full data of the joined mesh. I don't know by how much, but a situation like this could greatly increase file size.
Author

What would be useful to compare is the data layers (shape keys, vertex groups and attributes) of the joined mesh to the data layers of the individual parts that have been joined together.

If, for example, each imported mesh had a uniquely named UV map, then the joined mesh would have every one of those UV maps, but each would be expanded to contain the full set of data of the joined mesh. Similarly, if one of the imported meshes had 100 shape keys, the joined mesh would also have all of those 100 shape keys, but each shape key would have expanded to contain the full data of the joined mesh. I don't know by how much, but a situation like this could greatly increase file size.

Hi ,

No shape keys, but a lot of the meshes have UV's which are still intact after the export to obj and reimport. I'll delete all UV data and see if that has a different result.

M.

> What would be useful to compare is the data layers (shape keys, vertex groups and attributes) of the joined mesh to the data layers of the individual parts that have been joined together. > > If, for example, each imported mesh had a uniquely named UV map, then the joined mesh would have every one of those UV maps, but each would be expanded to contain the full set of data of the joined mesh. Similarly, if one of the imported meshes had 100 shape keys, the joined mesh would also have all of those 100 shape keys, but each shape key would have expanded to contain the full data of the joined mesh. I don't know by how much, but a situation like this could greatly increase file size. Hi , No shape keys, but a lot of the meshes have UV's which are still intact after the export to obj and reimport. I'll delete all UV data and see if that has a different result. M.
Author

@Mark-Deamer-1 You seem unable to provide an example file?

Client CAD data, which I am not allow to distribute.

M.

> @Mark-Deamer-1 You seem unable to provide an example file? Client CAD data, which I am not allow to distribute. M.

What does it show you when you view the outliner in Blender File mode?

What does it show you when you view the outliner in Blender File mode?
Author

What would be useful to compare is the data layers (shape keys, vertex groups and attributes) of the joined mesh to the data layers of the individual parts that have been joined together.

If, for example, each imported mesh had a uniquely named UV map, then the joined mesh would have every one of those UV maps, but each would be expanded to contain the full set of data of the joined mesh. Similarly, if one of the imported meshes had 100 shape keys, the joined mesh would also have all of those 100 shape keys, but each shape key would have expanded to contain the full data of the joined mesh. I don't know by how much, but a situation like this could greatly increase file size.

@Mysteryem , it was exactly what you said, the UV data was duplicated on merge, hundreds of UV's per mesh and some of them 250mb ! Thank you for the suggestion and thank you everyone else' for your time.

Regards.
Mark.

> What would be useful to compare is the data layers (shape keys, vertex groups and attributes) of the joined mesh to the data layers of the individual parts that have been joined together. > > If, for example, each imported mesh had a uniquely named UV map, then the joined mesh would have every one of those UV maps, but each would be expanded to contain the full set of data of the joined mesh. Similarly, if one of the imported meshes had 100 shape keys, the joined mesh would also have all of those 100 shape keys, but each shape key would have expanded to contain the full data of the joined mesh. I don't know by how much, but a situation like this could greatly increase file size. @Mysteryem , it was exactly what you said, the UV data was duplicated on merge, hundreds of UV's per mesh and some of them 250mb ! Thank you for the suggestion and thank you everyone else' for your time. Regards. Mark.
Blender Bot added
Status
Archived
and removed
Status
Needs Info from Developers
labels 2023-08-27 16:48:49 +02:00
Member

Thx for investiagting @Mysteryem !

I think this is probably what was the issue in #71823 and #96926 as well.

I think the situation should still be improved:

  • either limiting the amount of UV layers upon joining to 8 (as we elsewhere in the UI)
  • merging the UV layers based upon index (so merge all first uv layers of all sources into one on the destination, merge all second uv layers of all sources into a second uv layer on destination, ...) -- this could be an option on the operator
  • if the above doesnt work out for some reason, at least spit out a warning in the UI that more than 8 UV layers have been created

I will open another issue for this shortly...

Thx for investiagting @Mysteryem ! I think this is probably what was the issue in #71823 and #96926 as well. I think the situation should still be improved: - either limiting the amount of UV layers upon joining to 8 (as we elsewhere in the UI) - merging the UV layers based upon index (so merge all first uv layers of all sources into one on the destination, merge all second uv layers of all sources into a second uv layer on destination, ...) -- this could be an option on the operator - if the above doesnt work out for some reason, at least spit out a warning in the UI that more than 8 UV layers have been created I will open another issue for this shortly...
Member

I opened #111608 for this.

I opened #111608 for this.
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset System
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Code Documentation
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Viewport & EEVEE
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Asset Browser Project
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Module
Viewport & EEVEE
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Severity
High
Severity
Low
Severity
Normal
Severity
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
6 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#111564
No description provided.