[GRASS-user] Newbie adding additional modules?
David Finlayson
david.p.finlayson at gmail.com
Tue Jun 27 03:06:24 EDT 2006
Another route that does not involve recompiling GRASS is to write a Python
script to export the data from GRASS into an ASCII format, read the data
into a numeric python array (NumPy) and then use the included netCDF module
in NumPy to create your netCDF:
http://www-md.fsl.noaa.gov/eft/developer/netCDFPythonInterface.html
On 6/26/06, Nagesh Bhatkar <bnagesh at nio.org> wrote:
>
> Copy the r.out.netcdf module into the ~/grass-6.0.0/raster/ source
> directory
> Create a Makefile in the r.out.netcdf directory if there doesnt exist
> one, and then run
> "make" . If the Makefile already exist, make sure -lnetcdf is added to
> the LIBES
> The following is the Makefile:
>
>
> MODULE_TOPDIR = ../..
>
> PGM = r.out.netcdf
>
> LIBES = $(D_LIB) $(DISPLAYLIB) $(RASTERLIB) $(GISLIB) -lnetcdf
> DEPENDENCIES= $(D_DEP) $(DISPLAYDEP) $(RASTERDEP) $(GISDEP)
>
> include $(MODULE_TOPDIR)/include/Make/Module.make
>
> default: cmd
>
>
>
>
>
>
>
>
>
>
> Hamish wrote:
>
> >Barry Baker wrote:
> >
> >
> >
> >>It has been nearly 16 years since I used Grass and now coming back.
> >>I have GRASS up and running on my Mac PowerBook G4 with OS X 10.4.6
> >>
> >>
> >
> >!!
> >
> >
> >
> >>Now I am trying to install the r.out.netcdf module and am at a loss as
> >>to how to go about it. Any help would be appreciated.
> >>
> >>
> >
> >Unless r.out.netcdf is packaged for the new GRASS 6.1 Extension Manager
> >(GEM), and I'm pretty sure it isn't, you will need the full grass source
> >code to compile it.
> >
> >after ./configure, make of source code,
> >
> >mkdir raster/r.out.netcdf/
> >cd raster/r.out.netcdf/
> >cp r.out.netcdf_source_files/* .
> >make
> >
> >
> >alternatively and probably simpler, use r.out.gdal for NetCDF output:
> >
> >GRASS> gdalinfo --formats
> > GMT (rw): GMT NetCDF Grid Format
> > netCDF (ro): network Common Data Format
> >
> >In my old version of GDAL, the GMT version is only one which it can
> >write to. I'm not sure what the latest version can do.
> >
> >http://www.gdal.org/formats_list.html
> >
> >another indirect way is to use r.out.mat to make a Matlab array and
> >to save a NetCDF file from there. (r.out.mat is untested on big-endian
> >AFAIK, if that doesn't work use raw r.out.bin -> Matlab)
> >
> >If you are looking to send output to GMT, there are other options &
> >scripts that can be used. see r.out.gmt on the wiki add-ons page and:
> > http://169.237.35.250/~dylan/grass_user_group/#GMT_and_GRASS-overview
> >
> >
> >
> >Hamish
> >
> >_______________________________________________
> >grassuser mailing list
> >grassuser at grass.itc.it
> >http://grass.itc.it/mailman/listinfo/grassuser
> >
> >
> >
> >
>
> _______________________________________________
> grassuser mailing list
> grassuser at grass.itc.it
> http://grass.itc.it/mailman/listinfo/grassuser
>
--
David Finlayson
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/grass-user/attachments/20060627/3fe0fc18/attachment.html
More information about the grass-user
mailing list