1photo.2target(1)              Grass User's Manual             photo.2target(1)
2
3
4

NAME

6       photo.2target   - Creates control points on an image to be ortho-recti‐
7       fied.
8

KEYWORDS

10       imagery
11

SYNOPSIS

13       photo.2target
14       photo.2target help
15       photo.2target group=string   [map=name]    [target=name]    [--verbose]
16       [--quiet]
17
18   Parameters:
19       group=string
20           Name of imagery group
21
22       map=name
23           Name  of  image  to  be  rectified which will  be initialy drawn on
24           screen.
25
26       target=name
27           Name of a map from target mapset which  will be initialy  drawn  on
28           screen.
29

DESCRIPTION

31       photo.2target  is  an imagery function that enables you to mark control
32       points on an image to be ortho-rectified and then input the coordinates
33       of  each point for calculation of rectification parameters.  Rectifica‐
34       tion is the mapping of an image from one coordinate system to  another.
35       The  geometry of an image extracted into a GRASS LOCATION having an x,y
36       coordinate system is not planimetric.  To create a  planimetric  image,
37       that  is,  to convert the x,y coordinate system into a standard coordi‐
38       nate system (for example, the UTM coordinate system or the State  Plane
39       coordinate  system),  points from a map having the standard coordinates
40       must be associated with the same points on the image to  be  rectified.
41       The  ortho-rectification  parameters  are  computed  in two phases. The
42       first phase computes a transformation matrix  between  image  (row,col)
43       coordinates  and  photo  (x,y)  coordinates relative to the perspective
44       center. The transformation matrix is computed explicitly in the  option
45       photo.2image  .   The  second phase, photo.2target, enables you to mark
46       control points on the image and then  input  the  standard  coordinates
47       (Easting,Northing,  and  elevation)  to  determine the parameters for a
48       three dimensional projective transformation.  photo.init
49        may be run before running photo.2target to modify the  initial  camera
50       exposure  station  parameters,  and/or modify the standard deviation of
51       these parameters.  photo.init
52        is not required but generally is helpful.
53
54       During the process of marking  control  points  and  entering  standard
55       coordinates,  you may compute the RMS (root mean square) error for each
56       control point entered.  photo.2target  does  this  by  calculating  the
57       transformation  equation, and then plugging these results into an equa‐
58       tion for RMS error.
59
60       photo.2target offers a zoom option to locate precisely the point to  be
61       marked  on an image. This program also offers you the option of acquir‐
62       ing standard coordinates for a marked point from a  map  layer  in  the
63       target database, or from a digitizer.
64
65       To run photo.2target, a graphics monitor is required.
66
67       The procedure for marking points, entering coordinates, and calculating
68       RMS error is described below.
69
70       The terminal screen displays the following message:
71
72       use mouse now...
73
74       The graphics monitor displays the following screen:
75
76
77       +-----------------------------+--------------------------------+
78       |imagery  filename  (mag)     | target  filename  (mag)        |
79       +-----------------------------+--------------------------------+
80       |                             |                                |
81       |                             |                                |
82       |                             |                                |
83       |                             |                                |
84       |                             |                                |
85       |                             |                                |
86       |                             |                                |
87       +-----------------------------+--------------------------------+
88       |                             |                                |
89       |                             |                                |
90       |                             |                                |
91       |                             |                                |
92       |                             |                                |
93       |                             |                                |
94       +-----------------------------+--------------------------------+
95       |QUIT ZOOM PLOTCELL ANALYZE   |                                |
96       +-----------------------------+--------------------------------+
97
98
99       A pop-down menu like that shown below will be superimposed on the  left
100       half of the screen:
101
102
103                  +------------------------------------------+
104                  | Double click on raster map to be plotted |
105                  | Double click here to cancel              |
106                  +------------------------------------------+
107                              +--------------------+
108                              |  Mapset PERMANENT  |
109                              +---------+----------+
110                              |gs13.1   | gs14.1   |
111                              +---------+----------+
112                              |gs21.1   | gs22.2   |
113                              +---------+----------+
114
115
116       Any  single  file  in the imagery group may be used to mark points, and
117       you can mark points on more than one file in the imagery group to accu‐
118       mulate  the 12 points suggested minimum.  Any file in the imagery group
119       can be rectified (using photo.rectify  )  based  on  the  rectification
120       parameters computed from these control points.
121
122       The  imagery file you select is displayed in the upper left quadrant of
123       the screen.
124

ZOOM

126       To magnify the displayed file, you must place the mouse cross hairs  on
127       the  word ZOOM. The following menu will then be displayed at the bottom
128       of the screen:
129
130
131                 +-------+-----+-------++--------------------+
132                 |Cancel | Box | Point ||Select type of ZOOM |
133                 +-------+-----+-------++--------------------+
134
135
136       You may identifying the zoom window either by using the mouse to make a
137       box,  or by using the mouse to mark the center of the window and enter‐
138       ing a magnification factor.  The terminal screen will display  a  mouse
139       button menu to guide you in identifying the window.
140
141       It  is  also possible to start zoom by box with middle mouse button and
142       pan by right mouse button.
143

MARKING POINTS

145       To mark the points on the image that correspond  to  the  points  on  a
146       standard coordinate system map, you must place the mouse cross hairs on
147       the corresponding location on the image to be marked and press the left
148       hand  button  on  the mouse.  A diamond shaped symbol will be marked on
149       the image.  The terminal will display the following menu:
150
151
152          +------------------------------------+--------------------------+
153          |Point 1 marked at IMAGE COORDINATES |                          |
154          |IMAGE X:   1023.77                  |                          |
155          |IMAGE Y:  -164.41                   |                          |
156          |                                    |                          |
157          +------------------------------------+--------------------------+
158          |Enter CONTROL COORDINATES as east,north,elevation:             |
159          +---------------------------------------------------------------+
160
161
162       You then enter the easting,  northing,  and  elevation  for  the  point
163       marked on the image.  If you wish not to enter a coordinate, simply hit
164       RETURN to return control to the mouse;  the marked  point  then  disap‐
165       pears.
166
167       Entered point can be canceled by right mouse button click.
168

PLOT CELL

170       In  addition  to acquiring control points from a standard map, you have
171       the option of acquiring the  points from a cell-map in the target data‐
172       base.   The  database map is displayed by placing the mouse cross hairs
173       on the words PLOT CELL.  The following line is then  displayed  at  the
174       bottom of the monitor:
175
176
177           +-------+---------------------------------------+
178           |Cancel | Indicate which side should be plotted |
179           +-------+---------------------------------------+
180
181
182       Which  side of the monitor is to be plotted is indicated by placing the
183       mouse cross hairs on the half of the monitor screen that you would like
184       to  use,  and  pressing  the left mouse button.  The following pop-down
185       menu will be superimposed on the half of the screen that was chosen:
186
187
188           +------------------------------------------+
189           | Double click on raster map to be plotted |
190           | Double click here to cancel              |
191           +------------------------------------------+
192
193           +-----------------------------+
194           |   Mapset user1              |
195           +--------------+--------------+
196           |tm.rectified  |              |
197           +--------------+--------------+
198           |tm.classified |              |
199           +--------------+--------------+
200           |   Mapset PERMANENT          |
201           +--------------+--------------+
202           |elevation     | geology      |
203           +--------------+--------------+
204           |slope         | soils        |
205           +--------------+--------------+
206           |aspect        |              |
207           +--------------+--------------+
208           |roads         |              |
209           +--------------+--------------+
210           |streams       |              |
211           +--------------+--------------+
212           |airfields     |              |
213           +--------------+--------------+
214
215
216       After the map is displayed the following message appears at the  bottom
217       of the monitor:
218
219
220            +-----------------+----------+--------+
221            |input method ->  | keyboard | screen |
222            +-----------------+----------+--------+
223
224
225       If you wish to use the plotted map only as a comparative reference, the
226       keyboard can be chosen as the means to input coordinates  corresponding
227       to  the marked control points.  This is done by placing the mouse cross
228       hairs on the word KEYBOARD and pressing the left button on the mouse.
229
230       If you select the SCREEN option, points marked on the image will  auto‐
231       matically  be  associated  with  the coordinates from the corresponding
232       points on the target database map, and a corresponding  elevation  from
233       the  cell-file  selected  for elevation data.  In this option, when you
234       mark a point on the image, the following menu is displayed on the  ter‐
235       minal:
236
237
238          +------------------------------------+--------------------------+
239          |Point 5 marked at IMAGE COORDINATES |                          |
240          |IMAGE X: 1023.77                    |                          |
241          |IMAGE Y: -164.41                    |                          |
242          |                                    |                          |
243          |                                    |                          |
244          |Control Point location              |                          |
245          |East:      679132.57                |                          |
246          |North:    4351080.67                |                          |
247          |Elevation:  1010.00                 |                          |
248          |                                    |                          |
249          |                                    |                          |
250          |                                    |                          |
251          +------------------------------------+--------------------------+
252          |use mouse now...                                               |
253          +---------------------------------------------------------------+
254
255
256       The  coordinates for the target database map are automatically saved as
257       the coordinates corresponding to the marked control point on the image.
258

ANALYZE

260       After a number of points have been marked (4 to 7), you can  check  the
261       RMS  error  of the points marked on the image.  This is done by placing
262       the mouse cross hairs on the word ANALYZE at the bottom of the monitor.
263       An error report resembling that shown below is superimposed on the mon‐
264       itor:
265
266
267       +--------------------------------------------------------------------------+
268       |                                                                 error
269       |
270       |#  east    north    target    east    north    east    north     elev.
271       |
272       +--------------------------------------------------------------------------+
273       |1  0.0     -0.9       1.0     48.5     4.8   79132.5 351080.6     10.0
274       |
275       |2   0.4      1.0       1.3     53.1     7.2   84314.7 399001.4   239.3
276       |
277       |3 -1.2     -0.5       0.6     52.8     6.5   67841.4 457682.8    209.5
278       |
279       |4   1.1      0.5       1.3     34.0     9.2   77573.8 352626.4   432.5
280       |
281       |5 -2.7     14.0      14.2     48.6  -144.9   79132.6 351080.7    985.0
282       |
283       |
284       |
285       +--------------------------------------------------------------------------+
286       |                 overall          rms             error:          4.46
287       |
288       +--------------------------------------------------------------------------+
289
290
291       The following menu then appears at the bottom of the monitor:
292
293
294        +-----+------------+------------------------------------------------+
295        |DONE | PRINT FILE |  Double click on point to be included/excluded |
296        +-----+------------+------------------------------------------------+
297
298
299       The  RMS  error  for the image is given under the column TITLEd "error"
300       and subTITLEd "east" and "north".  In the above report, point number  1
301       is  0.0  and  -0.9  meters (east and north) from the predicted location
302       calculated from the transformation equation.  The  RMS  error  for  the
303       target map is listed under the heading "target".  This is the RMS error
304       for the east and north coordinates of the target map  but  it  is  pre‐
305       sented  in the table using one general value.  The overall RMS error is
306       displayed at the bottom of the screen in meters.   Points  that  create
307       high RMS error are displayed in red on the monitor (represented here in
308       italics).
309
310       The image coordinates of the point marked on the imagery group file  is
311       given under the heading "image" and the subheadings "east" and "north".
312       The location of the control point in the target database is given under
313       the  heading  "control" and the subheadings "east","north", and "elev".
314       If you would like to exclude or include a control point,  this  can  be
315       accomplished by placing the mouse cross hairs on the control point num‐
316       ber to be included (if the point is absent) or excluded (if  the  point
317       is  displayed) and pressing the left button on the mouse twice.  When a
318       point is excluded, it is not afterwards included in the calculation  of
319       the RMS error, or included in the final rectification parameters.  How‐
320       ever, it can be retrieved within photo.2target at any  time  by  double
321       clicking with the mouse as described above.
322

QUIT

324       To  end  the  photo.2target  program place the mouse cross hairs on the
325       word QUIT;  the marked control points (including coordinates)  will  be
326       saved.
327

NOTES

329       During  the  course  of marking control points and computing the ortho-
330       rectification parameters, a matrix inversion error may occur.  This  is
331       caused by trying to invert a non-singular normal equation matrix.  When
332       this situation arises, the status of all  previously  selected  control
333       points   are  modified,  the  control  points  are  excluded.   Running
334       photo.init
335        for the selected imagery group with accurate camera  exposure  station
336       parameters  should  remedy  the situation.  The excluded control points
337       may again be included as described in the section ANALYZE.
338
339       A good rule of thumb is to mark at least 12  to  15  points  which  are
340       evenly  distributed  over  the  entire  imagery  group file in order to
341       obtain an accurate  transformation  parameters  for  the  rectification
342       process.   The  RMS  error may increase with more points added, but the
343       transformation parameters will be more accurate over the entire image.
344
345       An RMS error of less than or equal to approximately one resolution unit
346       (pixel)  for  the image being rectified is generally considered accept‐
347       able.
348

SEE ALSO

350       i.ortho.photo, photo.camera, photo.2image, photo.init, photo.rectify
351

AUTHOR

353       Mike Baba,  DBA Systems, Inc.
354
355       Last changed: $Date: 2006-12-15 11:10:21 +0100 (Fri, 15 Dec 2006) $
356
357       Full index
358
359       © 2003-2008 GRASS Development Team
360
361
362
363GRASS 6.3.0                                                   photo.2target(1)
Impressum