Добавил:
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:

Kluwer - Handbook of Biomedical Image Analysis Vol

.1.pdf
Скачиваний:
106
Добавлен:
10.08.2013
Размер:
10.58 Mб
Скачать

Recent Advances in the Level Set Method

255

method, Comput. Methods Appl. Mech. Eng., Vol. 190, pp. 6183–6200,

2001.

[120]Sukumar, N., Chopp, D. L., and Moran, B., Extended finite element method and fast marching method for three-dimensional fatigue crack propagation, Eng. Fracture Mech., Vol. 70, No. 1, pp. 29–48, 2003.

[121]Sukumar, N., Moes,¨ N., Moran, B., and Belytschko, T., Extended finite element method for three-dimensional crack modeling, Int. J. Numer. Methods Eng., Vol. 48, No. 11, pp. 1549–1570, 2000.

[122]Suri, J. S., Two-dimensional fast magnetic resonance brain segmentation, IEEE Eng. Med. Biol. Mag., Vol. 20, pp. 84–95, 2001.

[123]Torres, M., Chopp, D. L., and Walsh, T., Level set methods to compute minimal surfaces in a medium with exclusions (voids), Interfaces and Free Boundaries, 2004, to appear.

[124]Udaykumar, H. S. and Mao, L., Sharp-interface simulation of dendritic solidification of solutions, Int. J. Heat Mass Transfer, Vol. 45, No. 24, pp. 4793–4808, 2002.

[125]Vemuri, B. C., Guo, Y. L., and Wang, Z. Z., Deformable pedal curves and surfaces: Hybrid geometric active models for shape recovery, Int. J. Comput. Vision, Vol. 44, pp. 137–155, 2001.

[126]Vemuri, B. C., Ye, J., Chen, Y., and Leonard, C. M., Image registration via level-set motion: Applications to atlas-based segmentation, Med. Image Anal., Vol. 7, pp. 1–20, 2003.

[127]Ventura, G., Xu, J. X., and Belytschko, T., A vector level set method and new discontinuity approximations for crack growth by EFG, Int. J. Numer. Methods Eng., Vol. 54, pp. 923–944, 2002.

[128]Vese, L. A. and Chan, T. F., A multiphase level set framework for image segmentation using the Mumford and Shah model, Int. J. Comput. Vision, Vol. 50, pp. 271–293, 2002.

[129]Vladimirsky, A., Fast Methods for Static Hamilton–Jacobi Partial Differential Equations, Ph.D. Thesis, Univ. of California, Berkeley, 2001.

256

Chopp

[130]Vogl, P., Hansen, U., and Fiorentini, V., Multiscale approaches for metal thin film growth, Comput. Mater. Sci., Vol. 24, pp. 58–65, 2002.

[131]Wang, M. Y., Wang, X. M., and Guo, D. M., A level set method for structural topology optimization, Comput. Methods Appl. Mech. Eng., Vol. 192, pp. 227–246, 2003.

[132]Wheeler, D., Josell, D., and Moffat, T. P., Modeling superconformal electrodeposition using the level set method, J. Electrochem. Soc., Vol. 150, pp. C302–C310, 2003.

[133]Yan, J. Y. and Zhuang, T. G., Applying improved fast marching method to endocardial boundary detection in echocardiographic images, Pattern Recognit. Lett., Vol. 24, pp. 2777–2784, 2003.

[134]Ye, J. C., A self-referencing level-set method for image reconstruction from sparse Fourier samples, Int. J. Comput. Vision, Vol. 50, pp. 253–270, 2002.

[135]Yokoi, K., Numerical method for complex moving boundary problems in a Cartesian fixed grid, Phys. Rev. E, Vol. 65, pp. 055701–055705, 2002.

[136]Yokoi, K., Numerical method for a moving solid object in flows, Phys. Rev. E, Vol. 67, pp. 045701–045704, 2003.

[137]Yokoi, K., and Xiao, F., Mechanism of structure formation in circular hydraulic jumps: Numerical studies of strongly deformed free-surface shallow flows, Physica. D, Vol. 161, pp. 202–219, 2002.

[138]Yue, W. S., Lin, C. L., and Patel, V. C., Numerical simulation of unsteady multidimensional free surface motions by level set method, Int. J. Numer. Methods Fluids, Vol. 42, pp. 853–884, 2003.

[139]Zigelman, G., Kimmel, R., and Kiryati, N., Texture mapping using surface flattening via multidimensional scaling, IEEE Trans. Vis. Comput. Graphics, Vol. 8, pp. 198–207, 2002.

Chapter 5

Shape From Shading Models

Xiaoping Shen1 and Lin Yang2

5.1 Introduction

In many applications, for instance, visual inspection in robot vision and autonomous land vehicle navigation to name a few, a procedure of recovering three-dimensional surfaces of unknown objects is of considerable practical interest. In this chapter, we consider one of the reconstruction models: the shape from shading (SFS) model. The SFS models are not only important for applications in engineering but also of great intrinsic mathematical interest. We begin with a portrait of the model.

5.1.1 The Shape from Shading Model

The problem of SFS is to determine the shape of a surface, given a single gray level image of the surface. Mathematically speaking, if we denote the surface of the object by

Z = Z(x, y), (x, y)

with the unit normal to the surface

−→

=

1

(

p, q,

1)T

,

N

 

 

 

 

 

1 + p2 + q2

1 Department of Mathematics, Ohio University, Athens, OH 45701, USA 2 Department of EECS, Ohio University, Athens, OH 45701, USA

257

258

 

 

 

 

Shen and Yang

where

 

 

 

 

 

( p, q) =

∂ Z

∂ Z

 

(5.1)

 

,

 

∂ x

∂ y

is the gradient field, the image irradiance (intensity function) of the surface

I(x, y) and the reflectance map R( p, q) are related by the following image irradiance equation [29] (p. 218):

I(x, y) = R( p, q).

(5.2)

The reflectance map R( p, q) depends on the reflectance properties of the surface and the distribution of the light sources. It could be linear or nonlinear. An SFS problem is classified as a linear shape from shading problem if the reflectance map is linear or otherwise it is a nonlinear shape from shading problem. For instance, the one commonly used to model the lunar surface—Maria of the moon—is linear:

R( p, q)

=

ρ

1 + p0 p + q0q

,

(5.3)

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

1 + p02 + q02

 

 

 

where ρ , the surface albedo, and

 

 

 

 

 

 

 

 

 

 

s0

 

 

1

 

 

 

( p0

, q0,

1)T ,

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

−→ = 1 + p02 + q02

 

 

 

 

the light source direction, are given. Solving the surface Z from (5.3) is a linear shape from shading problem.

Equation (5.2) is sometimes called the Horn image irradiance equation since it was first derived by Horn in 1970 in his thesis [26]. We would like to point out that since Eq. (5.2) depends only on the partial derivatives ( p, q) of the surface

Z(x, y), therefore without additional conditions, the uniqueness of the solution is obviously not possible. These additional conditions are usually given by the boundary conditions. Boundary conditions can be given in many different ways; as an example, we consider the system

ρ

1 + p0 p + q0q

=

I(x, y),

(x, y)

 

,

 

 

 

 

 

 

 

 

 

 

 

 

 

 

1 + p02 + q02

 

 

 

 

 

Shape From Shading Models

 

259

where = [0, 1] × [0, 1] with boundary conditions:

 

(i) Z(0, y) = g1(y),

0 ≤ y ≤ 1,

(5.4)

(ii) Z(1, y) = g2(y),

0 ≤ y ≤ 1,

 

(iii) Z(x, 0) = g3(x),

0 ≤ x ≤ 1.

 

Here gi, i = 1, 2, 3, are smooth functions.

An ideal Lambertian surface is one that appears equally bright from all viewing directions and reflects all incident light, absorbing none ( [29], p. 212). One of the most interesting properties of a Lambertian surface is that the maximum point of reflectance map is unique if it exists [51]. Assuming that the object has a Lambertian surface and is illuminated by a planar wave of light, the Lambertain reflectance map becomes

= −→ · −→

R( p, q) N s ,

−→

where s is the unit vector pointing to the light source, which is given.

A nonlinear shape from shading model is given by an ideal Lambertian sur-

face. In this case, the reflectance map has the well-known form:

 

R( p, q)(x, y)

=

ρ

 

1 + p0 p + q0q

.

(5.5)

 

 

 

 

 

1 + p02 + q02

 

 

 

 

1 + p2 + q2

 

 

 

In a stereographic coordinate system, the stereographic coordinate ( f, g) is related to the Cartesian coordinate by

f =

 

 

2 p

and

g =

 

 

2q

 

 

 

 

 

 

 

 

 

,

1 +

 

 

1 +

 

 

 

1 + p2 + q2

 

1 + p2 + q2

or conversely

 

 

 

 

 

 

 

 

 

 

 

 

 

p =

 

4 f

and

q =

 

4g

 

 

 

 

 

.

 

4 − f 2 g2

4 − f 2 g2

In such a coordinate system, instead of using ( p, q), the reflectance map becomes

R( f, g)

 

4

 

( f 2

g2)

 

 

 

4 f

 

 

 

 

 

4g

 

 

 

1

 

s . (5.6)

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

=

 

4

( f 2

+ g2)

4

 

( f

2

 

g2) , 4

 

( f 2

 

g2) ,

 

+

+

 

· −→

 

 

 

 

+

 

+

 

 

 

 

 

 

 

 

 

 

 

 

 

In summary, the shape from shading problems can be formulated by using

−→

either N or ( p, q) or ( f, g). Together with adequate boundary conditions, the shape from shading problem is to solve a linear or nonlinear partial differential equation (PDE) of first order. In this chapter, we have limited our attention to

260

Shen and Yang

recovering a non-self-shadowing Lambertian surface with constant albedo. We further assume that the object is illuminated by a single distant light source.

The earliest mathematical method to solve this problem, posed by Horn [28], is based on the characteristic strip expansion (see next section). Like the idea of dealing with any other nonlinear problems, linearization is the most common and easiest approach to obtain an approximation to the exact solution. Taylor expansion can be used to derive a linear equation associated with the original equation. After the equation is linearized, some criteria are chosen to discretize the linear PDE to get an algebraic equation. Such methods include, for example, numerical differentiation and integral transform (see [13,15]). Then a numerical method is selected to find an approximation of the solution to the algebraic problem numerically. Since there is no guarantee to the existence of the solution, another approach is to search for optimization solution. This procedure includes introduction of a satisfactory energy function and finding the solution of the posed optimization problem numerically.

5.1.2 About this Chapter

This chapter is written for the purpose of introducing students and practitioners to the necessary elements, including numerical methods and algorithms, in order to understand the current methods and use them in dealing with some practical problems. With a limited set of mathematical jargons and symbols, the emphasis is given to kindle interest for the problem. This has been done by selecting those methods which are easily understood and best demonstrate the idea of SFS models. Of course, our selection of the techniques and numerical examples is limited by the usual constraints: author prejudice and author limitation. Our goal is to draw an outline or describe the framework for solving this problem and leave the details to the readers for further study.

We conclude this section by giving an outline of the chapter. In this chapter, we consider one of the reconstruction methods: shape from shading. The chapter is organized as follows: the first section serves as a brief review of the SFS models, their history, and recent developments. Section 5.2 provides certain mathematical background related to SFS. It discusses some selected numerical methods for solving discretized SFS problems. The emphasis is given to the welldeveloped method—Finite difference method (FDM). Section 5.4 is devoted to the illustration of numerical techniques for solving SFS problems. It concerns

Shape From Shading Models

261

related algorithms and their implementations. The section ends with a discussion about the advantages and disadvantages of the algorithms introduced in this section. The last section attempts to introduce the recently developed waveletbased methods by using an example. A part of the section, however, is devoted to a brief introduction of the basic facts of wavelet theory. In the hope that readers will be able to extrapolate the elements presented here to initiate the understanding of the subject on their own, the chapter concludes with some remarks on other advanced methods. Finally, we include an intensive set of references to make up whatever important spirits which the authors have indeed hardly to touch in this short chapter.

5.2 Mathematical Background of SFS Models

Many problems of mathematical physics lead to PDEs. In general, PDEs are classified in many different ways. However, in most mathematics literature, PDEs are classified on the basis of their characteristics, or curves of information propagation (see, for example, [60] and [19]). The irradiance equation (5.2) is a first-order nonlinear equation. The general format of such an equation in the two-dimensional space is given by

 

∂ Z

∂ Z

 

f

 

,

 

, z, x, y = 0, (x, y) .

(5.7)

∂ x

∂ y

Theoretically, a compactible boundary condition should be given as

Z(x, y) = g(x, y), (x, y) ,

where is the boundary curve of the domain .

In general, nonlinear PDEs are much more difficult than the linear equations, while the more the nonlinearity affects the higher derivatives, the more difficult the PDE is. The irradiance equation (5.2) with a nonlinear reflectance map (5.5) is a hyperbolic PDE of first order with severe nonlinearity. Although the nonlinearity prevents the possibility of deriving any simple method to solve the equation, there are still some techniques developed to obtain local information of the solution to a certain extent. In this section, we briefly review some basics about the irradiance equation, namely, the existence and uniqueness of

262

Shen and Yang

the solution. We also describe a technique, characteristic strip method, which leads to the solution of the equation.

5.2.1 The Uniqueness and Existence

It has been shown that surfaces with continuously varying surface orientation give rise to shaded images. The problem of shape from shading is to reconstruct the three-dimensional shape of a surface from the brightness or intensity variation in a single black-and-white photographic image of the surface. For a long time in history, the SFS model was believed ill-posed. However, it has been shown that the problem in its idealized form is actually well posed or “partially” well posed under a wide range of conditions ( [32, 42]).

The standard assumptions for the idealized surface are:

“Lambertian” reflectance—the surface is matte, rather than mirror-like and reflects light evenly in all directions,

“Orthographic” projection—the illuminating light is from a single known direction and that the surface is distant from the camera, and

“Nonocclusion”—all portions of the surface are visible.

If only one source of illumination is available, uniqueness can be proved. Further Saxberg [51, 52] discussed conditions for existence of the solution. Oliensis [41, 42] has shown the following:

Proposition 1. For an image of a light region contained in a black background, if the reflectance map is known, as given in (5.2), then there is a unique solution for a generic surface which is smooth and non-self-occluding.

Despite various existence and uniqueness theorems for smooth solutions (see [14, 30, 34, 41, 42, 51, 52, 64]), in practice the problem is unstable, which is catastrophic for general numerical algorithms [4, 18]. This is because the reflectance map is, in general, given by its sampled data rather than an analytic expression. This data may be sparse and contaminated by noise. We will not go into the detailed discussion about the uniqueness and existence issue here; the readers who are interested in this issue are referred to the excellent review paper by Hurt [32] and references [14, 30, 34].

Shape From Shading Models

263

5.2.2 The Characteristic Strip Method

Horn [29] established a method to find the solution of (5.2), the characteristic strip method ( [29], p. 244). This method is to generate the characteristic strip expansion for the nonlinear PDE (5.2) along a curve on the surface by solving a group of five ordinary differential equations called characteristic equations:

·

·

 

·

x = Rp,

y = Rq ,

Z = pRp + q Rq ,

·

·

= Ey,

 

p = Ex,

q

 

where the dot denotes differentiation along a solution curve. The characteristic equation can be organized in a matrix format:

 

 

x

 

 

 

Rp

dt

 

y

 

=

 

Rq

d

 

 

 

 

Z

 

 

pRp

 

 

 

p

 

 

Ex

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

q

 

 

 

Ey

 

 

 

 

 

+ q Rq . (5.8)

The solution, (x, y, Z, p, q)T , to (5.8) forms a characteristic strip along the curve. The curves traced out by the solutions of the five ordinary differential equations are called characteristic curves, and their projections in the image are called base characteristics. If an initial curve (with known derivative along this curve) is given by a parametric equation:

−→

= {

}

T

,

r (η)

 

x(η), y(η), Z(η)

 

then we can derive the surface by integrating the equation

∂ Z

= p

∂ x

+ q

∂ y

(5.9)

 

 

 

 

.

∂η

∂η

 

∂η

Example 2. Consider an ideal Lambertian surface illuminated by a light source close to the viewer at ( p0, q0, 1) = (0, 0, 1). ( p0, q0) is the direction toward the light source. In this case, the image irradiance equation is

I(x, y) =

 

1

,

 

 

1 + p2 + q2

where we have set ρ = 1 for simplicity.

264

Shen and Yang

The characteristic equation is then given by

 

 

x

 

 

p(1

d

Z

 

 

( p2

dt

 

y

=

 

 

 

 

 

 

 

 

p

 

Ix

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

+

p2

+

q2)23

 

 

 

 

 

 

pI3

(x, y)

 

3

+

 

 

=

 

 

 

+

 

+

 

 

+

3

 

 

 

+ p2 + q2)2

 

 

 

 

q I3(x, y)

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

q2)(1

p2

 

q2)2

 

 

Ix

 

 

q2)I

 

 

 

 

 

 

( p2

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

3

(x, y) .

q

Iy

Iy

(5.10)

In general, (5.10) has to be solved numerically to get characteristic curves. In practice, since the intensity function is only available as a discrete set of data, analytic solution is simply impossible. An alternative method, which is also the most common method in solving any nonlinear problem, is the calculus of variations.

5.2.3 The Idea of Calculus of Variations

We denote the nonlinear partial differential operator associated with (5.7) by

D[Z](x, y) = 0.

(5.11)

If there exists an “energy” function E[z](x, y) such that

D[·] = E [·],

then the problem (5.11) is equivalent to solving:

E [Z]

=

0.

(5.12)

 

 

 

The solution of the irradiance equation is the critical point of E. In many cases, finding the minimum (or maximum) is easier than solving (5.11) directly. In addition, many of the laws of physics and other scientific disciplines arise directly as variational principle [11, 19, 60].

5.2.3.1 Euler Equation and Lagrange Multipliers

Calculus of variations seeks to find the path, curve, surface, etc. for which a given function has a stationary value (which, in physical problems, is usually a minimum or maximum). In 2D space, this involves finding stationary values of