Use 'read' instead of 'append' as the file mode in Calibrator.load_raw().
[calibcant.git] / calibcant / calibrate.py
index da7e7cf10e76c83b862e0fb8ca28b0688357b23c..8a68cbe01dbf8694b49f8c5a0738ea29b5a7bf52 100644 (file)
@@ -593,7 +593,7 @@ class Calibrator (object):
     def load_raw(self, filename=None, group='/'):
         """Load results saved during `.aquire()` by bumps, etc."""
         data = {}
     def load_raw(self, filename=None, group='/'):
         """Load results saved during `.aquire()` by bumps, etc."""
         data = {}
-        with _h5py.File(filename, 'a') as f:
+        with _h5py.File(filename, 'r') as f:
             for name,loader in [('bump',_bump_load),
                                 ('temperature', _temperature_load),
                                 ('vibration', _vibration_load),
             for name,loader in [('bump',_bump_load),
                                 ('temperature', _temperature_load),
                                 ('vibration', _vibration_load),