[GRASS-windows] Georectify problems

7 messages Options
Embed this post
Permalink
Ken Mycock

[GRASS-windows] Georectify problems

Reply Threaded More More options
Print post
Permalink
I'm new to GRASS and am slowly learning my way around.  I've been trying
to georectify a raster scan of a historic map to add to a mapset based
on modern Ordnance Survey data to compare the topology over the
intervening 200 years.  However, whichever way I try I end up with
errors and no rectified output.

Using the georectify tool, I have established seven GCPs and have
verified that they are in a POINTS file.  However, whenever I click on
either the RMS icon or the rectify icon it throws an error window
"WARNING: bad format in control point file for group [Orig_Inc in
PERMANENT]  ERROR: Not Enough Points -- 3 are required" (I'm trying
first order to begin with).

Then I tried using i.rectify from the command line in the output window,
via Run (GUI), hoping it would use the POINTS file already created.  I
successfully completed all the fields in the dialogue, including using
the browse function to select the Group, but when I click Run it throws
an error in the Output window: "Group Orig_Inc@PERMANENT does not exist."

Any suggestions to move on with this essential part of my project?

Ken
_______________________________________________
grass-windows mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/grass-windows
Moritz Lennert

Re: [GRASS-windows] Georectify problems

Reply Threaded More More options
Print post
Permalink
On 26/11/08 16:47, Ken Mycock wrote:

> I'm new to GRASS and am slowly learning my way around.  I've been trying
> to georectify a raster scan of a historic map to add to a mapset based
> on modern Ordnance Survey data to compare the topology over the
> intervening 200 years.  However, whichever way I try I end up with
> errors and no rectified output.
>
> Using the georectify tool, I have established seven GCPs and have
> verified that they are in a POINTS file.  However, whenever I click on
> either the RMS icon or the rectify icon it throws an error window
> "WARNING: bad format in control point file for group [Orig_Inc in
> PERMANENT]  ERROR: Not Enough Points -- 3 are required" (I'm trying
> first order to begin with).
>
> Then I tried using i.rectify from the command line in the output window,
> via Run (GUI), hoping it would use the POINTS file already created.  I
> successfully completed all the fields in the dialogue, including using
> the browse function to select the Group, but when I click Run it throws
> an error in the Output window: "Group Orig_Inc@PERMANENT does not exist."

There was a bug in the group handling which failed on composite names
(i.e. containing @mapset). Try erasing the @PERMANENT.

Also be aware that i.rectify needs to be run from the source location,
i.e. the one where your non-georeferenced image lies. This is different
from the gui georeferencing tool which works from the target location.

You might also have to run i.target in the source location before
running i.rectify.

This said, if you don't get it to work in the GUI, could you please also
file a bug report at http://trac.osgeo.org/grass/, so that we are
reminded to take care of it ?

Thank you,

Moritz
_______________________________________________
grass-windows mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/grass-windows
Ken Mycock

Re: [GRASS-windows] Georectify problems

Reply Threaded More More options
Print post
Permalink
Moritz

Thanks for that.  I should have said that I restarted GRASS in the
source mapset to run i.rectify

I tried i.rectify again as you suggested (removing @PERMANENT from both
the group and the map fields.  It ran a little further and then threw
the same error as the georectify tool -"bad format in control point file
for group [Orig_Inc in PERMANENT]"

I thought it would pick up the target from the annotation in the POINTS
file?

I'll log a bug when I'm sure it's the tool and not me!

Ken

On 26/11/2008 16:28, Moritz Lennert wrote:

> On 26/11/08 16:47, Ken Mycock wrote:
>> I'm new to GRASS and am slowly learning my way around.  I've been
>> trying to georectify a raster scan of a historic map to add to a
>> mapset based on modern Ordnance Survey data to compare the topology
>> over the intervening 200 years.  However, whichever way I try I end
>> up with errors and no rectified output.
>>
>> Using the georectify tool, I have established seven GCPs and have
>> verified that they are in a POINTS file.  However, whenever I click
>> on either the RMS icon or the rectify icon it throws an error window
>> "WARNING: bad format in control point file for group [Orig_Inc in
>> PERMANENT]  ERROR: Not Enough Points -- 3 are required" (I'm trying
>> first order to begin with).
>>
>> Then I tried using i.rectify from the command line in the output
>> window, via Run (GUI), hoping it would use the POINTS file already
>> created.  I successfully completed all the fields in the dialogue,
>> including using the browse function to select the Group, but when I
>> click Run it throws an error in the Output window: "Group
>> Orig_Inc@PERMANENT does not exist."
>
> There was a bug in the group handling which failed on composite names
> (i.e. containing @mapset). Try erasing the @PERMANENT.
>
> Also be aware that i.rectify needs to be run from the source location,
> i.e. the one where your non-georeferenced image lies. This is
> different from the gui georeferencing tool which works from the target
> location.
>
> You might also have to run i.target in the source location before
> running i.rectify.
>
> This said, if you don't get it to work in the GUI, could you please
> also file a bug report at http://trac.osgeo.org/grass/, so that we are
> reminded to take care of it ?
>
> Thank you,
>
> Moritz
>
_______________________________________________
grass-windows mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/grass-windows
Ken Mycock

Re: [GRASS-windows] Georectify problems

Reply Threaded More More options
Print post
Permalink
In reply to this post by Moritz Lennert
Moritz & List members

I've now cracked the bad format issue - accidentally double clicking a point on
the target map to give the east-north reference puts two sets of coordinates
into the point file. That is one line ends up with one xy point followed by two
east-north points, hence the bad format.  I'll log a bug report on this
relatively small aspect.

Correcting this allows i.rectify to run to completion.  For my test image, it
reported over 3.5 million cells created for each of the three colour channels,
which is as expected.  However, displaying the resulting georectified raster in
the target mapset shows large single colour blocks arranged in the expected
portion of the target region - north 5 blocks cover over 1 km and east 8 blocks
cover about the same distance, so the region is covered by 40 cells, not the
reported 3.5 million.

Any suggestions what I'm doing wrong this time?

Regards
Ken

Moritz

Thanks for that.  I should have said that I restarted GRASS in the
source mapset to run i.rectify

I tried i.rectify again as you suggested (removing @PERMANENT from both
the group and the map fields.  It ran a little further and then threw
the same error as the georectify tool -"bad format in control point file
for group [Orig_Inc in PERMANENT]"

I thought it would pick up the target from the annotation in the POINTS
file?

I'll log a bug when I'm sure it's the tool and not me!

Ken

On 26/11/2008 16:28, Moritz Lennert wrote:

> On 26/11/08 16:47, Ken Mycock wrote:
>> I'm new to GRASS and am slowly learning my way around.  I've been
>> trying to georectify a raster scan of a historic map to add to a
>> mapset based on modern Ordnance Survey data to compare the topology
>> over the intervening 200 years.  However, whichever way I try I end
>> up with errors and no rectified output.
>>
>> Using the georectify tool, I have established seven GCPs and have
>> verified that they are in a POINTS file.  However, whenever I click
>> on either the RMS icon or the rectify icon it throws an error window
>> "WARNING: bad format in control point file for group [Orig_Inc in
>> PERMANENT]  ERROR: Not Enough Points -- 3 are required" (I'm trying
>> first order to begin with).
>>
>> Then I tried using i.rectify from the command line in the output
>> window, via Run (GUI), hoping it would use the POINTS file already
>> created.  I successfully completed all the fields in the dialogue,
>> including using the browse function to select the Group, but when I
>> click Run it throws an error in the Output window: "Group
>> Orig_Inc@PERMANENT does not exist."
>
> There was a bug in the group handling which failed on composite names
> (i.e. containing @mapset). Try erasing the @PERMANENT.
>
> Also be aware that i.rectify needs to be run from the source location,
> i.e. the one where your non-georeferenced image lies. This is
> different from the gui georeferencing tool which works from the target
> location.
>
> You might also have to run i.target in the source location before
> running i.rectify.
>
> This said, if you don't get it to work in the GUI, could you please
> also file a bug report at http://trac.osgeo.org/grass/, so that we are
> reminded to take care of it ?
>
> Thank you,
>
> Moritz
>

_______________________________________________
grass-windows mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/grass-windows
Moritz Lennert

Re: [GRASS-windows] Georectify problems

Reply Threaded More More options
Print post
Permalink
On 05/12/08 11:36, Ken Mycock wrote:

> Moritz & List members
>
> I've now cracked the bad format issue - accidentally double clicking a
> point on the target map to give the east-north reference puts two sets
> of coordinates into the point file. That is one line ends up with one xy
> point followed by two east-north points, hence the bad format.  I'll log
> a bug report on this relatively small aspect.
>
> Correcting this allows i.rectify to run to completion.  For my test
> image, it reported over 3.5 million cells created for each of the three
> colour channels, which is as expected.  However, displaying the
> resulting georectified raster in the target mapset shows large single
> colour blocks arranged in the expected portion of the target region -
> north 5 blocks cover over 1 km and east 8 blocks cover about the same
> distance, so the region is covered by 40 cells, not the reported 3.5
> million.
>
> Any suggestions what I'm doing wrong this time?

You need to set the desired resolution and extent in the target location
(g.region).

Did you run i.rectify from the command line or via the georectify GUI ?
If the latter than until (including) 6.3, this ran i.rectify with the -c
flag, meaning that it only rectified the portion of the map that lies
within the current region of the target location. Since 6.4, there is a
flag allowing you to chose whether you want this.

If you ran from the command line and didn't use the -c flag, then just
try running g.region rast=YourMap and redisplay ("Zoom to computational
region").

Moritz
_______________________________________________
grass-windows mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/grass-windows
Ken Mycock

Re: [GRASS-windows] Georectify problems

Reply Threaded More More options
Print post
Permalink
Thanks again Moritz

I ran it from the command line without the -c flag, so g.region worked
as per your last para.  If I use the georectify GUI (6.3) in future, do
I need to run g.region vect=MylargestMap first to work round the -c flag?

Regards
Ken

On 05/12/2008 12:30, Moritz Lennert wrote:

> On 05/12/08 11:36, Ken Mycock wrote:
>> Moritz & List members
>>
>> I've now cracked the bad format issue - accidentally double clicking
>> a point on the target map to give the east-north reference puts two
>> sets of coordinates into the point file. That is one line ends up
>> with one xy point followed by two east-north points, hence the bad
>> format.  I'll log a bug report on this relatively small aspect.
>>
>> Correcting this allows i.rectify to run to completion.  For my test
>> image, it reported over 3.5 million cells created for each of the
>> three colour channels, which is as expected.  However, displaying the
>> resulting georectified raster in the target mapset shows large single
>> colour blocks arranged in the expected portion of the target region -
>> north 5 blocks cover over 1 km and east 8 blocks cover about the same
>> distance, so the region is covered by 40 cells, not the reported 3.5
>> million.
>>
>> Any suggestions what I'm doing wrong this time?
>
> You need to set the desired resolution and extent in the target
> location (g.region).
>
> Did you run i.rectify from the command line or via the georectify GUI
> ? If the latter than until (including) 6.3, this ran i.rectify with
> the -c flag, meaning that it only rectified the portion of the map
> that lies within the current region of the target location. Since 6.4,
> there is a flag allowing you to chose whether you want this.
>
> If you ran from the command line and didn't use the -c flag, then just
> try running g.region rast=YourMap and redisplay ("Zoom to
> computational region").
>
> Moritz
>
_______________________________________________
grass-windows mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/grass-windows
Moritz Lennert

Re: [GRASS-windows] Georectify problems

Reply Threaded More More options
Print post
Permalink
On 05/12/08 14:08, Ken Mycock wrote:
> Thanks again Moritz
>
> I ran it from the command line without the -c flag, so g.region worked
> as per your last para.

And setting g.region rast= does not help ?


>  If I use the georectify GUI (6.3) in future, do
> I need to run g.region vect=MylargestMap first to work round the -c flag?

yup.

Moritz

>
> Regards
> Ken
>
> On 05/12/2008 12:30, Moritz Lennert wrote:
>> On 05/12/08 11:36, Ken Mycock wrote:
>>> Moritz & List members
>>>
>>> I've now cracked the bad format issue - accidentally double clicking
>>> a point on the target map to give the east-north reference puts two
>>> sets of coordinates into the point file. That is one line ends up
>>> with one xy point followed by two east-north points, hence the bad
>>> format.  I'll log a bug report on this relatively small aspect.
>>>
>>> Correcting this allows i.rectify to run to completion.  For my test
>>> image, it reported over 3.5 million cells created for each of the
>>> three colour channels, which is as expected.  However, displaying the
>>> resulting georectified raster in the target mapset shows large single
>>> colour blocks arranged in the expected portion of the target region -
>>> north 5 blocks cover over 1 km and east 8 blocks cover about the same
>>> distance, so the region is covered by 40 cells, not the reported 3.5
>>> million.
>>>
>>> Any suggestions what I'm doing wrong this time?
>>
>> You need to set the desired resolution and extent in the target
>> location (g.region).
>>
>> Did you run i.rectify from the command line or via the georectify GUI
>> ? If the latter than until (including) 6.3, this ran i.rectify with
>> the -c flag, meaning that it only rectified the portion of the map
>> that lies within the current region of the target location. Since 6.4,
>> there is a flag allowing you to chose whether you want this.
>>
>> If you ran from the command line and didn't use the -c flag, then just
>> try running g.region rast=YourMap and redisplay ("Zoom to
>> computational region").
>>
>> Moritz
>>

_______________________________________________
grass-windows mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/grass-windows