crystals, cameras, and chemical engineering: new tools for ...jbr · crystals, cameras, and...
TRANSCRIPT
Crystals, Cameras, and Chemical Engineering: NewTools for Monitoring Particulate Processes
Paul A. Larsen and James B. Rawlings
Department of Chemical and Biological EngineeringUniversity of Wisconsin–Madison
CBE Department Seminar – May 10, 2007
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 1 / 31
Process understanding through imaging
Examples from UW-CBE
Abbott, de Pablo, Palecek groups: Polarized and fluorescence microscopy toinvestigate stem cell cultures on liquid crystal interfaces.
Kuech and Nealey groups: SEM imaging to characterize size distributionand number density of quantum dot arrays.
Yin group: Quantifying viral propagation rates.
de Pablo and Graham groups: Flourescence microscopy to characterizeconfined DNA molecules.
quantum dots confined DNA virus infection
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 2 / 31
Extracting information from images
Segmentation: Separating objects of interest from the background
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 3 / 31
Extracting information from images
Segmentation: Separating objects of interest from the background
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 3 / 31
Challenges for automatic image segmentation
Challenges for thresholding andedge detection-based methods:1
Non-uniform color/intensity.
Poorly-defined outline.
Challenges for template-matching:
Non-uniform size and shape.
Random orientation in 3-Dspace.
Other challenges:
Motion blur, out-of-focus blur.
Agglomeration, attrition,breakage.
1Calderon De Anda, Wang andRoberts, ChE Sci, 2005
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 4 / 31
Challenges for automatic image segmentation
Challenges for thresholding andedge detection-based methods:1
Non-uniform color/intensity.
Poorly-defined outline.
Challenges for template-matching:
Non-uniform size and shape.
Random orientation in 3-Dspace.
Other challenges:
Motion blur, out-of-focus blur.
Agglomeration, attrition,breakage.
1Calderon De Anda, Wang andRoberts, ChE Sci, 2005
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 4 / 31
Challenges for automatic image segmentation
Challenges for thresholding andedge detection-based methods:1
Non-uniform color/intensity.
Poorly-defined outline.
Challenges for template-matching:
Non-uniform size and shape.
Random orientation in 3-Dspace.
Other challenges:
Motion blur, out-of-focus blur.
Agglomeration, attrition,breakage.
1Calderon De Anda, Wang andRoberts, ChE Sci, 2005
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 4 / 31
Challenges for automatic image segmentation
Challenges for thresholding andedge detection-based methods:1
Non-uniform color/intensity.
Poorly-defined outline.
Challenges for template-matching:
Non-uniform size and shape.
Random orientation in 3-Dspace.
Other challenges:
Motion blur, out-of-focus blur.
Agglomeration, attrition,breakage.
1Calderon De Anda, Wang andRoberts, ChE Sci, 2005
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 4 / 31
SHARC: 2-D model-based image analysis for needles2,3
Original image
Linear feature detection Collinearity identification
Parallelism identification Cluster properties
2Larsen, Rawlings, and Ferrier, ChE Sci, 20063Patent filed by WARF, P05340US
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 5 / 31
SHARC: 2-D model-based image analysis for needles2,3
Original image Linear feature detection
Collinearity identification
Parallelism identification Cluster properties
2Larsen, Rawlings, and Ferrier, ChE Sci, 20063Patent filed by WARF, P05340US
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 5 / 31
SHARC: 2-D model-based image analysis for needles2,3
Original image Linear feature detection Collinearity identification
Parallelism identification Cluster properties
2Larsen, Rawlings, and Ferrier, ChE Sci, 20063Patent filed by WARF, P05340US
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 5 / 31
SHARC: 2-D model-based image analysis for needles2,3
Original image Linear feature detection Collinearity identification
Parallelism identification
Cluster properties
2Larsen, Rawlings, and Ferrier, ChE Sci, 20063Patent filed by WARF, P05340US
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 5 / 31
SHARC: 2-D model-based image analysis for needles2,3
Original image Linear feature detection Collinearity identification
Parallelism identification Cluster properties
2Larsen, Rawlings, and Ferrier, ChE Sci, 20063Patent filed by WARF, P05340US
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 5 / 31
M-SHARC: 3-D models for more complex shapes 4,5
Parameterized, wireframe model.
Viewpoint-invariant groups used as cues for location and size ofcrystals in image.
t
t
h
y
x
z
w
w
Junction Parallel pair
Symmetric pair Arrow
4Larsen, Rawlings, and Ferrier, ChE Sci, 20075Patent filed by WARF, P06449US
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 6 / 31
M-SHARC: 3-D models for more complex shapes 4,5
Parameterized, wireframe model.Viewpoint-invariant groups used as cues for location and size ofcrystals in image.
t
t
h
y
x
z
w
w
Junction Parallel pair
Symmetric pair Arrow4Larsen, Rawlings, and Ferrier, ChE Sci, 20075Patent filed by WARF, P06449US
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 6 / 31
M-SHARC example: α-glycine crystal
(a) Original image
(b) Linear features (c) Salient line group
(d) Model initialization (e) Further matches (f) Optimized Fit
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 7 / 31
M-SHARC example: α-glycine crystal
(a) Original image (b) Linear features
(c) Salient line group
(d) Model initialization (e) Further matches (f) Optimized Fit
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 7 / 31
M-SHARC example: α-glycine crystal
(a) Original image (b) Linear features (c) Salient line group
(d) Model initialization (e) Further matches (f) Optimized Fit
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 7 / 31
M-SHARC example: α-glycine crystal
(a) Original image (b) Linear features (c) Salient line group
(d) Model initialization
(e) Further matches (f) Optimized Fit
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 7 / 31
M-SHARC example: α-glycine crystal
(a) Original image (b) Linear features (c) Salient line group
(d) Model initialization (e) Further matches
(f) Optimized Fit
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 7 / 31
M-SHARC example: α-glycine crystal
(a) Original image (b) Linear features (c) Salient line group
(d) Model initialization (e) Further matches (f) Optimized Fit
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 7 / 31
Low solids concentration
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 8 / 31
Low solids concentration
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 8 / 31
Medium solids concentration
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 9 / 31
Medium solids concentration
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 9 / 31
High solids concentration
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 10 / 31
High solids concentration
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 10 / 31
What we want to measure
Crystal shape
Needles glycine, α polymorph glycine, γ polymorph
Particle size distribution (PSD)
0 100 200 300 400 500
num
ber
dens
ity,
[1/m
m3]
particle length, L, [µm]
PSD
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 11 / 31
What we want to measure
Crystal shape
Needles glycine, α polymorph glycine, γ polymorph
Particle size distribution (PSD)
0 100 200 300 400 500
num
ber
dens
ity,
[1/m
m3]
particle length, L, [µm]
PSD
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 11 / 31
PSD estimation: definitions
ntot : Total number ofparticles
V : Total system volume
ni : Total number of particlesin size class i
ρi = ni/V : PSD, number ofparticles of size class i perunit volume of crystallizer.
0 100 200 300 400 500
num
ber
dens
ity,
[1/m
m3]
particle length, L, [µm]
PSD
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 12 / 31
PSD estimation: definitions
ntot : Total number ofparticles
V : Total system volume
ni : Total number of particlesin size class i
ρi = ni/V : PSD, number ofparticles of size class i perunit volume of crystallizer.
0 100 200 300 400 500
num
ber
dens
ity,
[1/m
m3]
particle length, L, [µm]
PSD
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 12 / 31
PSD estimation: definitions
ntot : Total number ofparticles
V : Total system volume
ni : Total number of particlesin size class i
ρi = ni/V : PSD, number ofparticles of size class i perunit volume of crystallizer.
0 100 200 300 400 500
num
ber
dens
ity,
[1/m
m3]
particle length, L, [µm]
PSD
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 12 / 31
PSD estimation: definitions
ntot : Total number ofparticles
V : Total system volume
ni : Total number of particlesin size class i
ρi = ni/V : PSD, number ofparticles of size class i perunit volume of crystallizer.
0 100 200 300 400 500
num
ber
dens
ity,
[1/m
m3]
particle length, L, [µm]
PSD a
b
d
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 12 / 31
Sampling bias by occlusion and orientation effects
Occlusion effects
Orientation effects
Projected particle lengths are less than true lengths unless particles areoriented in the plane perpendicular to camera’s optical axis.
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 13 / 31
Sampling bias by occlusion and orientation effects
Occlusion effects
Orientation effects
Projected particle lengths are less than true lengths unless particles areoriented in the plane perpendicular to camera’s optical axis.
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 13 / 31
Sampling bias by edge effects
“Clean tile” and the Buffon-Laplace needle problem
a a a
b
b
b
clean
Double
Intersection
Single
Intersection
Solomon,H., Geometric Probability, SIAM 1978
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 14 / 31
Result of ignoring edge effects
PSD estimated by counting non-border particles
Uniform distribution Normal distribution
0 0.2 0.4 0.6 0.8 1
PSD
particle length (normalized)
True PSDEstimated PSD
0 0.2 0.4 0.6 0.8 1PSD
particle length (normalized)
True PSDEstimated PSD
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 15 / 31
Maximum likelihood estimation of PSD
Definitions
ρ = arg maxρ
pX (x1, x2, . . . , xT |ρ)
ρ = (ρ1, . . . , ρT ): maximum likelihood estimate of absolute PSD
xi : number of observations of non-border particles in size class i
pX : joint probability density for X
X = (X1, . . . ,XT ): random vector in which Xi gives the number ofnon-border particles of size class i observed
Solution
Assuming X1, . . . ,XT independent (occlusion effects negligible) . . .
ρi =Xi
αi, i = 1, . . . ,T
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 16 / 31
Maximum likelihood estimation of PSD
Definitions
ρ = arg maxρ
pX (x1, x2, . . . , xT |ρ)
ρ = (ρ1, . . . , ρT ): maximum likelihood estimate of absolute PSD
xi : number of observations of non-border particles in size class i
pX : joint probability density for X
X = (X1, . . . ,XT ): random vector in which Xi gives the number ofnon-border particles of size class i observed
Solution
Assuming X1, . . . ,XT independent (occlusion effects negligible) . . .
ρi =Xi
αi, i = 1, . . . ,T
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 16 / 31
Maximum likelihood estimation of PSD
Definitions
ρ = arg maxρ
pX (x1, x2, . . . , xT |ρ)
ρ = (ρ1, . . . , ρT ): maximum likelihood estimate of absolute PSD
xi : number of observations of non-border particles in size class i
pX : joint probability density for X
X = (X1, . . . ,XT ): random vector in which Xi gives the number ofnon-border particles of size class i observed
Solution
Assuming X1, . . . ,XT independent (occlusion effects negligible) . . .
ρi =Xi
αi, i = 1, . . . ,T
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 16 / 31
Maximum likelihood estimation of PSD
Definitions
ρ = arg maxρ
pX (x1, x2, . . . , xT |ρ)
ρ = (ρ1, . . . , ρT ): maximum likelihood estimate of absolute PSD
xi : number of observations of non-border particles in size class i
pX : joint probability density for X
X = (X1, . . . ,XT ): random vector in which Xi gives the number ofnon-border particles of size class i observed
Solution
Assuming X1, . . . ,XT independent (occlusion effects negligible) . . .
ρi =Xi
αi, i = 1, . . . ,T
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 16 / 31
Maximum likelihood estimation of PSD
Definitions
ρ = arg maxρ
pX (x1, x2, . . . , xT |ρ)
ρ = (ρ1, . . . , ρT ): maximum likelihood estimate of absolute PSD
xi : number of observations of non-border particles in size class i
pX : joint probability density for X
X = (X1, . . . ,XT ): random vector in which Xi gives the number ofnon-border particles of size class i observed
Solution
Assuming X1, . . . ,XT independent (occlusion effects negligible) . . .
ρi =Xi
αi, i = 1, . . . ,T
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 16 / 31
Distribution of PSD estimates
x-y plane: PSD
01234567
02
46
8100
0.050.1
0.150.2
0.250.3
probability
PSD size class
probability
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 17 / 31
Distribution of PSD estimates
100 images
01234567
02
46
8100
0.050.1
0.150.2
0.250.3
probability
PSD size class
probability
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 17 / 31
Distribution of PSD estimates
1000 images
01234567
02
46
8100
0.01
0.02
0.03
0.04
0.05
probability
PSD size class
probability
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 17 / 31
Characterizing measurement reliability
Measurement reliability depends on a variety of factors:
Imaging conditions:
Camera resolution, R
Field of view, a,b
Depth of field, d
Process conditions:
Solids concentration (w/v), Sw
Particle length, L
Particle width, w
Factors can be lumped into single parameter denoting number of crystalsappearing in the image:
Nc =Swabd
ρcw2L
. . . but what’s really important is the amount of overlap
D = ρΩd
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 18 / 31
Constant solids concentration versus constant D
Constant solids Constant overlap (D)
0
2
4
6
8
10
3 4 5 6 7 8 9 10 11 12
Ave
.no
.of
over
laps
Solids Concentration, Sw
0.1a
0.4a0.7a
0
0.5
1
1.5
2
2.5
0 0.5 1 1.5 2 2.5
Ave
.no
.of
over
laps
Image difficulty, D
L = 0.1a, AR=5L = 0.7a, AR=5L = 0.1a,AR=20L = 0.7a,AR=20
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 19 / 31
Estimation of number density in presence of overlap
Number of particles identified by image analysis (IA):
n = ρα
0
20
40
60
80
100
0 100 200 300 400 500 600 700
num
ber
iden
tified
byIA
number of particles per image
Per
fect
IA
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 20 / 31
Estimation of number density in presence of overlap
Number of particles identified by image analysis (IA):
n = ρα exp(−ρΩ)
0
20
40
60
80
100
0 100 200 300 400 500 600 700
num
ber
iden
tified
byIA
number of particles per image
Per
fect
IA
Worst-case IA
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 20 / 31
Estimation of number density in presence of overlap
Number of particles identified by image analysis (IA):
n = ρα exp(−ρΩ)
0
20
40
60
80
100
0 100 200 300 400 500 600 700
num
ber
iden
tified
byIA
number of particles per image
Per
fect
IA
Worst-case IA
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 20 / 31
Estimation of number density in presence of overlap
Number of particles identified by image analysis (IA):
n = ρα exp(−ρΩ)
0
20
40
60
80
100
0 100 200 300 400 500 600 700
num
ber
iden
tified
byIA
number of particles per image
Per
fect
IA
Worst-case IA
SHARC data
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 20 / 31
Estimation of number density in presence of overlap
Number of particles identified by image analysis (IA):
n = ρα exp(−ρΩθ)
0
20
40
60
80
100
0 100 200 300 400 500 600 700
num
ber
iden
tified
byIA
number of particles per image
Per
fect
IA
Worst-case IA
SHARC dataθ = 0.4
θ = 0
θ = 1
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 20 / 31
Estimation
D = 0.1 D = 1.0 D = 3.0 D = 6.0
0
0.5
1
1.5
2
0 1 2 3 4 5 6
ρ/ρ
Image difficulty, D
MLE including overlapMLE ignoring overlap
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 21 / 31
Example: Batch crystallization of photochemical6
Simulation methods
Simulate PSD using populationbalance model.
At t = 0, 1, . . . , 7 hours,generate images correspondingto process state.
Estimate PSD from image data.
Batch Crystallizer.(Image courtesy of Ferro Pfanstiehl
Laboratories, Inc.)6Matthews and Rawlings, AIChE J., 1998
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 22 / 31
Conventional solid-phase measurement
Mirror
FiberopticProbe
00.10.20.30.40.50.60.70.80.9
1
0 1 2 3 4 5 6 7Tra
nsm
itta
nce
Time, [hours]
Surface area
Transmittance
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 23 / 31
Photochemical crystallization, t = 0 hrs
True vs measured PSD (500 images) Example image
0
0.01
0.02
0.03
0.04
0.05
0.06
0 50 100 150 200 250 300 350
wei
ght
PSD
,f w
,[g
/cm
3]
Length, L, [µm]
TrueMeasured
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 24 / 31
Photochemical crystallization, t = 1 hr
True vs measured PSD (500 images) Example image
0
0.05
0.1
0.15
0.2
0.25
0 50 100 150 200 250 300 350
wei
ght
PSD
,f w
,[g
/cm
3]
Length, L, [µm]
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 25 / 31
Photochemical crystallization, t = 2 hrs
True vs measured PSD (500 images) Example image
00.10.20.30.40.50.60.70.80.9
1
0 50 100 150 200 250 300 350
wei
ght
PSD
,f w
,[g
/cm
3]
Length, L, [µm]
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 26 / 31
Photochemical crystallization, t = 4 hrs
True vs measured PSD (500 images) Example image
0
2
4
6
8
10
12
0 50 100 150 200 250 300 350
wei
ght
PSD
,f w
,[g
/cm
3]
Length, L, [µm]
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 27 / 31
Photochemical crystallization, t = 5 hrs
True vs measured PSD (500 images) Example image
0
5
10
15
20
25
0 50 100 150 200 250 300 350
wei
ght
PSD
,f w
,[g
/cm
3]
Length, L, [µm]
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 28 / 31
Photochemical crystallization, t = 7 hrs
True vs measured PSD (500 images) Example image
0
5
10
15
20
25
30
35
0 50 100 150 200 250 300 350
wei
ght
PSD
,f w
,[g
/cm
3]
Length, L, [µm]
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 29 / 31
Conclusions
Image Analysis
SHARC and M-SHARC can segment noisy, in situ images.
The algorithms enable real-time measurement of crystal shape andsize distributions.
SHARC licensed by Mettler-Toledo.
Statistical Estimation
Sampling bias due to edge effects and imperfect image analysis canbe corrected using maximum likelihood estimation.
An easy-to-implement, computationally inexpensive method forestimating PSD has been developed.
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 30 / 31
Conclusions
Image Analysis
SHARC and M-SHARC can segment noisy, in situ images.
The algorithms enable real-time measurement of crystal shape andsize distributions.
SHARC licensed by Mettler-Toledo.
Statistical Estimation
Sampling bias due to edge effects and imperfect image analysis canbe corrected using maximum likelihood estimation.
An easy-to-implement, computationally inexpensive method forestimating PSD has been developed.
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 30 / 31
Conclusions
Image Analysis
SHARC and M-SHARC can segment noisy, in situ images.
The algorithms enable real-time measurement of crystal shape andsize distributions.
SHARC licensed by Mettler-Toledo.
Statistical Estimation
Sampling bias due to edge effects and imperfect image analysis canbe corrected using maximum likelihood estimation.
An easy-to-implement, computationally inexpensive method forestimating PSD has been developed.
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 30 / 31
Conclusions
Image Analysis
SHARC and M-SHARC can segment noisy, in situ images.
The algorithms enable real-time measurement of crystal shape andsize distributions.
SHARC licensed by Mettler-Toledo.
Statistical Estimation
Sampling bias due to edge effects and imperfect image analysis canbe corrected using maximum likelihood estimation.
An easy-to-implement, computationally inexpensive method forestimating PSD has been developed.
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 30 / 31
Conclusions
Image Analysis
SHARC and M-SHARC can segment noisy, in situ images.
The algorithms enable real-time measurement of crystal shape andsize distributions.
SHARC licensed by Mettler-Toledo.
Statistical Estimation
Sampling bias due to edge effects and imperfect image analysis canbe corrected using maximum likelihood estimation.
An easy-to-implement, computationally inexpensive method forestimating PSD has been developed.
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 30 / 31
Acknowledgment
Professor Nicola Ferrier, Mech. Eng. Dept.
Image analysis consulting.
Professor Lian Yu, School of Pharmacy
Polymorphism expertise.XRPD and Raman analysis for initial glycine studies.
Dr. Philip C. Dell’Orco, GlaxoSmithKline
Imaging equipment.
National Science Foundation.
Larsen, Rawlings (Wisconsin) Imaging-based crystallization monitoring 31 / 31