-
Notifications
You must be signed in to change notification settings - Fork 8
/
main_ci.m
40 lines (24 loc) · 1.15 KB
/
main_ci.m
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
32
33
34
35
36
% MAIN_CI Tests and compares multiple automated segmentation methods for continuous integration.
% Author: Timothy Sipkens, 2020-8-25
%=========================================================================%
% Load online image.
[Imgs, imgs, pixsizes] = tools.load_imgs( ...
'https://raw.githubusercontent.com/tsipkens/atems/master/images/201805A_A6_004.TIF'); % load first image in 'images' folder
fname = {Imgs.fname};
%== Run thresholding for all of the images ===============================%
% k-means
imgs_km = agg.seg_kmeans(Imgs);
Aggs = agg.analyze_binary(imgs_km, pixsizes, imgs, fname, [], 0);
% New Otsu
imgs_otsu = agg.seg_otsu(imgs, pixsizes);
agg.analyze_binary(imgs_otsu, pixsizes, imgs, fname, [], 0);
% Original Otsu
imgs_otsu_o = agg.seg_otsu_orig(imgs, pixsizes);
agg.analyze_binary(imgs_otsu_o, pixsizes, imgs, fname, [], 0);
%=========================================================================%
%== Primary particle sizing ==============================================%
pp.edm_sbs(Aggs);
pp.hough_kook2(Aggs, 0);
pp.pcm(Aggs);
pp.edm_ws(Aggs, [], 0);
%=========================================================================%