Hi Hamish and Michael,
your questions are connected I will try to explain both. The scatter plot tool backend is run in same process as wxGUI. If you select some area in scatter plot, then data from numpy arrays are passed to the backend (through ctypes), which describes selected areas in scatters plots. And the backend computes corresponding areas which will be highlighted in all opened scatter plots. To avoid frozing of the wxGUI, the computation is done in separate python thread. Currently r.out.bin is used to bypass inability to set region in raster library for different rasters. When user choose raster group for analysis in the tool, it is exported into binary files in current region and the backend works directly with the binary files. This is not very nice. If the backend would be written as module, then I would need to create temporary files to pass the selected areas, which does not seem very elegant to me. In simplified way the idea is that the library should give you option whether you want to open and then work with raster file according to the statically set variables (in structure R__) or open it with dynamically defined variables. It could be also useful for Pietro's pyGRASS API. And it would be first small step to achieve compilation of raster modules as library instead of different programs. I am working on more concrete proposal of the changes in raster library during this weekend. I am new to this problematic, so all these suggestions can be totally wrong.. Best Stepan ---------- Původní zpráva ---------- Od: Michael Barton <[email protected]> Datum: 6. 7. 2013 Předmět: Re: [SoC] Weekly report #3 - GRASS Interactive Scatter Plot Tool "So I take it you are not using r.stats to generate the data to plot, but are getting data directly accessing rasters via GRASS libraries? Michael ______________________________" Hi, I am interested to hear more about the library limitations.. you mean the WIND region, right? I'd be surprised if WIND_OVERRIDE or GRASS_REGION enviro variables (and the python wrappers for them) didn't provide full control for whatever someone might like to do. I would guess if the scatter tool was spawned as an independent process, it could maintain its own environment & so it's own region override enviro variables. or simply unset the wxGUI display overrides and just use the mapset's real computational region read directly from the WIND file? regards, Hamish
_______________________________________________ grass-dev mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/grass-dev
