Re: [GRASS-user] Probabilistic neighborhood analysis

2023-01-10 Thread Moritz Lennert

10 janv. 2023 08:46:42 Maris Nartiss :

> Hello Bernardo,
> although a solution with r.mapcalc random could be made to work, I'd
> say creating a new dedicated module is the way to go. Just an idea –
> create neighbour count raster (how many cells with centre class are in
> a sliding window), in second pass unroll classes based on their count
> and then choose random class from obtained list.
> 
> I don't think it is so common to infill (inpaint) categorical values
> in classification results of remote sensing.

I think this is quite common. However, it is generally done using majority 
rules or similar. I don't think I have seen much use of randomization in that 
context.

Moritz
___
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] How to use g.extension in GRASS7.8

2023-01-10 Thread Bernardo Santos via grass-user
 Hi Stefan,
this worked perfectly for now! Thanks!BestBernardo
Em terça-feira, 10 de janeiro de 2023 07:37:15 GMT+1, Stefan Blumentrath 
 escreveu:  
 
 Hei Bernardo,

The problem is likely that the layout of the addon repo changed after 7.8.5, 
thus the path is not constructed correctly by g.extension in that version.

A workaround could be to fetch the add on repo with git (git clone 
https://github.com/osgeo/grass-addons)

And then point g.extension to your local copy:
g.extension extension=r.area url=./grass-addons/src/raster/r.area

You may need a zip file, but you can try the above first...

Good luck.. 

Cheers,
Stefan

> Gesendet: Montag, den 09.01.2023 um 21:14 Uhr
> Von: "Bernardo Santos via grass-user" 
> An: "Markus Neteler" 
> Cc: "GRASS User List" 
> Betreff: Re: [GRASS-user] How to use g.extension in GRASS7.8
> 
>  Hi Markus and Vero,
> Thanks. Indeed, my GRASS version is old:GRASS 7.8.5Ubuntu 18.04.6 LTS
> I unfortunately do not have a way to upgrade it myself since this is a 
> company server shared with other people (and we have been fighting with IT to 
> change to GRASS 8).But maybe it is easier to at lease update GRASS to version 
> 7.8.7 (or 7.8.8).
> I just talked to a colleague (@mauricio.vancince) who mentioned he had the 
> same problem but could overcome it opening the terminal as a superuser and 
> using g.extension r.area -sUnfortunately I do not have admin rights, but I 
> will see what is possible to be done.
> Thanks!BestBernardo 
>    Em segunda-feira, 9 de janeiro de 2023 15:19:07 GMT+1, Markus Neteler 
> escreveu:  
>  
>  Hi Bernardo,
> 
> On Mon, Jan 9, 2023 at 2:58 PM Bernardo Santos
>  wrote:
> >
> > Hi Markus,
> >
> > That was my first try, and then I get the error below:
> >
> > > g.extension extension=r.area
> > Fetching  from GRASS GIS Addons repository (be patient)...
> > svn: E17: URL 
> > 'https://github.com/OSGeo/grass-addons/trunk/grass7/raster/r.area' doesn't 
> > exist
> > ERROR: GRASS Addons  not found
> 
> Ah right. Then your GRASS GIS 7.8 version may be too old. G 7.8.7
> should be ok (G 7.8.8 is on the way these days) but in any case, as
> Vero pointed out, we highly recommend to upgrade to GRASS GIS 8.2.x.
> 
> Best,
> Markus
>  ___
> grass-user mailing list
> grass-user@lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/grass-user
___
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user
  ___
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user


Re: [GRASS-user] How to use g.extension in GRASS7.8

2023-01-10 Thread Asim via grass-user


On 1/10/23 1:44 AM, Bernardo Santos via grass-user wrote:
I unfortunately do not have a way to upgrade it myself since this is a 
company server shared with other people (and we have been fighting 
with IT to change to GRASS 8).
But maybe it is easier to at lease update GRASS to version 7.8.7 (or 
7.8.8).


A workaround, without having to upgrade GRASS (which is not a good 
idea), is to clone the grass-addons repo and supply a local path as 
extension URL.


    git clone -b grass7 https://github.com/OSGeo/grass-addons 
$PWD/grass-addons

    g.extension extension=r.area url=$PWD/grass-addons/src/raster/r.area

Asim


___
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user