Savegame vs autosave size difference

Anything that prevents you from playing the game properly. Do you have issues playing for the game, downloading it or successfully running it on your computer? Let us know here.
szydas
Burner Inserter
Burner Inserter
Posts: 8
Joined: Fri Dec 09, 2022 5:19 pm
Contact:

Savegame vs autosave size difference

Post by szydas »

Hi,
where comes file size difference between savegame and autosave from? In my case it's 816 vs 730 MB files, saved one by one. Restoring game from both gives same results. So why one is much bigger than other?

Rseding91
Factorio Staff
Factorio Staff
Posts: 14150
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Savegame vs autosave size difference

Post by Rseding91 »

There is no difference in the file format between the save methods. What most likely is happening is the game is updating between the two and things in the game are changing resulting in different data being saved.
If you want to get ahold of me I'm almost always on Discord.

szydas
Burner Inserter
Burner Inserter
Posts: 8
Joined: Fri Dec 09, 2022 5:19 pm
Contact:

Re: Savegame vs autosave size difference

Post by szydas »

There is only few seconds time between both saves. How much could change in game in such liitle time span?
Zrzut ekranu 2023-02-23 144614.png
Zrzut ekranu 2023-02-23 144614.png (3.81 KiB) Viewed 2144 times

Rseding91
Factorio Staff
Factorio Staff
Posts: 14150
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Savegame vs autosave size difference

Post by Rseding91 »

Technically; anything can change between any two game ticks.

You can test it simply by going into the editor and using the editor-pause feature. Let autosave run and do a manual save.
If you want to get ahold of me I'm almost always on Discord.

DaleStan
Filter Inserter
Filter Inserter
Posts: 370
Joined: Mon Jul 09, 2018 2:40 am
Contact:

Re: Savegame vs autosave size difference

Post by DaleStan »

This looks to me like it's probably a case of different compression settings for autosaves and manual saves.

Compare the size of the decompressed saves too, and see if the difference is closer to what you expect.

szydas
Burner Inserter
Burner Inserter
Posts: 8
Joined: Fri Dec 09, 2022 5:19 pm
Contact:

Re: Savegame vs autosave size difference

Post by szydas »

Is there different setting for compression of autosaves? I thought only one setting available affects all saves, auto and manual ones.

I unpacked both files: exept descriptor files (json, preview etc) every single .dat file has different size. About 5-20% bigger are manual saves.

cbhj1
Fast Inserter
Fast Inserter
Posts: 169
Joined: Tue Apr 25, 2017 2:53 pm
Contact:

Re: Savegame vs autosave size difference

Post by cbhj1 »

The compression ratio for the game state is going to vary from tick to tick with the sheer number of entities and states within. The sea of bytes is not always going to be optimally compressed as compatibility with the algorithm waxes and wanes.

User avatar
BlueTemplar
Smart Inserter
Smart Inserter
Posts: 2900
Joined: Fri Jun 08, 2018 2:16 pm
Contact:

Re: Savegame vs autosave size difference

Post by BlueTemplar »

A hint might be that the manual (?) savegame is called «nilaus» - and since I assume you aren't Nilaus (?), there might be some difference between his Factorio (and OS ?) and yours ??

P.S.: Also, what kind of gigantic factory is this save for ?! :shock:
BobDiggity (mod-scenario-pack)

szydas
Burner Inserter
Burner Inserter
Posts: 8
Joined: Fri Dec 09, 2022 5:19 pm
Contact:

Re: Savegame vs autosave size difference

Post by szydas »

No, I am not Nilaus :) I named my save by him, because in this game I use some of his blueprints. Well, a lot. I don't know if my base is huge, now it's about 27k SPM, but a little chaotic in design. My design from begining, not savegame file from net.

FuryoftheStars
Smart Inserter
Smart Inserter
Posts: 2768
Joined: Tue Apr 25, 2017 2:01 pm
Contact:

Re: Savegame vs autosave size difference

Post by FuryoftheStars »

I think if you do as Rseding91 suggested, you'll see they're correct.

Save size.png
Save size.png (11.9 KiB) Viewed 2020 times

And really, a 27k SPM base is pretty big with a lot of moving parts. It's not hard to imagine tens of thousands of things changing in a single tick.
My Mods: Classic Factorio Basic Oil Processing | Sulfur Production from Oils | Wood to Oil Processing | Infinite Resources - Normal Yield | Tree Saplings (Redux) | Alien Biomes Tweaked | Restrictions on Artificial Tiles | New Gear Girl & HR Graphics

szydas
Burner Inserter
Burner Inserter
Posts: 8
Joined: Fri Dec 09, 2022 5:19 pm
Contact:

Re: Savegame vs autosave size difference

Post by szydas »

You are right but... if save file size would change due tick-to-tick gamestate changes it will result with random size difference: sometimes manual save and sometimes autosave should be bigger. In my case manual save is ALWAYS bigger.
I am not familiar with editor mode - a good "howto" online?

FuryoftheStars
Smart Inserter
Smart Inserter
Posts: 2768
Joined: Tue Apr 25, 2017 2:01 pm
Contact:

Re: Savegame vs autosave size difference

Post by FuryoftheStars »

There is also a setting specifically for auto save file compression. Check out "The rest" in the main menu by ctrl+alt+clicking the Settings button. Mine is set for "fast".

For editor, easiest is to just open the console (tilde (~) key) in your currently running game and type (without quotes) "/editor" (in freeplay mode you may have to do it a second time). Time will automatically pause, but autosaves will still happen at the regular intervals. Just wait for one of them to happen (you can change the interval for the tests if you like), then do a manual save.
My Mods: Classic Factorio Basic Oil Processing | Sulfur Production from Oils | Wood to Oil Processing | Infinite Resources - Normal Yield | Tree Saplings (Redux) | Alien Biomes Tweaked | Restrictions on Artificial Tiles | New Gear Girl & HR Graphics

szydas
Burner Inserter
Burner Inserter
Posts: 8
Joined: Fri Dec 09, 2022 5:19 pm
Contact:

Re: Savegame vs autosave size difference

Post by szydas »

Strange, I have only "autosave-compression-level" and "muliplayer-compression-level" :?: Autosave level is set to maximum already, as I mentioned before, I set multiplayer level also to maximeum, let's see what will happen ;)

FuryoftheStars
Smart Inserter
Smart Inserter
Posts: 2768
Joined: Tue Apr 25, 2017 2:01 pm
Contact:

Re: Savegame vs autosave size difference

Post by FuryoftheStars »

szydas wrote:
Fri Feb 24, 2023 3:54 pm
Strange, I have only "autosave-compression-level" and "muliplayer-compression-level" :?:
Yes, that's all I have, too.
szydas wrote:
Fri Feb 24, 2023 3:54 pm
Autosave level is set to maximum already
Well, that may explain it, then. If manual save uses fast, then it's going to be consistently larger as your auto-save is set to compress it as much as possible.

Maybe a feature request, then, to also give us a setting for the manual (single player) save compression? Personally, I'd rather have auto-save be fast and manual be slow and compact, but that may just be me.
My Mods: Classic Factorio Basic Oil Processing | Sulfur Production from Oils | Wood to Oil Processing | Infinite Resources - Normal Yield | Tree Saplings (Redux) | Alien Biomes Tweaked | Restrictions on Artificial Tiles | New Gear Girl & HR Graphics

Post Reply

Return to “Technical Help”