[GRASSLIST:6157] Newbie with SRTM import problem

Hello GRASS-list member,

I downloaded and installed GRASS 6.0 for Cygwin (Version 0.2.2) on Windows 2000.

After trying to import a SRTM-tile I got the following messages from r.in.srtm :

<

r.in.srtm input=/cygdrive/d/Benutzer/b61bro/data/srtm/N35E065.hgt.zip
[: ==: unknown operand
Extracting /cygdrive/d/Benutzer/b61bro/data/srtm/N35E045...
Archive: /cygdrive/d/Benutzer/b61bro/data/srtm/N35E045.hgt.zip
   inflating: N35E045.hgt
Converting input file to BIL...
A datum name wgs84 (WGS_1984) was specified without transformation parameters.
Note that the GRASS default for wgs84 is towgs84=0.000,0.000,0.000.
Projection of input dataset and current location appear to match.
Proceeding with import...
Illegal filename. Cannot be '.' or 'NULL'

  - ** illegal name **
rm: cannot lstat `/cygdrive/d/Benutzer/b61bro/data/test/b61bro/.tmp/b6pc196/1952.0//cygdrive/d/Benutzer/b61bro/data/srtm/N35E045.hgt.zip': No such file or directory
rmdir: `/cygdrive/d/Benutzer/b61bro/data/test/b61bro/.tmp/b6pc196/1952.0': Device or resource busy
ERROR: - map not found
Done: generated map
(Note: Holes in the data can be closed with 'r.fillnulls' using splines)

>

My location is defined in WIND as follows:

<

proj: 3
zone: 0
north: 36N
south: 35N
east: 46E
west: 45E
cols: 1200
rows: 1200
e-w resol: 0:00:03
n-s resol: 0:00:03
top: 1
bottom: 0
cols3: 1
rows3: 1
depths: 1
e-w resol3: 1
n-s resol3: 1
t-b resol: 1

>

Has anyone an idea what might be wrong ?

Thanks in advance!

Karl

--------------------------------------------------------------------------
Dr.-Ing. Karl BROICH Tel: +49 / (0) 89 / 6004 2478
Universität der Bundeswehr München Fax: +49 / (0) 89 / 6004 3858
Institut für Wasserwesen
Werner-Heisenberg-Weg 39
D 85577 Neubiberg
--------------------------------------------------------------------------

Hi Karl,

try to copy the hgt.zip file into /tmp before you import it, may be the
import -script has aproblem with the cygdrive-paths.

Does this work?

Marco

P.S. I always tried it from the /tmp-dir not from any dir outside of the
cygwin-directorytree. May it's a problem with the .tmp folder in your path
to hgt.zip

P.P.S. well, as author of the CygwinGRASS-CD I can tell you, that this
Version is able to import SRTM-files (former versions had a gdal-problem,
:wink:

---------------------------------
Marco Lechner

dienstlich:
Institut für Physische Geographie
Uni Freiburg
Werderring 4
79085 Freiburg
Fon 0761 / 203-3548
Mail marco.lechner@geographie.uni-freiburg.de

-----Ursprüngliche Nachricht-----
Von: owner-GRASSLIST@baylor.edu [mailto:owner-GRASSLIST@baylor.edu]Im
Auftrag von Karl Broich
Gesendet: Montag, 14. März 2005 17:09
An: GRASSLIST@baylor.edu
Betreff: [GRASSLIST:6157] Newbie with SRTM import problem

Hello GRASS-list member,

I downloaded and installed GRASS 6.0 for Cygwin (Version 0.2.2) on Windows
2000.

After trying to import a SRTM-tile I got the following messages from
r.in.srtm :

<

r.in.srtm input=/cygdrive/d/Benutzer/b61bro/data/srtm/N35E065.hgt.zip
[: ==: unknown operand
Extracting /cygdrive/d/Benutzer/b61bro/data/srtm/N35E045...
Archive: /cygdrive/d/Benutzer/b61bro/data/srtm/N35E045.hgt.zip
   inflating: N35E045.hgt
Converting input file to BIL...
A datum name wgs84 (WGS_1984) was specified without transformation
parameters.
Note that the GRASS default for wgs84 is towgs84=0.000,0.000,0.000.
Projection of input dataset and current location appear to match.
Proceeding with import...
Illegal filename. Cannot be '.' or 'NULL'

  - ** illegal name **
rm: cannot lstat
`/cygdrive/d/Benutzer/b61bro/data/test/b61bro/.tmp/b6pc196/1952.0//cygdrive/
d/Benutzer/b61bro/data/srtm/N35E045.hgt.zip':
No such file or directory
rmdir: `/cygdrive/d/Benutzer/b61bro/data/test/b61bro/.tmp/b6pc196/1952.0':
Device or resource busy
ERROR: - map not found
Done: generated map
(Note: Holes in the data can be closed with 'r.fillnulls' using splines)

>

My location is defined in WIND as follows:

<

proj: 3
zone: 0
north: 36N
south: 35N
east: 46E
west: 45E
cols: 1200
rows: 1200
e-w resol: 0:00:03
n-s resol: 0:00:03
top: 1
bottom: 0
cols3: 1
rows3: 1
depths: 1
e-w resol3: 1
n-s resol3: 1
t-b resol: 1

>

Has anyone an idea what might be wrong ?

Thanks in advance!

Karl

--------------------------------------------------------------------------
Dr.-Ing. Karl BROICH Tel: +49 / (0) 89 / 6004 2478
Universität der Bundeswehr München Fax: +49 / (0) 89 / 6004 3858
Institut für Wasserwesen
Werner-Heisenberg-Weg 39
D 85577 Neubiberg
--------------------------------------------------------------------------

On Mon, 14 Mar 2005 17:09:01 +0100
Karl Broich <b61bro@b6axs1.bauv.unibw-muenchen.de> wrote:

Hello GRASS-list member,

I downloaded and installed GRASS 6.0 for Cygwin (Version 0.2.2) on Windows
2000.

After trying to import a SRTM-tile I got the following messages from
r.in.srtm :

<

r.in.srtm input=/cygdrive/d/Benutzer/b61bro/data/srtm/N35E065.hgt.zip
[: ==: unknown operand
Extracting /cygdrive/d/Benutzer/b61bro/data/srtm/N35E045...

can you edit the script* and change this line:

if [ "$GIS_OPT_output" == "" ] ; then

to

if [ -z "$GIS_OPT_output" ] ; then

and see if that fixes it? please let us know if it does.

[*] find with "which r.in.srtm". not sure if this works on cygwin?

using bash as your shell?

Hamish

Thanks to Hamish and Marco !

1. copying the *hgt to tmp does not change anything in my case
2. introducing the modification by Hamish in r.in.srtm solved the problem (almost).

There is still a problem with removal of the tmp (compare logg below).

<

r.in.srtm input=/cygdrive/d/Benutzer/b61bro/data/grass/PERMANENT/.tmp/N35E045.hgt.zip
Extracting /cygdrive/d/Benutzer/b61bro/data/grass/PERMANENT/.tmp/N35E045...
Archive: /cygdrive/d/Benutzer/b61bro/data/grass/PERMANENT/.tmp/N35E045.hgt.zip
   inflating: N35E045.hgt
Converting input file to BIL...
A datum name wgs84 (WGS_1984) was specified without transformation parameters.
Note that the GRASS default for wgs84 is towgs84=0.000,0.000,0.000.
Projection of input dataset and current location appear to match.
Proceeding with import...

CREATING SUPPORT FILES FOR N35E045

rm: cannot lstat `/cygdrive/d/Benutzer/b61bro/data/grass/PERMANENT/.tmp/b6pc196/1732.0//cygdrive/d/Benutzer/b61bro/data/grass/PERMANENT/.tmp/N35E045.hgt.zip': No such file or directory
rmdir: `/cygdrive/d/Benutzer/b61bro/data/grass/PERMANENT/.tmp/b6pc196/1732.0': Device or resource busy
Color table for [N35E045] set to srtm
Done: generated map N35E045
(Note: Holes in the data can be closed with 'r.fillnulls' using splines)

>

At 15:21 15.03.2005 +1300, you wrote:

On Mon, 14 Mar 2005 17:09:01 +0100
Karl Broich <b61bro@b6axs1.bauv.unibw-muenchen.de> wrote:

> Hello GRASS-list member,
>
> I downloaded and installed GRASS 6.0 for Cygwin (Version 0.2.2) on Windows
> 2000.
>
> After trying to import a SRTM-tile I got the following messages from
> r.in.srtm :
>
> <
>
> r.in.srtm input=/cygdrive/d/Benutzer/b61bro/data/srtm/N35E065.hgt.zip
> [: ==: unknown operand
> Extracting /cygdrive/d/Benutzer/b61bro/data/srtm/N35E045...

can you edit the script* and change this line:

if [ "$GIS_OPT_output" == "" ] ; then

to

if [ -z "$GIS_OPT_output" ] ; then

and see if that fixes it? please let us know if it does.

[*] find with "which r.in.srtm". not sure if this works on cygwin?

using bash as your shell?

Hamish

--------------------------------------------------------------------------
Dr.-Ing. Karl BROICH Tel: +49 / (0) 89 / 6004 2478
Universität der Bundeswehr München Fax: +49 / (0) 89 / 6004 3858
Institut für Wasserwesen
Werner-Heisenberg-Weg 39
D 85577 Neubiberg
--------------------------------------------------------------------------

Hamish wrote:

> [: ==: unknown operand
> Extracting /cygdrive/d/Benutzer/b61bro/data/srtm/N35E045...

can you edit the script* and change this line:

if [ "$GIS_OPT_output" == "" ] ; then

The equality-test operator is "=", not "=="; i.e. it should be:

  if [ "$GIS_OPT_output" = "" ] ; then

--
Glynn Clements <glynn@gclements.plus.com>

hi all,

I'm triying to compile grass6.0.0 in suse9.2, but i have a lot
of problems with dependencies. i.e. curses.h can't be found but
is there... i can't compile others versions neither.

Some one know how to do it?

Thanks.

Mauricio Vargas P.
Geólogo
MSc en Geología
Usurio Linux # 326558 counter.li.org

Mauricio, you have to be sure that you installed the *-devel rpms on
your distro. Yast will allow you to do that really easily. If that isn't
the situation, and you already have all the packages installed, then you
will have to give the configure script the path to those
headers/libraries on your system. Good luck!

Luis

On Sat, 2005-03-19 at 20:01 -0400, Mauricio Vargas P. wrote:

hi all,

I'm triying to compile grass6.0.0 in suse9.2, but i have a lot
of problems with dependencies. i.e. curses.h can't be found but
is there... i can't compile others versions neither.

Some one know how to do it?

Thanks.

Mauricio Vargas P.
Geólogo
MSc en Geología
Usurio Linux # 326558 counter.li.org

I'm triying to compile grass6.0.0 in suse9.2, but i have a lot
of problems with dependencies. i.e. curses.h can't be found but
is there... i can't compile others versions neither.

Some one know how to do it?

Have you tried the pre-compiled SuSE binaries?

http://www.gdf-hannover.de/software/suse/9.2/

(note download page only linked to 9.1 in past; now updated in CVS to
link to both 9.1 and 9.2 versions)

Hamish

On Sun, 20 Mar 2005 13:59:19 +1200, Hamish wrote

Have you tried the pre-compiled SuSE binaries?

http://www.gdf-hannover.de/software/suse/9.2/

jaja... thanks a lot... i get it again :slight_smile:

Mauricio Vargas P.
Geólogo
MSc en Geología
Usurio Linux # 326558 counter.li.org
http://users.quickfox.org/~mauriciovargas/