co

Covariance and Coherence Matrix Estimation
from matplotlib import pyplot as plt
import zarr
import colorcet
import moraine.cli as mc
from moraine.utils_ import is_cuda_available

source

emperical_co_pc

 emperical_co_pc (rslc:str, is_shp_dir:str, gix:str, coh_dir:str,
                  image_pairs:numpy.ndarray=None, chunks:int=None,
                  cuda:bool=False, processes=None, n_workers=None,
                  threads_per_worker=None, rmm_pool_size=0.9,
                  **dask_cluster_arg)

estimate emperical coherence matrix on point cloud data.

Type Default Details
rslc str input: rslc stack, shape (nlines, width, nimages)
is_shp_dir str input: directory for bool array indicating the SHPs of pc
gix str input: bool array indicating pc, shape (2, n_points)
coh_dir str output: directory that hold complex coherence matrix for pc
image_pairs ndarray None input: image pairs (element in the coherence matrix) to be calculated, all image pairs by default
chunks int None parallel processing azimuth/range chunk size, optional. Default: rslc.chunks[:2]
cuda bool False if use cuda for processing, false by default
processes NoneType None use process for dask worker over thread, the default is False for cpu, only applied if cuda==False
n_workers NoneType None number of dask worker, the default is 1 for cpu, number of GPU for cuda
threads_per_worker NoneType None number of threads per dask worker, the default is 2 for cpu, only applied if cuda==False
rmm_pool_size float 0.9 set the rmm pool size, only applied when cuda==True
dask_cluster_arg VAR_KEYWORD
logger = mc.get_logger()
ds_can_gix = './shp/ds_can_gix.zarr'
is_shp = './shp/is_shp.zarr/'
ds_can_is_shp_dir = './co/ds_can_is_shp'
ds_can_key = './co/ds_can_key.zarr'
mc.ras2pc_ras_chunk(ds_can_gix,is_shp,ds_can_is_shp_dir,ds_can_key,chunks=(1000,1000))
2025-06-24 21:46:16 - log_args - INFO - running function: ras2pc_ras_chunk
2025-06-24 21:46:16 - log_args - INFO - fetching args:
2025-06-24 21:46:16 - log_args - INFO - gix = './shp/ds_can_gix.zarr'
2025-06-24 21:46:16 - log_args - INFO - ras = './shp/is_shp.zarr/'
2025-06-24 21:46:16 - log_args - INFO - pc = './co/ds_can_is_shp'
2025-06-24 21:46:16 - log_args - INFO - key = './co/ds_can_key.zarr'
2025-06-24 21:46:16 - log_args - INFO - chunks = (1000, 1000)
2025-06-24 21:46:16 - log_args - INFO - processes = False
2025-06-24 21:46:16 - log_args - INFO - n_workers = 1
2025-06-24 21:46:16 - log_args - INFO - threads_per_worker = 1
2025-06-24 21:46:16 - log_args - INFO - dask_cluster_arg = {}
2025-06-24 21:46:16 - log_args - INFO - fetching args done.
2025-06-24 21:46:16 - zarr_info - INFO - ./shp/ds_can_gix.zarr zarray shape, chunks, dtype: (732727, 2), (100000, 1), int32
2025-06-24 21:46:16 - ras2pc_ras_chunk - INFO - loading gix into memory.
2025-06-24 21:46:16 - ras2pc_ras_chunk - INFO - convert gix to the order of ras chunk
2025-06-24 21:46:23 - ras2pc_ras_chunk - INFO - save key
2025-06-24 21:46:23 - ras2pc_ras_chunk - INFO - starting dask local cluster.
2025-06-24 21:46:24 - ras2pc_ras_chunk - INFO - dask local cluster started.
2025-06-24 21:46:24 - dask_cluster_info - INFO - dask cluster: LocalCluster(dashboard_link='http://10.211.48.18:8787/status', workers=1, threads=1, memory=1.46 TiB)
2025-06-24 21:46:24 - ras2pc_ras_chunk - INFO - start to slice on ./shp/is_shp.zarr/
2025-06-24 21:46:24 - zarr_info - INFO - ./shp/is_shp.zarr/ zarray shape, chunks, dtype: (2500, 1834, 11, 11), (1000, 1000, 1, 1), bool
2025-06-24 21:46:24 - darr_info - INFO - ras dask array shape, chunksize, dtype: (2500, 1834, 11, 11), (1000, 1000, 11, 11), bool
2025-06-24 21:46:24 - darr_info - INFO - pc dask array shape, chunksize, dtype: (732727, 11, 11), (201403, 11, 11), bool
2025-06-24 21:46:24 - ras2pc_ras_chunk - INFO - saving to co/ds_can_is_shp.
2025-06-24 21:46:24 - ras2pc_ras_chunk - INFO - computing graph setted. doing all the computing.
2025-06-24 21:46:27 - ras2pc_ras_chunk - INFO - computing finished.
2025-06-24 21:46:27 - ras2pc_ras_chunk - INFO - dask cluster closed.
rslc = './raw/rslc.zarr'
ds_can_coh_dir = './co/ds_can_coh'
emperical_co_pc(rslc,ds_can_is_shp_dir,ds_can_gix,ds_can_coh_dir,chunks=(1000,1000),cuda=False)
2025-06-24 21:46:27 - log_args - INFO - running function: emperical_co_pc
2025-06-24 21:46:27 - log_args - INFO - fetching args:
2025-06-24 21:46:27 - log_args - INFO - rslc = './raw/rslc.zarr'
2025-06-24 21:46:27 - log_args - INFO - is_shp_dir = './co/ds_can_is_shp'
2025-06-24 21:46:27 - log_args - INFO - gix = './shp/ds_can_gix.zarr'
2025-06-24 21:46:27 - log_args - INFO - coh_dir = './co/ds_can_coh'
2025-06-24 21:46:27 - log_args - INFO - image_pairs = None
2025-06-24 21:46:27 - log_args - INFO - chunks = (1000, 1000)
2025-06-24 21:46:27 - log_args - INFO - cuda = False
2025-06-24 21:46:27 - log_args - INFO - processes = None
2025-06-24 21:46:27 - log_args - INFO - n_workers = None
2025-06-24 21:46:27 - log_args - INFO - threads_per_worker = None
2025-06-24 21:46:27 - log_args - INFO - rmm_pool_size = 0.9
2025-06-24 21:46:27 - log_args - INFO - dask_cluster_arg = {}
2025-06-24 21:46:27 - log_args - INFO - fetching args done.
2025-06-24 21:46:27 - zarr_info - INFO - ./raw/rslc.zarr zarray shape, chunks, dtype: (2500, 1834, 17), (1000, 1000, 1), complex64
2025-06-24 21:46:27 - emperical_co_pc - INFO - azimuth window size and half azimuth window size: 11, 5
2025-06-24 21:46:27 - emperical_co_pc - INFO - range window size and half range window size: 11, 5
2025-06-24 21:46:27 - emperical_co_pc - INFO - parallel processing azimuth chunk size: 1000
2025-06-24 21:46:27 - emperical_co_pc - INFO - parallel processing range chunk size: 1000
2025-06-24 21:46:27 - zarr_info - INFO - ./shp/ds_can_gix.zarr zarray shape, chunks, dtype: (732727, 2), (100000, 1), int32
2025-06-24 21:46:27 - emperical_co_pc - INFO - loading gix into memory.
2025-06-24 21:46:27 - emperical_co_pc - INFO - convert gix to the order of ras chunk
2025-06-24 21:46:28 - emperical_co_pc - INFO - starting dask cluster.
2025-06-24 21:46:28 - emperical_co_pc - INFO - dask cluster started.
2025-06-24 21:46:28 - dask_cluster_info - INFO - dask cluster: LocalCluster(dashboard_link='http://10.211.48.18:8787/status', workers=1, threads=2, memory=1.46 TiB)
2025-06-24 21:46:28 - darr_info - INFO - rslc_overlap dask array shape, chunksize, dtype: (2520, 1844, 17), (1010, 1005, 17), complex64
2025-06-24 21:46:28 - darr_info - INFO - gix in ras chunk order dask array shape, chunksize, dtype: (732727, 2), (201403, 2), int32
2025-06-24 21:46:28 - emperical_co_pc - INFO - estimating coherence matrix chunk by chunk.
2025-06-24 21:46:28 - darr_info - INFO - is_shp for chunk 0 dask array shape, chunksize, dtype: (201097, 11, 11), (201097, 11, 11), bool
2025-06-24 21:46:28 - darr_info - INFO - coh for chunk 0 dask array shape, chunksize, dtype: (201097, 136), (201097, 136), complex64
2025-06-24 21:46:28 - emperical_co_pc - INFO - saving coh for chunk 0
2025-06-24 21:46:28 - zarr_info - INFO - co/ds_can_coh/0.zarr zarray shape, chunks, dtype: (201097, 136), (201097, 1), complex64
2025-06-24 21:46:28 - darr_info - INFO - is_shp for chunk 1 dask array shape, chunksize, dtype: (137562, 11, 11), (137562, 11, 11), bool
2025-06-24 21:46:28 - darr_info - INFO - coh for chunk 1 dask array shape, chunksize, dtype: (137562, 136), (137562, 136), complex64
2025-06-24 21:46:28 - emperical_co_pc - INFO - saving coh for chunk 1
2025-06-24 21:46:28 - zarr_info - INFO - co/ds_can_coh/1.zarr zarray shape, chunks, dtype: (137562, 136), (137562, 1), complex64
2025-06-24 21:46:28 - darr_info - INFO - is_shp for chunk 2 dask array shape, chunksize, dtype: (201403, 11, 11), (201403, 11, 11), bool
2025-06-24 21:46:28 - darr_info - INFO - coh for chunk 2 dask array shape, chunksize, dtype: (201403, 136), (201403, 136), complex64
2025-06-24 21:46:28 - emperical_co_pc - INFO - saving coh for chunk 2
2025-06-24 21:46:28 - zarr_info - INFO - co/ds_can_coh/2.zarr zarray shape, chunks, dtype: (201403, 136), (201403, 1), complex64
2025-06-24 21:46:28 - darr_info - INFO - is_shp for chunk 3 dask array shape, chunksize, dtype: (73518, 11, 11), (73518, 11, 11), bool
2025-06-24 21:46:28 - darr_info - INFO - coh for chunk 3 dask array shape, chunksize, dtype: (73518, 136), (73518, 136), complex64
2025-06-24 21:46:28 - emperical_co_pc - INFO - saving coh for chunk 3
2025-06-24 21:46:28 - zarr_info - INFO - co/ds_can_coh/3.zarr zarray shape, chunks, dtype: (73518, 136), (73518, 1), complex64
2025-06-24 21:46:28 - darr_info - INFO - is_shp for chunk 4 dask array shape, chunksize, dtype: (78445, 11, 11), (78445, 11, 11), bool
2025-06-24 21:46:28 - darr_info - INFO - coh for chunk 4 dask array shape, chunksize, dtype: (78445, 136), (78445, 136), complex64
2025-06-24 21:46:28 - emperical_co_pc - INFO - saving coh for chunk 4
2025-06-24 21:46:28 - zarr_info - INFO - co/ds_can_coh/4.zarr zarray shape, chunks, dtype: (78445, 136), (78445, 1), complex64
2025-06-24 21:46:28 - darr_info - INFO - is_shp for chunk 5 dask array shape, chunksize, dtype: (40702, 11, 11), (40702, 11, 11), bool
2025-06-24 21:46:28 - darr_info - INFO - coh for chunk 5 dask array shape, chunksize, dtype: (40702, 136), (40702, 136), complex64
2025-06-24 21:46:28 - emperical_co_pc - INFO - saving coh for chunk 5
2025-06-24 21:46:28 - zarr_info - INFO - co/ds_can_coh/5.zarr zarray shape, chunks, dtype: (40702, 136), (40702, 1), complex64
2025-06-24 21:46:28 - emperical_co_pc - INFO - computing graph setted. doing all the computing.
2025-06-24 21:46:32 - emperical_co_pc - INFO - computing finished.s
2025-06-24 21:46:32 - emperical_co_pc - INFO - dask cluster closed.
CPU times: user 39.8 s, sys: 4.59 s, total: 44.4 s
Wall time: 4.09 s
if is_cuda_available():
    emperical_co_pc(rslc,ds_can_is_shp_dir,ds_can_gix,ds_can_coh_dir,chunks=(1000,1000),cuda=True)
2025-06-24 21:46:32 - log_args - INFO - running function: emperical_co_pc
2025-06-24 21:46:32 - log_args - INFO - fetching args:
2025-06-24 21:46:32 - log_args - INFO - rslc = './raw/rslc.zarr'
2025-06-24 21:46:32 - log_args - INFO - is_shp_dir = './co/ds_can_is_shp'
2025-06-24 21:46:32 - log_args - INFO - gix = './shp/ds_can_gix.zarr'
2025-06-24 21:46:32 - log_args - INFO - coh_dir = './co/ds_can_coh'
2025-06-24 21:46:32 - log_args - INFO - image_pairs = None
2025-06-24 21:46:32 - log_args - INFO - chunks = (1000, 1000)
2025-06-24 21:46:32 - log_args - INFO - cuda = True
2025-06-24 21:46:32 - log_args - INFO - processes = None
2025-06-24 21:46:32 - log_args - INFO - n_workers = None
2025-06-24 21:46:32 - log_args - INFO - threads_per_worker = None
2025-06-24 21:46:32 - log_args - INFO - rmm_pool_size = 0.9
2025-06-24 21:46:32 - log_args - INFO - dask_cluster_arg = {}
2025-06-24 21:46:32 - log_args - INFO - fetching args done.
2025-06-24 21:46:32 - zarr_info - INFO - ./raw/rslc.zarr zarray shape, chunks, dtype: (2500, 1834, 17), (1000, 1000, 1), complex64
2025-06-24 21:46:32 - emperical_co_pc - INFO - azimuth window size and half azimuth window size: 11, 5
2025-06-24 21:46:32 - emperical_co_pc - INFO - range window size and half range window size: 11, 5
2025-06-24 21:46:32 - emperical_co_pc - INFO - parallel processing azimuth chunk size: 1000
2025-06-24 21:46:32 - emperical_co_pc - INFO - parallel processing range chunk size: 1000
2025-06-24 21:46:32 - zarr_info - INFO - ./shp/ds_can_gix.zarr zarray shape, chunks, dtype: (732727, 2), (100000, 1), int32
2025-06-24 21:46:32 - emperical_co_pc - INFO - loading gix into memory.
2025-06-24 21:46:32 - emperical_co_pc - INFO - convert gix to the order of ras chunk
2025-06-24 21:46:32 - emperical_co_pc - INFO - starting dask cluster.
2025-06-24 21:46:38 - emperical_co_pc - INFO - dask cluster started.
2025-06-24 21:46:38 - dask_cluster_info - INFO - dask cluster: LocalCUDACluster(dashboard_link='http://127.0.0.1:8787/status', workers=8, threads=8, memory=1.46 TiB)
2025-06-24 21:46:38 - darr_info - INFO - rslc_overlap dask array shape, chunksize, dtype: (2520, 1844, 17), (1010, 1005, 17), complex64
2025-06-24 21:46:38 - darr_info - INFO - gix in ras chunk order dask array shape, chunksize, dtype: (732727, 2), (201403, 2), int32
2025-06-24 21:46:39 - emperical_co_pc - INFO - estimating coherence matrix chunk by chunk.
2025-06-24 21:46:39 - darr_info - INFO - is_shp for chunk 0 dask array shape, chunksize, dtype: (201097, 11, 11), (201097, 11, 11), bool
2025-06-24 21:46:39 - darr_info - INFO - coh for chunk 0 dask array shape, chunksize, dtype: (201097, 136), (201097, 136), complex64
2025-06-24 21:46:39 - emperical_co_pc - INFO - saving coh for chunk 0
2025-06-24 21:46:39 - zarr_info - INFO - co/ds_can_coh/0.zarr zarray shape, chunks, dtype: (201097, 136), (201097, 1), complex64
2025-06-24 21:46:39 - darr_info - INFO - is_shp for chunk 1 dask array shape, chunksize, dtype: (137562, 11, 11), (137562, 11, 11), bool
2025-06-24 21:46:39 - darr_info - INFO - coh for chunk 1 dask array shape, chunksize, dtype: (137562, 136), (137562, 136), complex64
2025-06-24 21:46:39 - emperical_co_pc - INFO - saving coh for chunk 1
2025-06-24 21:46:39 - zarr_info - INFO - co/ds_can_coh/1.zarr zarray shape, chunks, dtype: (137562, 136), (137562, 1), complex64
2025-06-24 21:46:39 - darr_info - INFO - is_shp for chunk 2 dask array shape, chunksize, dtype: (201403, 11, 11), (201403, 11, 11), bool
2025-06-24 21:46:39 - darr_info - INFO - coh for chunk 2 dask array shape, chunksize, dtype: (201403, 136), (201403, 136), complex64
2025-06-24 21:46:39 - emperical_co_pc - INFO - saving coh for chunk 2
2025-06-24 21:46:39 - zarr_info - INFO - co/ds_can_coh/2.zarr zarray shape, chunks, dtype: (201403, 136), (201403, 1), complex64
2025-06-24 21:46:39 - darr_info - INFO - is_shp for chunk 3 dask array shape, chunksize, dtype: (73518, 11, 11), (73518, 11, 11), bool
2025-06-24 21:46:39 - darr_info - INFO - coh for chunk 3 dask array shape, chunksize, dtype: (73518, 136), (73518, 136), complex64
2025-06-24 21:46:39 - emperical_co_pc - INFO - saving coh for chunk 3
2025-06-24 21:46:39 - zarr_info - INFO - co/ds_can_coh/3.zarr zarray shape, chunks, dtype: (73518, 136), (73518, 1), complex64
2025-06-24 21:46:39 - darr_info - INFO - is_shp for chunk 4 dask array shape, chunksize, dtype: (78445, 11, 11), (78445, 11, 11), bool
2025-06-24 21:46:39 - darr_info - INFO - coh for chunk 4 dask array shape, chunksize, dtype: (78445, 136), (78445, 136), complex64
2025-06-24 21:46:39 - emperical_co_pc - INFO - saving coh for chunk 4
2025-06-24 21:46:39 - zarr_info - INFO - co/ds_can_coh/4.zarr zarray shape, chunks, dtype: (78445, 136), (78445, 1), complex64
2025-06-24 21:46:39 - darr_info - INFO - is_shp for chunk 5 dask array shape, chunksize, dtype: (40702, 11, 11), (40702, 11, 11), bool
2025-06-24 21:46:39 - darr_info - INFO - coh for chunk 5 dask array shape, chunksize, dtype: (40702, 136), (40702, 136), complex64
2025-06-24 21:46:39 - emperical_co_pc - INFO - saving coh for chunk 5
2025-06-24 21:46:39 - zarr_info - INFO - co/ds_can_coh/5.zarr zarray shape, chunks, dtype: (40702, 136), (40702, 1), complex64
2025-06-24 21:46:39 - emperical_co_pc - INFO - computing graph setted. doing all the computing.
2025-06-24 21:46:41 - emperical_co_pc - INFO - computing finished.s
2025-06-24 21:46:45,745 - distributed.nanny - WARNING - Worker process still alive after 3.1999995422363288 seconds, killing
2025-06-24 21:46:45 - emperical_co_pc - INFO - dask cluster closed.
CPU times: user 831 ms, sys: 1.57 s, total: 2.41 s
Wall time: 13.7 s
ds_can_coh = './co/ds_can_coh.zarr'
chunks = zarr.open(ds_can_gix,'r').chunks[0]
mc.pc_concat(ds_can_coh_dir,ds_can_coh,key=ds_can_key,chunks=chunks)
2025-06-24 21:46:45 - log_args - INFO - running function: pc_concat
2025-06-24 21:46:45 - log_args - INFO - fetching args:
2025-06-24 21:46:45 - log_args - INFO - pcs = './co/ds_can_coh'
2025-06-24 21:46:45 - log_args - INFO - pc = './co/ds_can_coh.zarr'
2025-06-24 21:46:45 - log_args - INFO - key = './co/ds_can_key.zarr'
2025-06-24 21:46:45 - log_args - INFO - chunks = 100000
2025-06-24 21:46:45 - log_args - INFO - processes = False
2025-06-24 21:46:45 - log_args - INFO - n_workers = 1
2025-06-24 21:46:45 - log_args - INFO - threads_per_worker = 1
2025-06-24 21:46:45 - log_args - INFO - dask_cluster_arg = {}
2025-06-24 21:46:45 - log_args - INFO - fetching args done.
2025-06-24 21:46:45 - pc_concat - INFO - input pcs: [[Path('co/ds_can_coh/0.zarr'), Path('co/ds_can_coh/1.zarr'), Path('co/ds_can_coh/2.zarr'), Path('co/ds_can_coh/3.zarr'), Path('co/ds_can_coh/4.zarr'), Path('co/ds_can_coh/5.zarr')]]
2025-06-24 21:46:45 - pc_concat - INFO - output pc: ['./co/ds_can_coh.zarr']
2025-06-24 21:46:45 - pc_concat - INFO - load key
2025-06-24 21:46:45 - zarr_info - INFO - ./co/ds_can_key.zarr zarray shape, chunks, dtype: (732727,), (100000,), int64
2025-06-24 21:46:45 - pc_concat - INFO - starting dask local cluster.
2025-06-24 21:46:45 - pc_concat - INFO - dask local cluster started.
2025-06-24 21:46:45 - dask_cluster_info - INFO - dask cluster: LocalCluster(dashboard_link='http://10.211.48.18:8787/status', workers=1, threads=1, memory=1.46 TiB)
2025-06-24 21:46:45 - pc_concat - INFO - read pc from [Path('co/ds_can_coh/0.zarr'), Path('co/ds_can_coh/1.zarr'), Path('co/ds_can_coh/2.zarr'), Path('co/ds_can_coh/3.zarr'), Path('co/ds_can_coh/4.zarr'), Path('co/ds_can_coh/5.zarr')]
2025-06-24 21:46:45 - darr_info - INFO - concatenated pc dask array shape, chunksize, dtype: (732727, 136), (732727, 1), complex64
2025-06-24 21:46:45 - pc_concat - INFO - sort pc according to key
2025-06-24 21:46:45 - darr_info - INFO - sorted pc dask array shape, chunksize, dtype: (732727, 136), (732727, 1), complex64
2025-06-24 21:46:45 - pc_concat - INFO - save pc to ./co/ds_can_coh.zarr
2025-06-24 21:46:45 - zarr_info - INFO - ./co/ds_can_coh.zarr zarray shape, chunks, dtype: (732727, 136), (100000, 1), complex64
2025-06-24 21:46:45 - pc_concat - INFO - computing graph setted. doing all the computing.
2025-06-24 21:46:51 - pc_concat - INFO - computing finished.|  5.8s
2025-06-24 21:46:51 - pc_concat - INFO - dask cluster closed.
ds_can_coh_ave = './co/ds_can_coh_ave.zarr'
n_point = zarr.open(ds_can_coh,'r').shape[0]
mc.data_reduce(ds_can_coh,ds_can_coh_ave,map_func=np.abs,reduce_func=np.sum,post_map_func=lambda x: x/n_point)
2025-06-24 21:46:51 - log_args - INFO - running function: data_reduce
2025-06-24 21:46:51 - log_args - INFO - fetching args:
2025-06-24 21:46:51 - log_args - INFO - data_in = './co/ds_can_coh.zarr'
2025-06-24 21:46:51 - log_args - INFO - out = './co/ds_can_coh_ave.zarr'
2025-06-24 21:46:51 - log_args - INFO - map_func = <ufunc 'absolute'>
2025-06-24 21:46:51 - log_args - INFO - reduce_func = <function sum>
2025-06-24 21:46:51 - log_args - INFO - axis = 0
2025-06-24 21:46:51 - log_args - INFO - post_map_func = <function <lambda>>
2025-06-24 21:46:51 - log_args - INFO - processes = False
2025-06-24 21:46:51 - log_args - INFO - n_workers = 1
2025-06-24 21:46:51 - log_args - INFO - threads_per_worker = 1
2025-06-24 21:46:51 - log_args - INFO - dask_cluster_arg = {}
2025-06-24 21:46:51 - log_args - INFO - fetching args done.
2025-06-24 21:46:51 - zarr_info - INFO - ./co/ds_can_coh.zarr zarray shape, chunks, dtype: (732727, 136), (100000, 1), complex64
2025-06-24 21:46:51 - data_reduce - INFO - starting dask local cluster.
2025-06-24 21:46:51 - data_reduce - INFO - dask local cluster started.
2025-06-24 21:46:51 - dask_cluster_info - INFO - dask cluster: LocalCluster(dashboard_link='http://10.211.48.18:8787/status', workers=1, threads=1, memory=1.46 TiB)
2025-06-24 21:46:51 - darr_info - INFO - data_in dask array shape, chunksize, dtype: (732727, 136), (100000, 1), complex64
2025-06-24 21:46:51 - darr_info - INFO - maped_data_in dask array shape, chunksize, dtype: (732727, 136), (100000, 1), float32
2025-06-24 21:46:51 - darr_info - INFO - reduced data in every chunk dask array shape, chunksize, dtype: (8, 136), (1, 1), float32
2025-06-24 21:46:51 - data_reduce - INFO - computing graph setted. doing all the computing.
2025-06-24 21:46:55 - data_reduce - INFO - computing finished. 3.6s
2025-06-24 21:46:55 - data_reduce - INFO - dask cluster closed.
2025-06-24 21:46:55 - data_reduce - INFO - continue the reduction on reduced data over every chunk
2025-06-24 21:46:55 - data_reduce - INFO - post mapping
2025-06-24 21:46:55 - data_reduce - INFO - writing output.
2025-06-24 21:46:55 - data_reduce - INFO - done.
ds_can_coh_ave_ = mr.uncompress_coh(zarr.open(ds_can_coh_ave,'r')[:])
fig, ax = plt.subplots(1,1,figsize=(15,10))
pcm = ax.imshow(ds_can_coh_ave_,cmap=colorcet.cm.fire)
ax.set(title='Average coherence matrix',xlabel='Image Index',ylabel='Image Index')
fig.colorbar(pcm)
fig.show()