code: def _openFile(self):
          
          if self.filename is not None:
              self.h5 = h5py.File(self.filename)
          else:
              return
  
          if 'bp' not in self.h5:
              self.h5.create_group('bp')
  
          if 'bps' not in self.h5:
              self.h5.create_group('bps')
  
          for bp_type in ['bp', 'bps']:
              for bp_num in self.data[bp_type]:
  
                  # Create group in case if new hdf5 file is opened
                  if bp_num not in self.h5[bp_type]:
                      self.h5[bp_type].create_group(bp_num)
  
                  # Sync data if old file is opened
                  for parameters in self.h5[bp_type][bp_num]:
                      self.data[bp_type][bp_num][parameters] = self.h5[bp_type][bp_num][parameters]
  
          if 'mask' in self.h5:
              self.mask = self.h5['mask'][:]
  
          if 'time' in self.h5:
              self.time = self.h5['time'][:]
  
          if 'num_bp' in self.h5.attrs:
              self.num_bp = self.h5.attrs['num_bp']
          else:
              self.h5.attrs['num_bp'] = self.num_bp
  
          if 'num_step' in self.h5.attrs:
              self.num_step = self.h5.attrs['num_step']
          else:
              self.h5.attrs['num_step'] = self.num_step
  
          if 'startBP' in self.h5.attrs:
              self.startBP = self.h5.attrs['startBP']
          else:
              self.h5.attrs['startBP'] = self.startBP
docs: Open the HDF5 file for reading/writing.
  
          This methad is called during the initialization of this class.