Toolbox ia870 | List of Figures | Fig. 3.29 | Fig. 3.31

Figure 3.30 - Reconstruction from the quench function

Description

xxxxxx

Demo Script

 1 import numpy as np
 2 import ia870 as MT
 3 
 4 S = MT.iabinary([
 5   [0,0,0,0,0,0,0,0,0],
 6   [0,0,0,0,1,0,0,0,0],
 7   [0,0,0,1,1,1,0,0,0],
 8   [0,0,0,1,1,1,0,0,0],
 9   [0,0,1,1,1,1,1,0,0],
10   [0,1,1,1,1,1,1,1,0],
11   [0,1,1,1,1,1,1,1,0],
12   [0,1,1,1,1,1,1,1,0],
13   [0,1,1,1,1,1,1,1,0],
14   [0,1,1,1,1,1,1,1,0],
15   [0,0,0,0,0,0,0,0,0]])
16 
17 q = MT.iaskelm(S,MT.iasebox(), 'value')
18 
19 S0 = MT.iaskelmrec(MT.iagray(MT.iathreshad(q,1,1),'uint8',1),MT.iasebox())
20 S1 = MT.iaskelmrec(MT.iagray(MT.iathreshad(q,2,2),'uint8',2),MT.iasebox())
21 S2 = MT.iaskelmrec(MT.iagray(MT.iathreshad(q,3,3),'uint8',3),MT.iasebox())
22 
23 Sr = MT.iaunion(S0,S1,S2)
24 
25 #fig_a = MT.iabshow(q,S)
26 fig_b = MT.iabshow(S,S0)
27 fig_c = MT.iabshow(S,S1)
28 fig_d = MT.iabshow(S,S2)
29 fig_e = MT.iabshow(S,Sr)
30 
31 #adshow(MT.iapad(MT.ianeg(fig_a)))
32 adshow(MT.iapad(MT.ianeg(fig_b)),'(b)')
33 adshow(MT.iapad(MT.ianeg(fig_c)),'(c)')
34 adshow(MT.iapad(MT.ianeg(fig_d)),'(d)')
35 adshow(MT.iapad(MT.ianeg(fig_e)),'(e)')

(b)

(c)

(d)

(e)