eters does not
x
gment
P
a E E
t xr
dz io^
x
lid
adjusting pose
c Solid
s by adjusting
ometry is the
In this paper,
1e-by-one, then
a Boolean set
n( M ), and
n process of a
CSG tree. The
sed. Since the
pancy between
raints or local
the attaching
1g model.
. Istanbul 2004
International Archives of the Photogrammetry, Remote Sensing and Spatial Information Sciences, Vol XXXV, Part B3. Istanbul 2004
3. LEAST-SQUARES MODEL-IMAGE FITTING
The principle of model-image fitting algorithm is to adjust the
shape and pose parameters of a primitive model, so it can fit the
corresponding features extracted from the images. Since the
floating model can be taken as a wire-frame model, the features
for fitting are edge pixels. The optimal fit is achieved by
minimizing the sum of the perpendicular distances from the
edge pixels to the corresponding projected line of the wire-
frame model. Figure 6 depicts the optimal fitting procedure. A
model base which is a collection of various floating models has
been pre-established. The selected primitive model is projected
onto the image and fit the extracted edge pixels.
Optimal Fitting
Edge
Detection [^
Model Base
&e[mce
Projection
Figure 6. The procedures of optimal fitting.
3.1 Coordinate Systems
The proposed LSMIF algorithm performs the fitting in the
photo coordinate system. A primitive model, however, is
defined in the model space. It is necessary to transform a
primitive model from model space to object space by
introducing a set of shape and pose parameters. Then, it has to
be projected onto the photo coordinate system with the known
exterior orientation parameters. On the other hand, edge pixels
extracted from the images should be transformed to the photo
coordinate system for matching. Figure 7 shows the
transformation of a box from model to photo coordinate system
and the edge pixels from image to photo coordinate system.
Shape & E.O. 1.0.
Pose Para. Parameters Parameters
Zi Y3 Zi Y 3
»
Es Model =) —=)| Exterior [T= fu Interior m)
to Orienta- Orienta- c
X Object X tion X tion
Model Coord. | Trans. Object Coord. Photo Coord.
System System System System
Figure 7. The coordinate systems involved with LSMIF.
The primitive model defined in the model space is a simple unit
solid, e.g. a box is a unit cube of which width, length, and
height are all equal to 1. The shape parameters will elongate or
shorten the box to the correct size, and the pose parameters will
rotate and move the box to the correct altitude and position in
the object space. Table 1 lists the eight vertices coordinates
transforming from model space to object space. Each vertex in
the object space is then projected onto the images by the
Image Coord.
collinearity condition equations with the known exterior
orientation elements
3.2 Approximate Fitting and Buffer
An approximate fitting is required before applying the LSMIF
algorithm. An interactive program is developed for model
selection, approximate fitting, and visualization. To obtain as
close as to the right fitting, this program provides a user
interface that allows the operator to resize, rotate, and move a
model to fit the corresponding building images approximately.
Benefited from the approximate fitting, the LSMIF iteratively
pulls the model to the optimal fit instead of blindly searching
for the solution. To avoid the disturbance of irrelevant edge
pixels, only those edge pixels distributed within the specified
buffer zones will be used in the calculation of the fitting
algorithm. Figure 8 depicts the extracted edge pixels 7; and the
buffer determined by a projected edge v;;v;> of the model. The
suffix i represents the index of edge line, j represents the index
of overlapped image, and k/ represents the index of the edge
pixel. Filtering edge pixels with buffer is reasonable, because
the discrepancies between the projected edges and the
corresponding edge pixels should be small, as the model
parameters are known approximately. However, the buffer size
has to be carefully chosen because it will directly affect the
convergence of the computation, i.e., the pull-in range.
A >
(x " Extracted Pixels
iN in Yi * En Jn)
E d. ? ©. e e
$0 jj °°
eo ^ e e
e Bhd
f
%.
Yo 7.)
» x
Figure 8. The extracted edge pixels and the buffer.
3.3 Objective Function and Least-squares Adjustment
That the fitting condition we are looking for is the projected
model edge line exactly falls on the building edges in the
images. In Eq.(1), the distance dj represents a discrepancy
between an edge pixel 7;; and its corresponding edge line vj;v;»,
which is expected to be zero. Therefore, the objective of the
fitting function is to minimize the squares sum of dj. Suppose a
projected edge line is composed of the projected vertices v;;(x;;,
vi) and vix(x;2, yi). and there is an edge pixel Z;,(xy yj)
located inside the buffer. The distance dj; from the point 7;, to
the edge v;;v;; can be formulated as the following equation:
Table 1. Vertices coordinates from model space to object space.
After Translation
Mertex No Model Space Multiply After Rotation ;
: Coordinate Shape Parameters (Object Space Coordinate)
Vi (0, 0, 0) (0, 0, 0) (0, 0, 0) (dX, dY, dZ)
Vo (1, 0, 0) (w, 0, 0) (wcosa, wsina, 0) (wcosa--dX, wsinac-dY, dZ)
V3 (1,0) (w, 1,0) (weosa-/sina, wsina+icosa, 0) (wcosa-Isina+dX, wsina+/cosa+dY, dZ)
V4 (0, 1, 0) (0, 7, 0) (-Isina, /cosa, 0) (-[sina+dX, /cosa+dY, dZ)
Vs (0, 0, 1) (0, 0, h) (0,0, h) (dX, dY, h+dZ)
V6 (1,0, 1) (w, 0, 4) (wcosa, wsina, h) ((vcosa+dX, wsina+dY, h+dZ)
V7 (1,11) (w, 1, h) (wcosa-Isina, wsina+/cosa, h) (rcosa-/sinatdX, wsina+/cosa+dY, h+dZ)
Vg (0.1, 1) (0, /, h) (-[sina, /cosa, h) (-Isina+dX, lcosa+dY, h+dZ)
443