Archive for the 'GIS Tools' Category

New python qgis plugin… raster file path info…

Monday, January 14th, 2008

http://blog.qgis.org/?q=node/104

As I noted over on the QGIS blog I have started to organize my python plugins and will be adding more soon.

Updated install notes for Mapserver 5.0 with AGG on FC8

Monday, January 14th, 2008

Had the need to install Mapserver/PostGIS/GDAL etc on a FC8 box.  While 99% of what I do now is on Ubuntu (here are some notes and vids on installing there)… I occasionally need to play on a Fedora box.  So, here are some recent install notes from a bare bones FC8 box to get it all going from source…

QGIS on the eee…

Sunday, January 6th, 2008

Well, I got Ubuntu 7.10 installed on an 8 gig SDHC card and away I go…

4.5 gigs used for the base Ubuntu system as well as the base GIS software:

1) Proj4 (4.6.0)
2) GDAL/OGR (1.5.0)
3) GEOS (3.0.0)
4) Postgresql (8.2.5)
5) PostGIS (1.3.2)
6) QT dev environment (4.3.2)
7) QGIS svn (0.9.2)

What do you get? Well, an ultra portable GIS workstation weighing in at less than 2 lbs that is very fun!

Check out a video:

http://www.reprojected.com/presentations/Videos/eee_qgis_install/eee_qgis_install.html

Getting QGIS to install on windows AND support Python apps…

Thursday, October 11th, 2007

So here are the simple (kind of) steps as of today to get a windows install of QGIS working that supports PyQt and the python bindings to QGIS… all with out having to compile anything:

1) Make sure you have Python 2.5 or newer installed on your machine… if you don’t have it you can download it from HERE (official) or HERE (my archive).

2) Install PyQt4.3.1 from HERE (official) or HERE (my archive)

3) Download and unpack THIS zip file. Copy the PyQt4 directory unpacked from the zip into your Python 2.5 site-packages directory. Make sure to save the old PyQt4 directory in the site-packages by renaming it in case something goes wrong!

4) Download and install QGIS from HERE (my archive). This is the latest release candidate from what_nick that is based on the Qt4.3.1 series.

5) In the QGIS install there are some GRASS documentation files that are missing and can cause warning dialogs to pop up when using the GRASS toolbox. You can unzip the contents of THIS archive into the QGISDIR\grass\docs\html directory to stop the warnings.

You can still follow the instructions HERE to build QGIS yourself and play to your hearts content, but I know that there are many windows users out there that really would just like to get moving without the hassle of compiling. This post is for you.

New Open Source Paper Submitted

Friday, March 2nd, 2007

CZ07

Just posted an extended abstract for Coastal Zone 07 to take place in Portland OR July 22nd-26th. Great to get some more Open Source geospatial published…

New build notes for a web-based OSGIS stack on FC3 and FC4

Thursday, January 11th, 2007

I went ahead and added some build notes that I have created in the past for setting up new Fedora based machines with a web GIS stack. Currently building on FC6 and will post soon. Hope this helps some folks out.

FC3 and FC4

Also, added a couple more historical presentations for archiving!

FREE web hosting for non-profits

Saturday, December 9th, 2006

Man you cant get any better than this:

http://wiki.dreamhost.com/index.php/Non-profit_Discount

We at Ecotrust just signed up… can’t beat 1/2 terabyte of storage and 5 terabytes of bandwidth… FREE!

This personal blog is hosted there as well under my personal account, but if you are a non-profit interested in playing with Mapserver/PostGIS/GMT/GRASS you can check out my post on installation in this environment to get up and running with web mapping… FOR FREE!!!

Enjoy

UPDATE (12/09/06): For those who are not in the non-profit world but are still interested in Dreamhost for cheap hosting I just created a promo code that gives the FULL $97 discount to you… Nothing to me.  Dreamhost works on this crazy “reward” system for getting people to use you as a referal, offering a finders fee to the current customer.  I have created this code to apply all of the finders fee to your discount… I get NOTHING.  It is ZPULLEYFULL , enjoy!

New Open Source based web mapping app - Map-Fu

Friday, December 8th, 2006

A local group here at Portland State University has just announced a new mapping interface into the mix. Check out the live demos and download the code. Looks to be a great resource! Thanks guys…

We are delighted to announce a new open source framework for web-mapping, your personal Ninja of web-mapping, ladies and gentlemen, it’s:

*Map-Fu*

Available for download, contribution of code, or reporting of bugs at our not-so-secret location on sourceforge: http://sourceforge.net/projects/map-fu/

It features a true object-oriented PHP-Mapscript backend, with a variety
of classes and interfaces, ease of extensibility, and other
configuration zoink-zoink.

On the front end is a fat Javascript client, using XMLHttpRequest to communicate with the server for updating the map and map-related data. It employs JSON for messaging and goes for a Web 2.0 feel. Some features on the front-end include pop-up tabs for reference map, legend, map information and query results. We try to maximize screen area for the map, since that’s what we are interested in visually!

Based on Minnesota Mapserver (of course) and PostGIS, we developed this interface to satisfy actual needs of clients for creating web-mapping applications that served SPECIFIC needs and required SPECIFIC tools.

Some production sites that are using the Map-Fu or related codebase (formerly known as YAMI (Yet Another Map Interface)):

http://glaciers.us - A database of glacier change in the Western US, including a linked assets database of aerial and oblique photos from the last century

http://www.oregongeology.com/sub/ogdc/index.htm - The most up-to-date geology compilation for Oregon, soon to be used for other states!

http://oscdl.research.pdx.edu/ - Oregon Sustainable
Communities Digital Library, a temporal database of regional planning for the Portland Metro area (ten years of regional planning data, plus links to documents tied to spatial objects)

We look forward to collaborating with a larger group of developers, and receiving feedback on our efforts! We’re interested in incorporating the OpenLayers interface, and “through the web” feature editing via WFS-T.

In the current vacuum of viable enterprise GIS solutions, we see this as a ripe time for rapid development!

The Map-Fu development team,
Morgan, Cris, Tim, Percy & Will
Portland State University
—-

Adding SESSION based data store for Chameleon based apps.

Monday, October 23rd, 2006

I have had a great need for a directory structure like the following in my Chameleon based apps:

SESSION_DIR
|
—>data
|
—>base_data (Base data shared with all apps on file server)
|
—>app_data (Application specific data residing on local server)
|
—>dyn_data (User specific dynamically generated layers)

The way I have tackeled this is to create a new directory in the session space of the Chameleon app and create symbolic links for the base and application data to common data storage areas on my file sservers. Lastly a new directory is created in that session data directory for dynamically created data. Pretty basic, but many questions have been asked to me about this, so here is an example.

index.phtml

// Make sure we have a data dir that is session based:
// sessionSavePath/data/base_data -> symbolic link to base data dir (shared)
// sessionSavePath/data/app_data -> application specific data (shared)
// sessionSavePath/data/dyn_data -> user specific dynamic data (not shared)
// If the directory does not exist, then we need to make one.
$data_dir = getSessionSavePath()."/data";
$data_base_dir = $data_dir."/base_data";
$data_app_dir = $data_dir."/app_data";
$data_dyn_dir = $data_dir."/dyn_data";
//save the current application working directory
$cwd = getcwd();
if (!file_exists($data_dir))
{
// Here we make the session data dir
$dir_exec = sprintf("mkdir ".$data_dir);
exec ($dir_exec,$arr,$err1);
$_SESSION['sessDataDir'] = $data_dir;
// Here we make the user dynamic data dir
$dir_exec = sprintf("mkdir ".$data_dyn_dir);
exec ($dir_exec,$arr,$err1);
// Here we make the base data link
$dir_exec = sprintf("ln -s ".
$cwd."/../../base_data ".$data_base_dir);
exec ($dir_exec,$arr,$err1);
// Here we make the app data link
$dir_exec = sprintf("ln -s ".
$cwd."/../app_data ".$data_app_dir);
exec ($dir_exec,$arr,$err1);
}
// Finally we modify the data path of our map object
$oMap = $oApp->moMapSession->getMapObj();
$oMap->set("shapepath", $data_dir);

mapfile.map

# For base data items
DATA Political/counties.shp
becomes...
DATA base_data/Political/counties.shp
<code># For app specific data
DATA Marinezones/contiguous_us_eez.shp
becomes...
DATA app_data/Marinezones/contiguous_us_eez.shp
<code># For dynamic data
Most apps will just create a layer dynamically in Mapscript and point the data statement toward the dyn_data directory.

That is it. Pretty basic, but allows you to keep your data separated between base data all apps will use, application specific data, and data that is generated dynamically by users on the fly.

Web-GIS on the cheap…

Monday, October 23rd, 2006

OK, I have servers at work that I use daily to develop Mapserver/GDAL/OGR/GRASS/GMT/etc… based apps, but how about on a shared hosting environment?

Well, I finally got it going. I have written up my install instructions for Mapserver/GDAL/OGR/Proj/Postgres/Postgis/Geos/GMT/GRASS on Dreamhost, a debian based shared hosting service. The great thing about it…

1) It cost $9.95/month (1 year contract) *12 = $119.40

2) You can use a discount code to get $97 off… Total cost at sign-up = $119.40-$97 = $22.40

UPDATE (12/09/06): I just created a propmo code that gives the FULL discount to you… Nothing to me.  It is ZPULLEYFULL , enjoy!

3) Add a domain for $9.95 and the first year of this site cost $32.35 … WOW

With this package I get 200 Gigs of space (grows weekely!) and 1 Terabyte of bandwidth/month (grows weekly!).

So what good is it if I cant do some mapping work with it? Well, I have posted notes how I was able to get a fully functional Mapserver/PostGIS environment up. I went as far as to get command line GRASS installed to do geo-processing sans the GUI. GMT installed like a breeze, and bammmm… a GIS work environment.

Cant beat the rent ;-)

Check out some demo’s running on the server:

1) ka-map

2) GMT

pretzel:~/usr/local/src/gmt/GMT4.1.2/examples> ./do_examples.csh
Doing example 01…done
Doing example 02…done
Doing example 03…done
Doing example 04…done
Doing example 05…done
Doing example 06…done
Doing example 07…done
Doing example 08…done
Doing example 09…done
Doing example 10…done
Doing example 11…done
Doing example 12…done
Doing example 13…done
Doing example 14…done
Doing example 15…done
Doing example 16…done
Doing example 17…done
Doing example 18…done
Doing example 19…done
Doing example 20…done
Doing example 21…done
Doing example 22…done
Doing example 23…done
Doing example 24…done
Doing example 25…done
Completed all examples
pretzel:~/usr/local/src/gmt/GMT4.1.2/examples>

Check out the Output Images

3) GRASS

IMPORT ——>

GRASS 6.1.cvs > r.in.gdal input=world-topo-bathy-97_32_84_24.tif output=bmng_grass location=blue_marble
A datum name wgs84 (WGS_1984) was specified without transformation parameters.
Note that the GRASS default for wgs84 is towgs84=0.000,0.000,0.000.
100%
CREATING SUPPORT FILES FOR bmng_grass.red
SETTING GREY COLOR TABLE FOR bmng_grass.red (8bit, full range)
100%
CREATING SUPPORT FILES FOR bmng_grass.green
SETTING GREY COLOR TABLE FOR bmng_grass.green (8bit, full range)
100%
CREATING SUPPORT FILES FOR bmng_grass.blue
SETTING GREY COLOR TABLE FOR bmng_grass.blue (8bit, full range)
r.in.gdal complete.
Mapset in Location
GRASS 6.1.cvs>

VERIFY ——->

Welcome to GRASS 6.1.cvs (2006)
GRASS homepage: http://grass.itc.it/
This version running thru: TC Shell (/usr/bin/tcsh)
Help is available with the command: g.manual -i
See the licence terms with: g.version -c
Start the graphical user interface with: gis.m &
When ready to quit enter: exit
Mapset in Location GRASS 6.1.cvs > g.list type=rast
----------------------------------------------
raster files available in mapset PERMANENT:
bmng_grass.blue bmng_grass.green bmng_grass.red

----------------------------------------------
Mapset in Location GRASS 6.1.cvs>

Thats it for now… Up and running!!!!!!