Thanks for responding. I actually forgot about this.
However i did find a solution. the problem was that some of the reference models inside our system were not being executed and some of those signals were included in the baseline (other tests execute those reference models). since there was no data for those signals it caused the issue of corrupting the entire .mat file.
Once i excluded the signals that were in those non-executed reference models the baselines saved and had good data.