[GRASS-user] r.stream.basins addon for grass7 broken (Pankaj Kr Sharma)

Pankaj Kr Sharma pkscwc at gmail.com
Mon Apr 16 04:01:43 EDT 2012


Thanks,
it's working again.
I noticed the changes in basins_inputs.c ( inclusion of header files) and
Makefile ( vectlib to vectorlib).

Thanks again.

On Tue, Apr 10, 2012 at 12:56 AM, <grass-user-request at lists.osgeo.org>wrote:

> Send grass-user mailing list submissions to
>        grass-user at lists.osgeo.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
>        http://lists.osgeo.org/mailman/listinfo/grass-user
> or, via email, send a message with subject or body 'help' to
>        grass-user-request at lists.osgeo.org
>
> You can reach the person managing the list at
>        grass-user-owner at lists.osgeo.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of grass-user digest..."
>
>
> Today's Topics:
>
>   1. r.stream.basins addon for grass7 broken (Pankaj Kr Sharma)
>   2. Re: Re: r.stream.extract Syntax Problem (Markus Metz)
>   3. trouble with r.terraflow (tomte)
>   4. Re: trouble with r.terraflow (Markus Neteler)
>   5. Re: trouble with r.terraflow (Markus Metz)
>   6. Re: trouble with r.terraflow (Markus Metz)
>   7. Re: r.stream.basins addon for grass7 broken (Markus Neteler)
>   8. Re: trouble with r.terraflow (tomte)
>   9. Re: Re: trouble with r.terraflow (Markus Metz)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Mon, 9 Apr 2012 22:32:07 +0530
> From: Pankaj Kr Sharma <pkscwc at gmail.com>
> Subject: [GRASS-user] r.stream.basins addon for grass7 broken
> To: grass-dev at lists.osgeo.org, grass-user at lists.osgeo.org
> Message-ID:
>        <CAM5_u0Hsu2GrD=8C3V3AmJABoTi7Z0zwe8NHmMiWbG2wH3108A at mail.gmail.com
> >
> Content-Type: text/plain; charset="iso-8859-1"
>
> Dear developers,
> After a considerable break, I was trying to update the things and catch up
> with latest grass.
> So, I updated with svn up.
>
> However, I am stuck at addons.
>
> The r.stream.basins addon fails to compile with following message:
>
> OBJ.x86_64-unknown-linux-gnu/basins_inputs.o: In function `process_vector':
>
> r.stream.basins/basins_inputs.c:52: undefined reference to
> `Vect_new_line_struct'
> r.stream.basins/basins_inputs.c:53: undefined reference to
> `Vect_new_cats_struct'
> r.stream.basins/basins_inputs.c:59: undefined reference to `Vect_open_old'
> r.stream.basins/basins_inputs.c:63: undefined reference to
> `Vect_region_box'
> r.stream.basins/basins_inputs.c:65: undefined reference to
> `Vect_read_next_line'
> r.stream.basins/basins_inputs.c:68: undefined reference to
> `Vect_point_in_box'
> r.stream.basins/basins_inputs.c:75: undefined reference to `Vect_rewind'
> r.stream.basins/basins_inputs.c:77: undefined reference to
> `Vect_read_next_line'
> r.stream.basins/basins_inputs.c:81: undefined reference to
> `Vect_point_in_box'
> r.stream.basins/basins_inputs.c:84: undefined reference to `Vect_cat_get'
> collect2: ld returned 1 exit status
>
> Please help.
>
> Thanks.
>
> Pankaj.
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> http://lists.osgeo.org/pipermail/grass-user/attachments/20120409/0b197c7f/attachment-0001.html
>
> ------------------------------
>
> Message: 2
> Date: Mon, 9 Apr 2012 19:52:08 +0200
> From: Markus Metz <markus.metz.giswork at googlemail.com>
> Subject: Re: [GRASS-user] Re: r.stream.extract Syntax Problem
> To: Rich Shepard <rshepard at appl-ecosys.com>
> Cc: grass-user at lists.osgeo.org
> Message-ID:
>        <CAG+h=FFjiuO57VWjmxq_oR--V_hXc9DW0UT4aJ1_D6wVcyLKww at mail.gmail.com
> >
> Content-Type: text/plain; charset=ISO-8859-1
>
> Considering the length of this thread and the various issues
> mentioned, it seems that I need to update the manual of
> r.stream.extract a bit. I will try to address the issues:
>
> r.stream.extract is designed to work with a DEM only or with a DEM and
> a flow accumulation map as input. This flow accumulation map can be
> created with any method and any software, tested with r.watershed,
> r.terraflow, TAS (now Whitebox), and SAGA. The methods tested are D8,
> MFD, and D-inf. Some modules/software need a hydrologically
> conditioned DEM without sinks as input (have a look at r.hydrodem in
> GRASS 7 addons), and not the raw DEM. In this case the modified DEM
> used to calculate flow accumulation must be used as input for
> r.stream.extract if a flow accumulation map is also provided. In case
> of r.terraflow, the filled DEM produced by r.terraflow must be used as
> input.
>
> The computational region should be aligned to the DEM in order to get
> accurate results. Aligning to the resolution of the DEM is not enough,
> i.e. you should use g.region align=DEM instead of g.region res=XXX -a.
> r.stream.extract should work if only a subregion is to be analysed by
> setting the computational region accordingly and/or creating a MASK
> e.g. for a specific basin.
>
> The flow accumulation map used as input to r.stream.extract can be
> modified, e.g. by multiplication with a weighing map. In this case
> valid accumulation values should not be converted to NULL, but zero is
> fine. The weighing map should not be used to mask out certain areas,
> instead it should be used to weigh the original accumulation map
> according to slope, valley type, rainfall, etc.
>
> The module will exit with a fatal error if for a given cell there is a
> NULL accumulation value provided, but the DEM is non-NULL. In this
> case a MASK must be created for the subregion covered by the
> accumulation map.
>
> HTH,
>
> Markus M
>
>
> On Sat, Apr 7, 2012 at 11:33 PM, Rich Shepard <rshepard at appl-ecosys.com>
> wrote:
> > On Sat, 7 Apr 2012, Helmut Kudrnovsky wrote:
> >
> >> if the (sub-)watershed are already given, maybe the easiest way to
> define
> >> the region extent for raster processing of your interest is using
> g.region
> >> [1]:
> >
> >
> > Helmut,
> >
> >  It's been long enough that I totally forgot about this. I don't need a
> > mask if I set the region to the basin of interest.
> >
> >  Thanks very much for the reminder!
> >
> > Rich
> >
> >
> > _______________________________________________
> > grass-user mailing list
> > grass-user at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/grass-user
>
>
> ------------------------------
>
> Message: 3
> Date: Mon, 9 Apr 2012 11:05:38 -0700 (PDT)
> From: tomte <tomte.tumetot at gmx.ch>
> Subject: [GRASS-user] trouble with r.terraflow
> To: grass-user at lists.osgeo.org
> Message-ID: <1333994738375-4716732.post at n6.nabble.com>
> Content-Type: text/plain; charset=us-ascii
>
> Dear folks,
>
> I am using GRASS 6.4.1 (2011) on Mac (mac os x 10.7.3). Generally I am
> running GRASS without any trouble but calling r.terraflow from the command
> line generates the following error comments:
>
> MM error: limit =0B. allocating 16B. limit exceeded by 24B.
> Assertion failed: (0), function operator new, file mm.cc, line 326.
> Abort trap: 6
>
>
> using the gui generates preety much the same output:
>
>
> tree = etree.fromstring(getInterfaceDescription(cmd))
>  File "/Applications/GRASS-6.4.app/Contents/MacOS/etc/wxpyt
> hon/gui_modules/menuform.py", line 1973, in
> getInterfaceDescription
>
> "Details: %s") % (cmd, cmderr)
> gui_modules.gcmd
> .
> GException
> :
> Unable to fetch interface description for command
> 'r.terraflow'. Details: MM error: limit =0B. allocating 16B.
> limit exceeded by 24B.
> Assertion failed: (0), function operator new, file mm.cc,
> line 326.
>
>
> Does anybody knows whats going wrong here.
> Thanks in advance
>
> Thomas
>
>
> --
> View this message in context:
> http://osgeo-org.1560.n6.nabble.com/trouble-with-r-terraflow-tp4716732p4716732.html
> Sent from the Grass - Users mailing list archive at Nabble.com.
>
>
> ------------------------------
>
> Message: 4
> Date: Mon, 9 Apr 2012 20:36:42 +0200
> From: Markus Neteler <neteler at osgeo.org>
> Subject: Re: [GRASS-user] trouble with r.terraflow
> To: tomte <tomte.tumetot at gmx.ch>
> Cc: GRASS user list <grass-user at lists.osgeo.org>
> Message-ID:
>        <CALFmHhvR-09C-moV3ffoaM4H4E83nxNk9k7XCw_nStp5YyZ82w at mail.gmail.com
> >
> Content-Type: text/plain; charset=ISO-8859-1
>
> On Mon, Apr 9, 2012 at 8:05 PM, tomte <tomte.tumetot at gmx.ch> wrote:
> > Dear folks,
> >
> > I am using GRASS 6.4.1 (2011) on Mac (mac os x 10.7.3). Generally I am
> > running GRASS without any trouble but calling r.terraflow from the
> command
> > line generates the following error comments:
> >
> > MM error: limit =0B. allocating 16B. limit exceeded by 24B.
> > Assertion failed: (0), function operator new, file mm.cc, line 326.
> > Abort trap: 6
> >
>
> In GRASS 6.4.2 I see three memory issues fixed in r.terraflow:
> http://trac.osgeo.org/grass/changeset/47647
> http://trac.osgeo.org/grass/changeset/47666
>
> I am not sure that they are related, though.
>
> Please post the output of
>
> g.region -p
>
> Markus
>
>
> ------------------------------
>
> Message: 5
> Date: Mon, 9 Apr 2012 20:36:13 +0200
> From: Markus Metz <markus.metz.giswork at googlemail.com>
> Subject: Re: [GRASS-user] trouble with r.terraflow
> To: tomte <tomte.tumetot at gmx.ch>
> Cc: grass-user at lists.osgeo.org
> Message-ID:
>        <CAG+h=FFTTBBLbOunQCGYQu65mXYka=Bix8omV0_YbPrz4v7TQA at mail.gmail.com
> >
> Content-Type: text/plain; charset=ISO-8859-1
>
> tomte wrote:
> > Dear folks,
> >
> > I am using GRASS 6.4.1 (2011) on Mac (mac os x 10.7.3). Generally I am
> > running GRASS without any trouble but calling r.terraflow from the
> command
> > line generates the following error comments:
> >
> > MM error: limit =0B. allocating 16B. limit exceeded by 24B.
> > Assertion failed: (0), function operator new, file mm.cc, line 326.
> > Abort trap: 6
> >
> It would help a lot if you could provide exact the command line used
> to invoke r.terraflow. A first guess is that the memory option was set
> to something higher than 2048, because r.terraflow in 6.4.1 can only
> use a maximum of 2GB of memory. Since r.terraflow is very efficient in
> handling temporary data, you could just as well leave out the memory
> option (default is 300MB). Alternatively, you can use r.watershed
> which produces more realistic results.
>
> Markus M
>
> >
> > using the gui generates preety much the same output:
> >
> >
> > tree = etree.fromstring(getInterfaceDescription(cmd))
> >  File "/Applications/GRASS-6.4.app/Contents/MacOS/etc/wxpyt
> > hon/gui_modules/menuform.py", line 1973, in
> > getInterfaceDescription
> >
> > "Details: %s") % (cmd, cmderr)
> > gui_modules.gcmd
> > .
> > GException
> > :
> > Unable to fetch interface description for command
> > 'r.terraflow'. Details: MM error: limit =0B. allocating 16B.
> > limit exceeded by 24B.
> > Assertion failed: (0), function operator new, file mm.cc,
> > line 326.
> >
> >
> > Does anybody knows whats going wrong here.
> > Thanks in advance
> >
> > Thomas
> >
> >
> > --
> > View this message in context:
> http://osgeo-org.1560.n6.nabble.com/trouble-with-r-terraflow-tp4716732p4716732.html
> > Sent from the Grass - Users mailing list archive at Nabble.com.
> > _______________________________________________
> > grass-user mailing list
> > grass-user at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/grass-user
>
>
> ------------------------------
>
> Message: 6
> Date: Mon, 9 Apr 2012 20:36:13 +0200
> From: Markus Metz <markus.metz.giswork at googlemail.com>
> Subject: Re: [GRASS-user] trouble with r.terraflow
> To: tomte <tomte.tumetot at gmx.ch>
> Cc: grass-user at lists.osgeo.org
> Message-ID:
>        <CAG+h=FFTTBBLbOunQCGYQu65mXYka=Bix8omV0_YbPrz4v7TQA at mail.gmail.com
> >
> Content-Type: text/plain; charset=ISO-8859-1
>
> tomte wrote:
> > Dear folks,
> >
> > I am using GRASS 6.4.1 (2011) on Mac (mac os x 10.7.3). Generally I am
> > running GRASS without any trouble but calling r.terraflow from the
> command
> > line generates the following error comments:
> >
> > MM error: limit =0B. allocating 16B. limit exceeded by 24B.
> > Assertion failed: (0), function operator new, file mm.cc, line 326.
> > Abort trap: 6
> >
> It would help a lot if you could provide exact the command line used
> to invoke r.terraflow. A first guess is that the memory option was set
> to something higher than 2048, because r.terraflow in 6.4.1 can only
> use a maximum of 2GB of memory. Since r.terraflow is very efficient in
> handling temporary data, you could just as well leave out the memory
> option (default is 300MB). Alternatively, you can use r.watershed
> which produces more realistic results.
>
> Markus M
>
> >
> > using the gui generates preety much the same output:
> >
> >
> > tree = etree.fromstring(getInterfaceDescription(cmd))
> >  File "/Applications/GRASS-6.4.app/Contents/MacOS/etc/wxpyt
> > hon/gui_modules/menuform.py", line 1973, in
> > getInterfaceDescription
> >
> > "Details: %s") % (cmd, cmderr)
> > gui_modules.gcmd
> > .
> > GException
> > :
> > Unable to fetch interface description for command
> > 'r.terraflow'. Details: MM error: limit =0B. allocating 16B.
> > limit exceeded by 24B.
> > Assertion failed: (0), function operator new, file mm.cc,
> > line 326.
> >
> >
> > Does anybody knows whats going wrong here.
> > Thanks in advance
> >
> > Thomas
> >
> >
> > --
> > View this message in context:
> http://osgeo-org.1560.n6.nabble.com/trouble-with-r-terraflow-tp4716732p4716732.html
> > Sent from the Grass - Users mailing list archive at Nabble.com.
> > _______________________________________________
> > grass-user mailing list
> > grass-user at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/grass-user
>
>
> ------------------------------
>
> Message: 7
> Date: Mon, 9 Apr 2012 20:42:29 +0200
> From: Markus Neteler <neteler at osgeo.org>
> Subject: Re: [GRASS-user] r.stream.basins addon for grass7 broken
> To: Pankaj Kr Sharma <pkscwc at gmail.com>
> Cc: GRASS user list <grass-user at lists.osgeo.org>,
>        grass-dev at lists.osgeo.org
> Message-ID:
>        <CALFmHhs-zHGQk0XJvRmJxCEPXz3_ceWUrPRgxjxm_2eYXq6Qeg at mail.gmail.com
> >
> Content-Type: text/plain; charset=ISO-8859-1
>
> On Mon, Apr 9, 2012 at 7:02 PM, Pankaj Kr Sharma <pkscwc at gmail.com> wrote:
> > Dear developers,
> > After a considerable break, I was trying to update the things and catch
> up
> > with latest grass.
> > So, I updated with svn up.
> >
> > However, I am stuck at addons.
> >
> > The r.stream.basins addon fails to compile with following message:
> >
> > OBJ.x86_64-unknown-linux-gnu/basins_inputs.o: In function
> `process_vector':
> >
> > r.stream.basins/basins_inputs.c:52: undefined reference to
> > `Vect_new_line_struct'
> ...
>
> I have fixed it in Addons. Please update and retry.
>
> Markus
>
>
> ------------------------------
>
> Message: 8
> Date: Mon, 9 Apr 2012 12:09:10 -0700 (PDT)
> From: tomte <tomte.tumetot at gmx.ch>
> Subject: [GRASS-user] Re: trouble with r.terraflow
> To: grass-user at lists.osgeo.org
> Message-ID: <1333998550782-4716996.post at n6.nabble.com>
> Content-Type: text/plain; charset=us-ascii
>
> below the output of g.region -p
>
>
> GRASS 6.4.1 (kana_cat0206):~/GIS/kanada/modelling/nka_05m/catch_0206_SA >
> g.region -p
> projection: 1 (UTM)
> zone:       11
> datum:      nad83
> ellipsoid:  grs80
> north:      5652250
> south:      5652130
> west:       635585
> east:       635705
> nsres:      5
> ewres:      5
> rows:       24
> cols:       24
> cells:      576
>
>
> Thomas
>
> --
> View this message in context:
> http://osgeo-org.1560.n6.nabble.com/trouble-with-r-terraflow-tp4716732p4716996.html
> Sent from the Grass - Users mailing list archive at Nabble.com.
>
>
> ------------------------------
>
> Message: 9
> Date: Mon, 9 Apr 2012 21:26:30 +0200
> From: Markus Metz <markus.metz.giswork at googlemail.com>
> Subject: Re: [GRASS-user] Re: trouble with r.terraflow
> To: tomte <tomte.tumetot at gmx.ch>
> Cc: grass-user at lists.osgeo.org
> Message-ID:
>        <CAG+h=FHHtfvsRUcV4QBeANh5yTPSRM=NLTrkHsi55GE+K3tZpQ at mail.gmail.com
> >
> Content-Type: text/plain; charset=ISO-8859-1
>
> On Mon, Apr 9, 2012 at 9:09 PM, tomte <tomte.tumetot at gmx.ch> wrote:
> > below the output of g.region -p
> >
> >
> > GRASS 6.4.1 (kana_cat0206):~/GIS/kanada/modelling/nka_05m/catch_0206_SA >
> > g.region -p
> > projection: 1 (UTM)
> > zone:       11
> > datum:      nad83
> > ellipsoid:  grs80
> > north:      5652250
> > south:      5652130
> > west:       635585
> > east:       635705
> > nsres:      5
> > ewres:      5
> > rows:       24
> > cols:       24
> > cells:      576
> >
> Hm, 576 cells is really not a lot, r.terraflow should work. I am still
> puzzled about the "MM error: limit =0B" error. Can you try to set the
> memory option to 200 and report what happens? Alternatively, try
> r.watershed.
>
> Markus M
>
>
> ------------------------------
>
> _______________________________________________
> grass-user mailing list
> grass-user at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-user
>
>
> End of grass-user Digest, Vol 72, Issue 21
> ******************************************
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/grass-user/attachments/20120416/2adb673b/attachment-0001.html


More information about the grass-user mailing list