Recognition and statistical size distribution of microdomains in TEM-images of polyimide films during their processing