# FIF-File 2x disk-size after first loading

**URL:** <https://mne.discourse.group/t/fif-file-2x-disk-size-after-first-loading/2866>\
**Category:** Support & Discussions\
**Created:** [March 21, 2021, 2:18pm UTC](https://mne.discourse.group/t/fif-file-2x-disk-size-after-first-loading/2866 "2021-03-21T14:18:29Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![marsipu](https://yyz2.discourse-cdn.com/free1/user_avatar/mne.discourse.group/marsipu/32/196_2.png) [@marsipu](https://mne.discourse.group/u/marsipu)\
**Post date:** [March 21, 2021, 2:18pm UTC](https://mne.discourse.group/t/fif-file-2x-disk-size-after-first-loading/2866/1 "2021-03-21T14:18:29Z")

</div>

Dear MNE-People,

when I first load Raw-Data into MNE-Python from a freshly generated FIF-File by our Neuromag122, the same unaltered Raw-Data takes 2x the space when saved to disk again.

**Does somebody has similar experience with their freshly generated data?**  
I uploaded an example file with code [here](https://heibox.uni-heidelberg.de/d/36f959bcbb6348fbb88b/).

Maybe there are some old FIFF-Data-Types in our data which get converted into larger types by default.  
**Is this mandatory to work with MNE-Python or could one somehow avoid the doubling of disksize?**  
Before I try to understand the data-structure of FIFF I wanted to ask here if somebody could give me a hint on that.

---

<div class="post-metadata">

**Author:** ![richard](https://yyz2.discourse-cdn.com/free1/user_avatar/mne.discourse.group/richard/32/15_2.png) [@richard](https://mne.discourse.group/u/richard)\
**Post date:** [March 21, 2021, 4:40pm UTC](https://mne.discourse.group/t/fif-file-2x-disk-size-after-first-loading/2866/2 "2021-03-21T16:40:37Z")

</div>

> [@marsipu](#):
>
> same unaltered Raw-Data takes 2x the space when saved to disk again.

I wonder if we might be changing the floating point precision … @agramfort?

---

<div class="post-metadata">

**Author:** ![agramfort](https://avatars.discourse-cdn.com/v4/letter/a/7c8e57/32.png) [@agramfort](https://mne.discourse.group/u/agramfort)\
**Post date:** [March 21, 2021, 6:54pm UTC](https://mne.discourse.group/t/fif-file-2x-disk-size-after-first-loading/2866/3 "2021-03-21T18:54:28Z")

</div>

See [MRG: keep orig format on save by agramfort · Pull Request #610 · mne-tools/mne-bids · GitHub](https://github.com/mne-tools/mne-bids/pull/610/files#diff-e868ae28f1323b802c1650596fa2eccad5831efc68f62bae91df1d79a0d27c92R665)

And the raw.orig\_format attribute

Alex

---

<div class="post-metadata">

**Author:** ![richard](https://yyz2.discourse-cdn.com/free1/user_avatar/mne.discourse.group/richard/32/15_2.png) [@richard](https://mne.discourse.group/u/richard)\
**Post date:** [March 21, 2021, 7:15pm UTC](https://mne.discourse.group/t/fif-file-2x-disk-size-after-first-loading/2866/5 "2021-03-21T19:15:49Z")

</div>

I tried with the script & file @marsipu supplied.

The original data format is `short`. Saving changes it to `single`.

What you want to do when saving is:

```python
raw.save(fmt=raw.orig_format)

```

This should fix the issue.

---

<div class="post-metadata">

**Author:** ![marsipu](https://yyz2.discourse-cdn.com/free1/user_avatar/mne.discourse.group/marsipu/32/196_2.png) [@marsipu](https://mne.discourse.group/u/marsipu)\
**Post date:** [March 21, 2021, 7:20pm UTC](https://mne.discourse.group/t/fif-file-2x-disk-size-after-first-loading/2866/6 "2021-03-21T19:20:11Z")

</div>

I see, thanks a lot @richard and @agramfort. I haven’t seen the parameter in raw.save(). This will save us a lot of space for the analysis in the lab.  
Is “single” still better though (because you recommend it in the docs) or does it make no difference if the data was generated with e.g. “short”?

---

<div class="post-metadata">

**Author:** ![agramfort](https://avatars.discourse-cdn.com/v4/letter/a/7c8e57/32.png) [@agramfort](https://mne.discourse.group/u/agramfort)\
**Post date:** [March 21, 2021, 8:13pm UTC](https://mne.discourse.group/t/fif-file-2x-disk-size-after-first-loading/2866/7 "2021-03-21T20:13:33Z")

</div>

I doubt it makes any difference yes.

Alex
