polyTEM.statistics.overlap_density

polyTEM.statistics.overlap_density(stack_list1, stack_list2, reference='', xstal_area='all', savefile='', prematched=False)

Compares overlap density of CrystalStacks peaks. Density defined by: (Area containing crystalline signal from list1 AND list2) / (Reference Area)

INPUTS: stack_list1 = list of CrystalStack objects stack_list2 = list of CrystalStack objects reference = determines reference area. options are None or ‘sum’

‘’ = no reference area used imples that the reference area is the area of the full sized image ‘sum’ = uses the total crystalline area from list1 and list2 as the reference.

xstal_area = defines what type of crystalline area

‘all’ = anywhere (x,y) location that had fft peak, uses crystalStack.sparse_peaks_mat for coo ‘domains’ = only (x,y) locations that belong to a cluster, uses crystalStack.peaks_df for coo ‘aligned’ = only clusters that have aligned orientations between list 1 and list 2, modifies crystalStack.peaks_df for coo.

use with NO reference, result is then directly proportional to amount of interfacial area in the film

– OUTPUTS: if overlap_density value is 0, then error occured. checking logging.ERROR