Suggestion for WPS: Support for R stat package

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Suggestion for WPS: Support for R stat package

Martinjensen
I am really thrilled by the potential of WPS in Geoserver. 

I have been using R spatial (http://r-spatial.sourceforge.net/) with postgresql (http://bostongis.com/?content_name=postgresql_plr_tut01#87) and I think it would be great for the WPS roadmap to consider support for R processes.


Any thouhgts on support for R in Geoserver WPS?






--
Med venlig hilsen

Martin Bjærge Jensen

------------------------------------------------------------------------------
Lotusphere 2011
Register now for Lotusphere 2011 and learn how
to connect the dots, take your collaborative environment
to the next level, and enter the era of Social Business.
http://p.sf.net/sfu/lotusphere-d2d
_______________________________________________
Geoserver-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/geoserver-users
Reply | Threaded
Open this post in threaded view
|

Re: Suggestion for WPS: Support for R stat package

geowolf
On Wed, Dec 15, 2010 at 11:32 PM, Martin Jensen
<[hidden email]> wrote:
> I am really thrilled by the potential of WPS in Geoserver.
> I have been using R spatial (http://r-spatial.sourceforge.net/) with
> postgresql (http://bostongis.com/?content_name=postgresql_plr_tut01#87) and
> I think it would be great for the WPS roadmap to consider support for R
> processes.
> http://www.r-project.org/
> Any thouhgts on support for R in Geoserver WPS?

Oh yeah, having R support would be indeed very nice (as it would be to
have GRASS support).

Afaik there are two challenges to overcome.
The first is technical, about the communication between a Java based
process and R.
I think there is something around but not sure what the maintainance status

The second is resourcing: new developments happen when either there is
something that needs it
that can also code, or when someone shows up with funding geared
towards a professional
GeoServer supporter (see the commercial support page).

As far as I know at the moment we don't have neither the first, nor the second,
but we can hope that will happen sometimes soon in the future :-)

Cheers
Andrea

-----------------------------------------------------
Ing. Andrea Aime
Senior Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584962313
fax:     +39 0584962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

-----------------------------------------------------

------------------------------------------------------------------------------
Lotusphere 2011
Register now for Lotusphere 2011 and learn how
to connect the dots, take your collaborative environment
to the next level, and enter the era of Social Business.
http://p.sf.net/sfu/lotusphere-d2d
_______________________________________________
Geoserver-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/geoserver-users
Reply | Threaded
Open this post in threaded view
|

Re: Suggestion for WPS: Support for R stat package

Martinjensen
Thanks for the reply!

I hope i'll bump into a project that can finance this!

As for a short term solution, maybe R could be suported through my Postgis datastore wehere I have  R -functions based on the PL/R language.

Is it possible to make a WPS process using the Postgis functions as backend ?

Martin




2010/12/16 Andrea Aime <[hidden email]>
On Wed, Dec 15, 2010 at 11:32 PM, Martin Jensen
<[hidden email]> wrote:
> I am really thrilled by the potential of WPS in Geoserver.
> I have been using R spatial (http://r-spatial.sourceforge.net/) with
> postgresql (http://bostongis.com/?content_name=postgresql_plr_tut01#87) and
> I think it would be great for the WPS roadmap to consider support for R
> processes.
> http://www.r-project.org/
> Any thouhgts on support for R in Geoserver WPS?

Oh yeah, having R support would be indeed very nice (as it would be to
have GRASS support).

Afaik there are two challenges to overcome.
The first is technical, about the communication between a Java based
process and R.
I think there is something around but not sure what the maintainance status

The second is resourcing: new developments happen when either there is
something that needs it
that can also code, or when someone shows up with funding geared
towards a professional
GeoServer supporter (see the commercial support page).

As far as I know at the moment we don't have neither the first, nor the second,
but we can hope that will happen sometimes soon in the future :-)

Cheers
Andrea

-----------------------------------------------------
Ing. Andrea Aime
Senior Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584962313
fax:     +39 0584962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

-----------------------------------------------------



--
Med venlig hilsen

Martin Bjærge Jensen

------------------------------------------------------------------------------
Lotusphere 2011
Register now for Lotusphere 2011 and learn how
to connect the dots, take your collaborative environment
to the next level, and enter the era of Social Business.
http://p.sf.net/sfu/lotusphere-d2d
_______________________________________________
Geoserver-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/geoserver-users
Reply | Threaded
Open this post in threaded view
|

Re: Suggestion for WPS: Support for R stat package

geowolf
On Sat, Dec 18, 2010 at 10:16 AM, Martin Jensen
<[hidden email]> wrote:
> Thanks for the reply!
>
> I hope i'll bump into a project that can finance this!
>
> As for a short term solution, maybe R could be suported through my Postgis
> datastore wehere I have  R -functions based on the PL/R language.
>
> Is it possible to make a WPS process using the Postgis functions as backend

I think it is, thought I never tried that.
A WPS process should be able to take data from anywhere, from a remote WFS,
WCS and so on.
Our WPS architecture abstracts that away from you, your process just need to
take in GeoTools FeatureCollection (vector data) or GridCoverage
(raster data) objects,
and the framework will take care of dealing with all the possible
input formats.
Here are two possibe examples, one dealing with raster data. the other with
vector data:
http://svn.codehaus.org/geoserver/trunk/src/extension/wps/wps-core/src/main/java/org/geoserver/wps/gs/StyleCoverage.java
http://svn.codehaus.org/geoserver/trunk/src/extension/wps/wps-core/src/main/java/org/geoserver/wps/gs/RectangularClipProcess.java

A process that actually backs onto PostgreSQL provided functions would have
to then connect to postgres, send the data over (I think, in a temporary table),
run the computation, grab the result back as another feature collection,
and clean up after the fact.
Pretty doable, with a lot of code that can be reused from one pg backed process
to the other, so it would be possible to make this easy by creating a base class
or a set of utilities that factor out all the commonly reusable parts.

Hope this helps

Cheers
Andrea

> ?
>
> Martin
>
>
>
>
> 2010/12/16 Andrea Aime <[hidden email]>
>>
>> On Wed, Dec 15, 2010 at 11:32 PM, Martin Jensen
>> <[hidden email]> wrote:
>> > I am really thrilled by the potential of WPS in Geoserver.
>> > I have been using R spatial (http://r-spatial.sourceforge.net/) with
>> > postgresql
>> > (http://bostongis.com/?content_name=postgresql_plr_tut01#87) and
>> > I think it would be great for the WPS roadmap to consider support for R
>> > processes.
>> > http://www.r-project.org/
>> > Any thouhgts on support for R in Geoserver WPS?
>>
>> Oh yeah, having R support would be indeed very nice (as it would be to
>> have GRASS support).
>>
>> Afaik there are two challenges to overcome.
>> The first is technical, about the communication between a Java based
>> process and R.
>> I think there is something around but not sure what the maintainance
>> status
>>
>> The second is resourcing: new developments happen when either there is
>> something that needs it
>> that can also code, or when someone shows up with funding geared
>> towards a professional
>> GeoServer supporter (see the commercial support page).
>>
>> As far as I know at the moment we don't have neither the first, nor the
>> second,
>> but we can hope that will happen sometimes soon in the future :-)
>>
>> Cheers
>> Andrea
>>
>> -----------------------------------------------------
>> Ing. Andrea Aime
>> Senior Software Engineer
>>
>> GeoSolutions S.A.S.
>> Via Poggio alle Viti 1187
>> 55054  Massarosa (LU)
>> Italy
>>
>> phone: +39 0584962313
>> fax:     +39 0584962313
>>
>> http://www.geo-solutions.it
>> http://geo-solutions.blogspot.com/
>> http://www.linkedin.com/in/andreaaime
>> http://twitter.com/geowolf
>>
>> -----------------------------------------------------
>
>
>
> --
> Med venlig hilsen
>
> Martin Bjærge Jensen
>



--
-----------------------------------------------------
Ing. Andrea Aime
Senior Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584962313
fax:     +39 0584962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

-----------------------------------------------------

------------------------------------------------------------------------------
Lotusphere 2011
Register now for Lotusphere 2011 and learn how
to connect the dots, take your collaborative environment
to the next level, and enter the era of Social Business.
http://p.sf.net/sfu/lotusphere-d2d
_______________________________________________
Geoserver-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/geoserver-users
Reply | Threaded
Open this post in threaded view
|

Re: Suggestion for WPS: Support for R stat package

Martinjensen
Thanks for the answer!

Regarding Postgis backend I was thinking (hoping)  about a really simple model:

Just write the sql statement with parameters:

SELECT St_buffer([WPS_INPUT_GEOM], 100) as WPS_OUTPUT_GEOM.

/Martin



2010/12/18 Andrea Aime <[hidden email]>
On Sat, Dec 18, 2010 at 10:16 AM, Martin Jensen
<[hidden email]> wrote:
> Thanks for the reply!
>
> I hope i'll bump into a project that can finance this!
>
> As for a short term solution, maybe R could be suported through my Postgis
> datastore wehere I have  R -functions based on the PL/R language.
>
> Is it possible to make a WPS process using the Postgis functions as backend

I think it is, thought I never tried that.
A WPS process should be able to take data from anywhere, from a remote WFS,
WCS and so on.
Our WPS architecture abstracts that away from you, your process just need to
take in GeoTools FeatureCollection (vector data) or GridCoverage
(raster data) objects,
and the framework will take care of dealing with all the possible
input formats.
Here are two possibe examples, one dealing with raster data. the other with
vector data:
http://svn.codehaus.org/geoserver/trunk/src/extension/wps/wps-core/src/main/java/org/geoserver/wps/gs/StyleCoverage.java
http://svn.codehaus.org/geoserver/trunk/src/extension/wps/wps-core/src/main/java/org/geoserver/wps/gs/RectangularClipProcess.java

A process that actually backs onto PostgreSQL provided functions would have
to then connect to postgres, send the data over (I think, in a temporary table),
run the computation, grab the result back as another feature collection,
and clean up after the fact.
Pretty doable, with a lot of code that can be reused from one pg backed process
to the other, so it would be possible to make this easy by creating a base class
or a set of utilities that factor out all the commonly reusable parts.

Hope this helps

Cheers
Andrea

> ?
>
> Martin
>
>
>
>
> 2010/12/16 Andrea Aime <[hidden email]>
>>
>> On Wed, Dec 15, 2010 at 11:32 PM, Martin Jensen
>> <[hidden email]> wrote:
>> > I am really thrilled by the potential of WPS in Geoserver.
>> > I have been using R spatial (http://r-spatial.sourceforge.net/) with
>> > postgresql
>> > (http://bostongis.com/?content_name=postgresql_plr_tut01#87) and
>> > I think it would be great for the WPS roadmap to consider support for R
>> > processes.
>> > http://www.r-project.org/
>> > Any thouhgts on support for R in Geoserver WPS?
>>
>> Oh yeah, having R support would be indeed very nice (as it would be to
>> have GRASS support).
>>
>> Afaik there are two challenges to overcome.
>> The first is technical, about the communication between a Java based
>> process and R.
>> I think there is something around but not sure what the maintainance
>> status
>>
>> The second is resourcing: new developments happen when either there is
>> something that needs it
>> that can also code, or when someone shows up with funding geared
>> towards a professional
>> GeoServer supporter (see the commercial support page).
>>
>> As far as I know at the moment we don't have neither the first, nor the
>> second,
>> but we can hope that will happen sometimes soon in the future :-)
>>
>> Cheers
>> Andrea
>>
>> -----------------------------------------------------
>> Ing. Andrea Aime
>> Senior Software Engineer
>>
>> GeoSolutions S.A.S.
>> Via Poggio alle Viti 1187
>> 55054  Massarosa (LU)
>> Italy
>>
>> phone: +39 0584962313
>> fax:     +39 0584962313
>>
>> http://www.geo-solutions.it
>> http://geo-solutions.blogspot.com/
>> http://www.linkedin.com/in/andreaaime
>> http://twitter.com/geowolf
>>
>> -----------------------------------------------------
>
>
>
> --
> Med venlig hilsen
>
> Martin Bjærge Jensen
>



--
-----------------------------------------------------
Ing. Andrea Aime
Senior Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584962313
fax:     +39 0584962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

-----------------------------------------------------



--
Med venlig hilsen

Martin Bjærge Jensen

------------------------------------------------------------------------------
Got Input?   Slashdot Needs You.
Take our quick survey online.  Come on, we don't ask for help often.
Plus, you'll get a chance to win $100 to spend on ThinkGeek.
http://p.sf.net/sfu/slashdot-survey
_______________________________________________
Geoserver-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/geoserver-users
Reply | Threaded
Open this post in threaded view
|

Re: Suggestion for WPS: Support for R stat package

geowolf
On Sun, Jul 31, 2011 at 9:45 PM, Martin Jensen
<[hidden email]> wrote:
> Thanks for the answer!
> Regarding Postgis backend I was thinking (hoping)  about a really simple
> model:
> Just write the sql statement with parameters:
> SELECT St_buffer([WPS_INPUT_GEOM], 100) as WPS_OUTPUT_GEOM.

This process already exists, look for JTS:Buffer, it does exactly that
(in 3 lines
of code or so).

For more complex processes that deal with feature collections what I've said
before is still valid

Cheers
Andrea


--
-------------------------------------------------------
Ing. Andrea Aime
GeoSolutions S.A.S.
Tech lead

Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584 962313
fax:      +39 0584 962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

-------------------------------------------------------

------------------------------------------------------------------------------
Got Input?   Slashdot Needs You.
Take our quick survey online.  Come on, we don't ask for help often.
Plus, you'll get a chance to win $100 to spend on ThinkGeek.
http://p.sf.net/sfu/slashdot-survey
_______________________________________________
Geoserver-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/geoserver-users
Reply | Threaded
Open this post in threaded view
|

Re: Suggestion for WPS: Support for R stat package

Martinjensen
I know jts:buffer exists. Just to make a simple example.

The reason why SQL is another supplementary approach is because many GIS admins don't code at all but master SQL instead, hence GIS admins would make a WPS process with configuration instead of code. Furthermore, I think (maybe I'm wrong) his approach makes it easy to make content specific WPS processes with local data. Like this simple example:

SELECT sum (column1) as OUTPUT1, sum(coluimn2) as OUTPUT2, avg(column3) as OUTPUT3, sum(column4) as OUTPUT4, sum(column5) as OUTPUT5 FROM schema.table. g
                            WHERE st_intersects(g.the_geom, ST_GeometryFromText('[INPUT]',25832))

That said, I'm thrilled about the WPS work in Geoserver already, and with the python extension it is even more flexible!


/Martin
Keep up the fantastic work!


2011/7/31 Andrea Aime <[hidden email]>
On Sun, Jul 31, 2011 at 9:45 PM, Martin Jensen
<[hidden email]> wrote:
> Thanks for the answer!
> Regarding Postgis backend I was thinking (hoping)  about a really simple
> model:
> Just write the sql statement with parameters:
> SELECT St_buffer([WPS_INPUT_GEOM], 100) as WPS_OUTPUT_GEOM.

This process already exists, look for JTS:Buffer, it does exactly that
(in 3 lines
of code or so).

For more complex processes that deal with feature collections what I've said
before is still valid

Cheers
Andrea


--
-------------------------------------------------------
Ing. Andrea Aime
GeoSolutions S.A.S.
Tech lead

Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584 962313
fax:      +39 0584 962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

-------------------------------------------------------



--
Med venlig hilsen

Martin Bjærge Jensen

------------------------------------------------------------------------------
BlackBerry&reg; DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts.
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
_______________________________________________
Geoserver-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/geoserver-users