Page History
...
2024-03-08 time consumption by the calib_jungfrau_v2 algorithm
Description
Code of calib_jungfrau_v2 is interlaces with timestamps. The list of timestamps is returned along with calibrated array.
Code Block | ||||
---|---|---|---|---|
| ||||
def calib_jungfrau_v2(det, evt, cmpars=(7,3,200,10), **kwa): """ v2 - improving performance, reduce time and memory consumption, use peds-offset constants Returns calibrated jungfrau data - gets constants - gets raw data - evaluates (code - pedestal - offset) - applys common mode correction if turned on - apply gain factor Parameters - det (psana.Detector) - Detector object - evt (psana.Event) - Event object - cmpars (tuple) - common mode parameters - cmpars[0] - algorithm # 7-for jungfrau - cmpars[1] - control bit-word 1-in rows, 2-in columns - cmpars[2] - maximal applied correction - **kwa - used here and passed to det.mask_v2 or det.mask_comb - nda_raw - if not None, substitutes evt.raw() - mbits - DEPRECATED parameter of the det.mask_comb(...) - mask - user defined mask passed as optional parameter """ t00 = time() src = det.source # - src (psana.Source) - Source object nda_raw = kwa.get('nda_raw', None) loop_segs = kwa.get('loop_segs', False) arr = det.raw(evt) if nda_raw is None else nda_raw # shape:(<npanels>, 512, 1024) dtype:uint16 if arr is None: return None t01 = time() detname = string_from_source(det.source) t02 = time() odc = cache.detcache_for_detname(detname) t03 = time() first_entry = odc is None if first_entry: odc = cache.add_detcache(det, evt) odc.cmps = det.common_mode(evt) if cmpars is None else cmpars odc.mask = det.mask_total(evt, **kwa) poff = odc.poff # 4d pedestals + offset shape:(3, 1, 512, 1024) dtype:float32 gfac = odc.gfac # 4d gain factors evaluated form gains mask = odc.mask outa = odc.outa cmps = odc.cmps t04 = time() if first_entry: logger.info('\n ====================== det.name: %s' % det.name\ +'\n detname from source: %s' % string_from_source(det.source)\ +info_ndarr(arr, '\n calib_jungfrau arr ')\ +info_ndarr(poff, '\n calib_jungfrau peds+off')\ +info_ndarr(gfac, '\n calib_jungfrau gfac')\ +info_ndarr(mask, '\n calib_jungfrau mask')\ +info_ndarr(outa, '\n calib_jungfrau outa')\ +info_ndarr(cmps, '\n calib_jungfrau common mode parameters ') +'\n loop over segments: %s' % loop_segs) if loop_segs: nsegs = arr.shape[0] shseg = arr.shape[-2:] # (512, 1024) for i in range(nsegs): arr1 = arr[i,:] mask1 = mask[i,:] gfac1 = gfac[:,i,:,:] poff1 = poff[:,i,:,:] arr1.shape = (1,) + shseg mask1.shape = (1,) + shseg gfac1.shape = (3,1,) + shseg poff1.shape = (3,1,) + shseg out1, times = calib_jungfrau_single_panel(arr1, gfac1, poff1, mask1, cmps) outa[i,:] = out1[0,:] resp = outa else: resp, times = calib_jungfrau_single_panel(arr, gfac, poff, mask, cmps) t17 = time() times = (t00, t01, t02, t03, t04) + times + (t17,) return resp, np.array(times, dtype=np.float64) def calib_jungfrau_single_panel(arr, gfac, poff, mask, cmps): """ Arrays should have a single panel shape, example for 8-panel detector arr: shape:(8, 512, 1024) size:4194304 dtype:uint16 [2906 2945 2813 2861 3093...] poff: shape:(3, 8, 512, 1024) size:12582912 dtype:float32 [2922.283 2938.098 2827.207 2855.296 3080.415...] gfac: shape:(3, 8, 512, 1024) size:12582912 dtype:float32 [0.02490437 0.02543429 0.02541406 0.02539831 0.02544083...] mask: shape:(8, 512, 1024) size:4194304 dtype:uint8 [1 1 1 1 1...] cmps: shape:(16,) size:16 dtype:float64 [ 7. 1. 100. 0. 0....] """ t05 = time() # Define bool arrays of ranges gr0 = arr < BW1 # 490 us gr1 =(arr >= BW1) & (arr<BW2) # 714 us gr2 = arr >= BW3 # 400 us t06 = time() factor = np.select((gr0, gr1, gr2), (gfac[0,:], gfac[1,:], gfac[2,:]), default=1) # 2msec t07 = time() pedoff = np.select((gr0, gr1, gr2), (poff[0,:], poff[1,:], poff[2,:]), default=0) t08 = time() # Subtract offset-corrected pedestals arrf = np.array(arr & MSK, dtype=np.float32) t09 = time() arrf -= pedoff t10 = time() if cmps is not None: mode, cormax = int(cmps[1]), cmps[2] npixmin = cmps[3] if len(cmps)>3 else 10 if mode>0: #arr1 = store.arr1 #grhg = np.select((gr0, gr1), (arr1, arr1), default=0) logger.debug(info_ndarr(gr0, 'gain group0')) logger.debug(info_ndarr(mask, 'mask')) t0_sec_cm = time() t11 = time() gmask = np.bitwise_and(gr0, mask) if mask is not None else gr0 t12 = time() #sh = (nsegs, 512, 1024) hrows = 256 #512/2 for s in range(arrf.shape[0]): t13 = time() if mode & 4: # in banks: (512/2,1024/16) = (256,64) pixels # 100 ms common_mode_2d_hsplit_nbanks(arrf[s,:hrows,:], mask=gmask[s,:hrows,:], nbanks=16, cormax=cormax, npix_min=npixmin) common_mode_2d_hsplit_nbanks(arrf[s,hrows:,:], mask=gmask[s,hrows:,:], nbanks=16, cormax=cormax, npix_min=npixmin) t14 = time() if mode & 1: # in rows per bank: 1024/16 = 64 pixels # 275 ms common_mode_rows_hsplit_nbanks(arrf[s,], mask=gmask[s,], nbanks=16, cormax=cormax, npix_min=npixmin) t15 = time() if mode & 2: # in cols per bank: 512/2 = 256 pixels # 290 ms common_mode_cols(arrf[s,:hrows,:], mask=gmask[s,:hrows,:], cormax=cormax, npix_min=npixmin) common_mode_cols(arrf[s,hrows:,:], mask=gmask[s,hrows:,:], cormax=cormax, npix_min=npixmin) logger.debug('TIME: common-mode correction time = %.6f sec' % (time()-t0_sec_cm)) t16 = time() arrf = arrf * factor if mask is None else arrf * factor * mask # gain correction return arrf, (t05, t06, t07, t08, t09, t10, t11, t12, t13, t14, t15, t16) |
...
Code Block | ||||
---|---|---|---|---|
| ||||
ana-4.0.59-py3 [dubrovin@sdfmilan204:~/LCLS/con-py3]$ mpirun -n 1 python Detector/examples/test-scaling-mpi.py 7 rank:000 cpu_num:000 size:01 [I] L0398: test-scaling-mpi.py ====================== det.name: CxiDs1.0:Jungfrau.0 detname from source: CxiDs1.0:Jungfrau.0 calib_jungfrau arr shape:(8, 512, 1024) size:4194304 dtype:uint16 [2906 2945 2813 2861 3093...] calib_jungfrau peds+off shape:(3, 8, 512, 1024) size:12582912 dtype:float32 [2922.283 2938.098 2827.207 2855.296 3080.415...] calib_jungfrau gfac shape:(3, 8, 512, 1024) size:12582912 dtype:float32 [0.02490437 0.02543429 0.02541406 0.02539831 0.02544083...] calib_jungfrau mask shape:(8, 512, 1024) size:4194304 dtype:uint8 [1 1 1 1 1...] calib_jungfrau outa shape:(8, 512, 1024) size:4194304 dtype:float32 [0. 0. 0. 0. 0....]ndarray from tuple: calib_jungfrau common mode parameters shape:(4,) size:4 dtype:int64 [ 7 7 200 10] loop over segments: True rank:000 cpu_num:000 nevt:0000 time:10.117775 [I] L0604: test-scaling-mpi.py rank:000 job 2-nd evt time:1710176925.177748 saveed in file: figs/mpi-job-2nd-evt-time.txt rank:000 cpu_num:000 nevt:0010 time:0.586269 rank:000 cpu_num:000 nevt:0020 time:0.581187 rank:000 cpu_num:000 nevt:0030 time:0.579508 rank:000 cpu_num:000 nevt:0040 time:0.566666 rank:000 cpu_num:000 nevt:0050 time:0.580894 rank:000 cpu_num:000 nevt:0060 time:0.580464 rank:000 cpu_num:000 nevt:0070 time:0.579505 rank:000 cpu_num:000 nevt:0080 time:0.582394 rank:000 cpu_num:000 nevt:0090 time:0.579650 rank:000 cpu_num:000 nevt:0100 time:0.580779 [I] L0637: test-scaling-mpi.py Summary for rank:000 job 2-nd evt time:1710176925.177748 time total (sec):65.284561 rank:000 times: shape:(100,) size:100 dtype:float64 ... QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-dubrovin' hostname:sdfmilan204 rank:000 cpu:000 cmt:8p-v7 proc time (sec) mean: 0.5819 +/- 0.0051 rms: 0.0066 +/- 0.0036 plot_figs_v2 fnprefix: figs/fig-mpi-data-8p-v7-sdfmilan204-ncores01 title: sdfmilan204 rank 000 of 001 cpu_num 000 arrts[msec]: shape:(100, 18) size:1800 dtype:float64 ... 000 1710176925.179 0.666 0.017 0.008 0.002 569.880 0.195 0.680 0.623 0.117 0.084 0.127 0.052 0.001 11.087 31.610 36.165 0.397 001 1710176925.835 0.638 0.018 0.003 0.002 571.524 0.194 0.707 0.637 0.119 0.083 0.132 0.054 0.001 11.149 31.636 35.907 0.396 002 1710176926.492 0.639 0.019 0.003 0.002 568.908 0.196 0.649 0.592 0.127 0.094 0.140 0.057 0.001 10.950 31.537 35.854 0.398 003 1710176927.147 0.633 0.019 0.003 0.002 568.563 0.201 0.649 0.601 0.117 0.083 0.130 0.056 0.001 10.769 31.551 36.225 0.401 004 1710176927.801 0.644 0.019 0.003 0.002 574.708 0.356 0.669 0.618 0.119 0.083 0.133 0.140 0.001 11.196 31.468 36.211 0.675 005 1710176928.465 1.722 0.018 0.003 0.001 568.464 0.195 0.674 0.592 0.117 0.083 0.132 0.056 0.001 11.315 31.503 35.888 0.401 006 1710176929.121 0.640 0.018 0.003 0.002 568.027 0.195 0.692 0.658 0.118 0.084 0.128 0.062 0.001 10.968 31.407 36.123 0.394 007 1710176929.775 0.638 0.023 0.012 0.002 569.959 0.192 0.603 0.678 0.118 0.083 0.130 0.056 0.001 10.919 31.392 35.939 0.395 008 1710176930.430 0.640 0.018 0.003 0.002 570.235 0.196 0.625 0.637 0.118 0.083 0.126 0.055 0.001 10.902 31.453 36.084 0.405 009 1710176931.086 0.637 0.018 0.003 0.001 572.507 0.353 0.658 0.603 0.118 0.084 0.133 0.140 0.002 11.013 31.432 37.417 0.677 010 1710176931.749 1.720 0.017 0.003 0.002 569.025 0.193 0.633 0.605 0.117 0.084 0.133 0.057 0.001 10.891 31.381 36.222 0.401 011 1710176932.405 0.635 0.017 0.003 0.001 567.340 0.194 0.634 0.612 0.125 0.083 0.127 0.056 0.001 11.194 31.417 35.845 0.399 012 1710176933.058 0.635 0.017 0.002 0.002 567.859 0.196 0.678 0.635 0.117 0.084 0.126 0.057 0.001 11.080 31.371 36.001 0.394 013 1710176933.712 0.636 0.024 0.013 0.002 566.197 0.194 0.657 0.603 0.117 0.083 0.133 0.058 0.001 11.233 31.371 36.247 0.403 014 1710176934.364 0.643 0.022 0.003 0.002 566.952 0.197 0.664 0.612 0.117 0.083 0.129 0.057 0.001 10.935 31.378 35.875 0.394 015 1710176935.016 0.635 0.018 0.003 0.002 569.362 0.510 0.626 0.861 0.127 0.083 0.154 0.136 0.001 11.003 31.729 36.294 0.671 016 1710176935.676 1.736 0.025 0.004 0.002 570.226 0.195 0.636 0.596 0.118 0.083 0.127 0.062 0.001 11.322 31.442 35.914 0.399 017 1710176936.337 0.637 0.018 0.002 0.002 567.089 0.192 0.650 0.592 0.300 0.083 0.129 0.057 0.001 11.218 31.405 35.914 0.393 018 1710176936.990 0.640 0.017 0.004 0.002 568.821 0.194 0.618 0.598 0.117 0.084 0.125 0.057 0.001 11.068 31.435 36.364 0.397 019 1710176937.645 0.642 0.017 0.003 0.002 567.523 0.196 0.665 0.636 0.119 0.083 0.127 0.057 0.001 11.117 31.384 35.998 0.395 020 1710176938.299 0.638 0.023 0.012 0.002 566.782 0.197 0.680 0.628 0.118 0.084 0.124 0.056 0.001 10.767 31.521 35.868 0.398 021 1710176938.951 0.636 0.018 0.003 0.001 565.609 0.193 0.610 0.607 0.118 0.084 0.126 0.057 0.002 11.339 31.319 36.009 0.394 022 1710176939.602 0.638 0.017 0.003 0.001 567.499 0.209 0.604 0.621 0.117 0.084 0.127 0.057 0.001 11.328 31.393 36.040 0.396 023 1710176940.256 0.635 0.019 0.004 0.002 573.105 0.353 0.679 0.609 0.118 0.091 0.127 0.141 0.001 11.096 31.372 36.344 0.681 024 1710176940.918 1.740 0.016 0.003 0.001 572.266 0.195 0.651 0.597 0.116 0.083 0.133 0.057 0.001 11.027 31.364 36.005 0.396 025 1710176941.577 0.631 0.018 0.003 0.001 567.538 0.192 0.631 0.591 0.125 0.084 0.125 0.057 0.001 11.003 31.337 35.894 0.396 026 1710176942.230 0.636 0.018 0.003 0.002 568.037 0.195 0.621 0.670 0.117 0.083 0.133 0.055 0.001 11.123 31.391 36.233 0.401 027 1710176942.884 0.636 0.018 0.003 0.001 567.989 0.193 0.635 0.677 0.127 0.084 0.126 0.056 0.001 10.962 31.390 35.895 0.398 028 1710176943.538 0.641 0.025 0.012 0.003 566.633 0.196 0.628 0.597 0.118 0.084 0.126 0.056 0.001 11.214 31.428 35.818 0.403 029 1710176944.190 0.635 0.017 0.003 0.002 565.870 0.192 0.648 0.610 0.117 0.089 0.124 0.057 0.001 11.144 31.362 35.860 0.395 030 1710176944.842 0.634 0.017 0.004 0.002 567.096 0.202 0.658 0.613 0.117 0.083 0.123 0.056 0.001 11.078 31.397 35.869 0.394 031 1710176945.494 0.629 0.018 0.003 0.001 566.641 0.195 0.649 0.607 0.118 0.083 0.133 0.057 0.001 11.119 31.346 36.274 0.401 032 1710176946.147 0.638 0.018 0.003 0.001 576.210 0.353 0.639 0.625 0.118 0.083 0.127 0.138 0.001 11.161 31.395 35.792 0.682 033 1710176946.812 1.721 0.018 0.003 0.002 567.965 0.192 0.614 0.622 0.117 0.083 0.131 0.057 0.001 11.197 31.366 35.955 0.394 034 1710176947.467 0.634 0.017 0.003 0.002 567.574 0.195 0.615 0.596 0.117 0.091 0.127 0.055 0.001 10.901 31.393 35.964 0.395 035 1710176948.120 0.635 0.017 0.003 0.001 540.194 0.195 0.662 0.509 0.100 0.070 0.107 0.050 0.001 10.365 28.301 34.414 0.394 036 1710176948.740 0.638 0.018 0.003 0.001 552.474 0.171 0.576 0.513 0.101 0.070 0.107 0.051 0.001 10.327 28.882 32.906 0.363 037 1710176949.372 0.607 0.017 0.003 0.002 547.162 0.194 0.664 0.616 0.118 0.083 0.136 0.065 0.001 10.803 31.229 35.949 0.402 038 1710176950.004 0.650 0.025 0.013 0.002 539.100 0.195 0.609 0.637 0.117 0.084 0.126 0.056 0.001 11.068 31.485 33.966 0.349 039 1710176950.627 0.606 0.016 0.002 0.002 554.036 0.169 0.542 0.518 0.105 0.071 0.120 0.065 0.001 10.410 29.793 32.797 0.351 040 1710176951.261 0.642 0.017 0.003 0.001 554.199 0.195 0.613 0.619 0.118 0.083 0.126 0.056 0.001 11.444 31.373 36.057 0.397 041 1710176951.902 0.631 0.024 0.003 0.002 570.335 0.194 0.641 0.595 0.118 0.083 0.135 0.057 0.001 10.968 31.413 35.979 0.393 042 1710176952.557 0.638 0.016 0.003 0.002 568.253 0.205 0.659 0.617 0.117 0.083 0.125 0.055 0.002 11.354 31.421 36.379 0.403 043 1710176953.212 0.636 0.017 0.003 0.002 570.688 0.349 0.694 0.612 0.127 0.084 0.125 0.137 0.001 10.998 31.364 35.868 0.677 044 1710176953.872 1.725 0.018 0.003 0.002 568.433 0.195 0.644 0.601 0.117 0.084 0.125 0.055 0.001 11.340 31.365 35.909 0.393 045 1710176954.528 0.631 0.018 0.003 0.001 566.346 0.194 0.655 0.607 0.117 0.083 0.128 0.061 0.001 11.143 31.315 35.884 0.393 046 1710176955.179 0.638 0.017 0.003 0.002 566.295 0.196 0.653 0.603 0.118 0.084 0.124 0.056 0.001 11.112 31.403 36.420 0.394 047 1710176955.832 0.632 0.017 0.004 0.002 565.378 0.193 0.613 0.597 0.117 0.088 0.128 0.056 0.001 11.151 31.322 36.042 0.398 048 1710176956.483 0.637 0.017 0.003 0.001 566.095 0.196 0.617 0.639 0.116 0.084 0.125 0.056 0.001 11.119 31.394 35.955 0.397 049 1710176957.135 0.633 0.018 0.003 0.002 567.317 0.193 0.696 0.609 0.118 0.089 0.128 0.057 0.001 11.030 31.297 35.939 0.395 050 1710176957.788 0.638 0.024 0.013 0.002 570.480 0.194 0.650 0.613 0.124 0.083 0.126 0.056 0.001 11.094 31.349 36.069 0.401 051 1710176958.444 0.634 0.017 0.003 0.001 567.719 0.195 0.686 0.591 0.117 0.083 0.132 0.057 0.001 11.028 31.395 35.928 0.394 052 1710176959.097 0.643 0.017 0.003 0.002 566.287 0.201 0.640 0.597 0.118 0.084 0.126 0.057 0.001 10.899 31.312 35.987 0.405 053 1710176959.749 0.637 0.017 0.003 0.002 567.780 0.196 0.647 0.611 0.118 0.084 0.131 0.057 0.002 10.977 31.435 35.997 0.395 054 1710176960.402 0.642 0.018 0.003 0.002 566.576 0.196 0.659 0.598 0.118 0.083 0.125 0.063 0.001 10.988 31.387 35.980 0.394 055 1710176961.055 0.627 0.017 0.003 0.002 566.366 0.194 0.659 0.613 0.118 0.084 0.135 0.056 0.001 10.914 31.310 36.169 0.396 056 1710176961.707 0.636 0.019 0.003 0.001 569.009 0.503 0.641 0.903 0.118 0.091 0.156 0.135 0.001 11.073 31.615 36.288 0.661 057 1710176962.366 1.732 0.019 0.002 0.002 570.110 0.196 0.658 0.647 0.118 0.083 0.134 0.057 0.001 11.127 35.682 35.929 0.401 058 1710176963.027 0.644 0.018 0.003 0.002 567.595 0.194 0.651 0.635 0.117 0.083 0.127 0.056 0.001 11.326 31.369 36.038 0.396 059 1710176963.681 0.628 0.019 0.002 0.002 566.851 0.194 0.634 0.625 0.118 0.084 0.128 0.055 0.001 11.123 31.468 35.948 0.393 060 1710176964.333 0.642 0.017 0.003 0.002 566.545 0.205 0.656 0.594 0.117 0.083 0.129 0.055 0.001 11.380 31.452 36.488 0.396 061 1710176964.987 0.630 0.018 0.003 0.002 567.141 0.231 0.631 0.615 0.117 0.084 0.125 0.055 0.001 11.449 31.284 35.898 0.393 062 1710176965.640 0.635 0.017 0.003 0.001 566.420 0.194 0.602 0.623 0.118 0.083 0.121 0.057 0.006 11.244 31.312 36.203 0.401 063 1710176966.292 0.636 0.018 0.003 0.001 566.424 0.196 0.646 0.604 0.119 0.084 0.127 0.056 0.001 10.810 31.245 36.966 0.411 064 1710176966.945 0.630 0.024 0.013 0.002 566.426 0.194 0.675 0.612 0.118 0.094 0.128 0.057 0.001 11.130 31.371 36.999 0.401 065 1710176967.598 0.634 0.018 0.003 0.002 569.700 0.204 0.633 0.603 0.117 0.083 0.125 0.056 0.002 11.036 31.356 36.108 0.394 066 1710176968.253 0.640 0.018 0.003 0.002 567.129 0.195 0.607 0.688 0.124 0.084 0.124 0.056 0.001 11.009 31.371 36.027 0.401 067 1710176968.906 0.633 0.018 0.003 0.002 565.612 0.203 0.671 0.599 0.116 0.083 0.125 0.056 0.001 10.705 31.379 36.182 0.396 068 1710176969.557 0.642 0.017 0.003 0.001 568.389 0.201 0.625 0.654 0.119 0.084 0.131 0.057 0.001 11.058 31.396 36.111 0.395 069 1710176970.212 0.628 0.018 0.002 0.002 566.199 0.195 0.646 0.595 0.117 0.083 0.126 0.061 0.001 10.833 31.327 36.125 0.395 070 1710176970.863 0.642 0.017 0.003 0.002 566.881 0.197 0.664 0.591 0.117 0.090 0.124 0.057 0.001 10.981 31.328 35.953 0.392 071 1710176971.516 0.628 0.017 0.003 0.002 566.241 0.194 0.659 0.633 0.118 0.084 0.123 0.062 0.001 10.926 31.365 36.098 0.394 072 1710176972.167 0.639 0.017 0.003 0.002 569.547 0.356 0.654 0.613 0.118 0.084 0.131 0.141 0.001 11.005 31.306 35.999 0.685 073 1710176972.826 1.742 0.017 0.003 0.001 568.023 0.194 0.629 0.602 0.117 0.084 0.123 0.056 0.002 10.927 31.313 35.976 0.394 074 1710176973.480 0.641 0.017 0.003 0.001 569.769 0.195 0.636 0.678 0.117 0.083 0.124 0.061 0.001 11.282 31.428 35.903 0.399 075 1710176974.136 0.636 0.017 0.003 0.002 566.796 0.194 0.653 0.627 0.117 0.084 0.124 0.073 0.002 10.784 31.387 36.141 0.393 076 1710176974.788 0.641 0.018 0.003 0.002 566.806 0.196 0.656 0.595 0.118 0.083 0.131 0.056 0.001 11.171 31.349 35.968 0.396 077 1710176975.441 0.630 0.023 0.003 0.002 567.456 0.194 0.654 0.627 0.125 0.085 0.126 0.056 0.001 11.124 31.371 36.198 0.397 078 1710176976.094 0.643 0.017 0.003 0.002 566.938 0.195 0.613 0.596 0.117 0.083 0.124 0.056 0.001 10.970 31.337 36.105 0.393 079 1710176976.747 0.631 0.017 0.003 0.002 568.831 0.194 0.609 0.648 0.118 0.083 0.125 0.055 0.001 11.077 31.336 35.977 0.397 080 1710176977.401 0.638 0.018 0.003 0.001 564.980 0.195 0.685 0.601 0.117 0.084 0.122 0.063 0.001 10.931 31.312 36.033 0.396 081 1710176978.052 0.630 0.018 0.003 0.002 566.748 0.194 0.676 0.622 0.118 0.083 0.125 0.057 0.002 11.122 31.409 36.197 0.394 082 1710176978.704 0.641 0.026 0.012 0.002 566.579 0.197 0.665 0.650 0.118 0.083 0.125 0.061 0.001 11.342 31.363 40.708 0.396 083 1710176979.362 0.630 0.017 0.003 0.002 567.053 0.203 0.644 0.600 0.118 0.083 0.126 0.056 0.001 10.994 31.350 36.342 0.396 084 1710176980.014 0.648 0.018 0.003 0.001 567.508 0.201 0.628 0.676 0.116 0.083 0.126 0.055 0.001 11.326 31.353 35.999 0.395 085 1710176980.668 0.633 0.016 0.003 0.002 566.638 0.194 0.640 0.597 0.118 0.083 0.127 0.054 0.001 11.118 31.345 35.914 0.400 086 1710176981.320 0.646 0.017 0.003 0.002 566.983 0.195 0.702 0.590 0.121 0.087 0.124 0.056 0.001 11.220 31.319 35.979 0.398 087 1710176981.973 0.634 0.017 0.003 0.001 567.545 0.195 0.602 0.595 0.118 0.084 0.124 0.057 0.001 11.417 31.365 36.243 0.405 088 1710176982.626 0.640 0.017 0.003 0.002 565.968 0.195 0.637 0.599 0.119 0.083 0.123 0.056 0.001 10.989 31.346 35.936 0.401 089 1710176983.277 0.628 0.015 0.003 0.002 566.326 0.196 0.645 0.602 0.118 0.083 0.126 0.057 0.001 10.849 31.537 36.117 0.393 090 1710176983.929 0.637 0.016 0.003 0.002 569.852 0.194 0.683 0.611 0.117 0.084 0.126 0.055 0.001 10.798 31.367 35.928 0.401 091 1710176984.584 0.631 0.017 0.002 0.001 571.955 0.352 0.689 0.596 0.117 0.084 0.131 0.139 0.001 11.187 31.335 36.047 0.682 092 1710176985.244 1.727 0.016 0.004 0.001 566.733 0.194 0.612 0.616 0.117 0.090 0.124 0.055 0.001 10.952 31.308 36.219 0.400 093 1710176985.898 0.628 0.018 0.004 0.002 566.060 0.200 0.602 0.627 0.117 0.083 0.125 0.056 0.002 11.088 32.352 36.037 0.394 094 1710176986.550 0.635 0.017 0.003 0.002 566.814 0.195 0.640 0.622 0.117 0.083 0.123 0.056 0.001 11.324 31.351 36.345 0.393 095 1710176987.202 0.629 0.017 0.003 0.002 566.586 0.194 0.652 0.672 0.117 0.083 0.131 0.057 0.001 10.958 31.435 36.180 0.401 096 1710176987.854 0.644 0.017 0.003 0.002 566.027 0.194 0.669 0.596 0.117 0.083 0.126 0.056 0.001 10.909 31.394 36.098 0.399 097 1710176988.506 0.636 0.017 0.003 0.001 566.741 0.192 0.636 0.651 0.118 0.084 0.125 0.056 0.002 11.258 31.340 35.949 0.392 098 1710176989.158 0.640 0.017 0.003 0.002 569.880 0.201 0.642 0.664 0.117 0.083 0.123 0.055 0.001 10.825 31.324 35.999 0.404 099 1710176989.813 0.628 0.016 0.003 0.001 566.983 0.202 0.645 0.596 0.118 0.083 0.124 0.056 0.001 11.322 31.347 36.264 0.399 evt t00(sec) ms: t01 t02 t03 t04 t05 t06 t07 t08 t09 t10 t11 t12 t13 t14 t15 t16 t17 job #1 median: 0.637 0.018 0.003 0.002 567.135 0.195 0.646 0.611 0.118 0.083 0.126 0.056 0.001 11.075 31.371 36.003 0.396 other other jobs job #2 median: 0.628 0.017 0.003 0.001 566.815 0.194 0.638 0.639 0.117 0.084 0.128 0.055 0.001 11.071 31.411 36.020 0.391 job #3 median: 0.628 0.016 0.003 0.001 567.021 0.194 0.689 0.601 0.118 0.084 0.125 0.055 0.001 11.060 31.398 35.948 0.395 job #4 median: 0.638 0.016 0.003 0.002 567.018 0.195 0.627 0.629 0.117 0.083 0.127 0.057 0.001 11.080 31.404 35.974 0.396 job #5 median: 0.805 0.014 0.003 0.001 567.475 0.212 0.654 0.624 0.120 0.085 0.125 0.057 0.001 11.093 31.389 35.989 0.400 |
Summary
w/o loops over panels | with loops over panels | |||||
---|---|---|---|---|---|---|
dt | meaning | array size in (512,1024) | msec | array size in (512,1024) | msec | comment |
01 | get det.raw(evt) | 8 | 0.664 | 8 | 0.638 | |
02 | get detector name from source | 0.015 | 0.016 | |||
03 | access cache object for detname | 0.003 | 0.003 | |||
04 | get peds, gfac, mask, out, cmps | 3x8 | 0.002 | 3x8 | 0.002 | |
05 | single panel begin processing | begin processing entire array | 0.001 | begin processing last panel | 567 | meaningless |
06 | make gain range indices, gr0, 1, 2 | 8 | 1.408 | 1 | 0.195 | |
07 | np.select for gain factor | 8 | 5.34 | 1 | 0.627 | |
08 | np.select for gain peds+offset | 8 | 5.00 | 1 | 0.629 | |
09 | apply mask for data bits, arr & MSK | 8 | 1.73 | 1 | 0.117 | |
10 | subtract pedestals | 8 | 1.19 | 1 | 0.083 | |
11 | massaging common mode parameters | 0.272 | 0.127 | |||
12 | apply pixel mask for gr0 | 8 | 0.674 | 1 | 0.057 | |
13 | begin loop over panels for CMC | time to work with last panel | 549 | time to work with current panel | 0.001 | meaningless |
14 | CMC in banks: (512/2,1024/16) = (256,64) | 1 | 11.2 | 1 | 11.1 | CMC always loop over panels |
15 | CMC in rows per bank: 1024/16 = 64 pixels | 1 | 31.3 | 1 | 31.4 | |
16 | CMC in cols per bank: 512/2 = 256 pixels | 1 | 35.9 | 1 | 36.0 | |
17 | Apply gain correction and mask | 8 | 2.87 | 1 | 0.40 | |
Total time per event | 8 | 576 | 8 | 582 |
- where CMC stands for common mode correction
References
- Scaling behavior of psana1 - Part 1 - det.calib method in multicore processing with mpi
- Scaling behavior of psana1 - Part 2 - test with command perf stat
...
Overview
Content Tools