-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconvert_test_mp.py
More file actions
31 lines (22 loc) · 923 Bytes
/
convert_test_mp.py
File metadata and controls
31 lines (22 loc) · 923 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
import importlib
import h5py
from timeit import default_timer as timer
import time
import DataHandlingMP as DH
importlib.reload(DH)
if __name__ == '__main__':
checkpoint_global = time.perf_counter()
# filename = '../AttoStreakSimulations/TF_train_mp_1.hdf5'
# transfer = 'reformed_TF_train_mp_1_quarter_stop.hdf5'
#filename = '../AttoStreakSimulations/TF_train_widegate_protect.hdf5'
#transfer = 'reformed_TF_train_widegate.hdf5'
filename = '../AttoStreakSimulations/TF_train_update.hdf5'
transfer = 'convert_test.hdf5'
DH.transform_2_spectra_from_mp(filename=filename, transfer=transfer)
delta_t = checkpoint_global - time.perf_counter()
print('Total Runtime was {}'.format(delta_t))
h5_file = h5py.File(transfer, 'r')
print(h5_file.keys())
for key in list(h5_file.keys()):
print('shape of {} is {}'.format(key, h5_file[key].shape))
h5_file.close()