Search This Blog

Tuesday, December 10, 2013

Web Links Dec 2013


Scanning maps and vectorizing them   http://www.gislounge.com/automating-extracting-gis-data-scanned-maps/
Spatial inequality – Census Data   http://www.sasi.group.shef.ac.uk/area_classification/
Interesting infographics   http://flowingdata.com/
Visualisation library for Python  http://bokeh.pydata.org/
Census English indices of deprivation   https://www.gov.uk/government/publications/english-indices-of-deprivation-2010
Quadrocopters – DJI Phantom 2 Vision  http://www.dji.com/feature/phantom-2-vision-features/
Find a PhD -  http://www.findaphd.com/
Interface (Scottish commercial using Uni for R&D) - http://www.interface-online.org.uk/
Autotrace bitmap to vector - http://autotrace.sourceforge.net/

GIS tools
MapTiler - http://www.maptiler.org/
Mapnik -  http://mapnik.org/
TileCache - http://tilecache.org/
Leaflet  - simple CSV - http://blog.perrygeo.net/2013/09/30/leaflet-simple-csv/
Visualising OpenStreetMap Community contributions: https://www.mapbox.com/blog/osm-community-visualized/
Geoforge -geosciences software solutions includes animal tracking tools -  http://www.geoforge.org/softwares.php

Wednesday, September 4, 2013

Sept 2013–List of Interesting Map Web tech

Just some interesting pages that I saw on the web…

http://mapstraction.com/

Mapstraction is a Javascript library that provides a single, common interface for a wide variety of Javascript map APIs. It’s designed to enable a developer to switch from one maps API to another as smoothly and as quickly as possible.

 

http://davidrowley.blogspot.co.nz/2013/08/calculating-line-of-sight-with-postgis.html

Performing Line of Sight analysis from PostGIS

 

http://www.imagico.de/

Map generalisation (coastlines) and ray tracing

 

http://www.klokantech.com/maptiler/

Powerful technology for accelerated pre-rendering of large maps

 

http://mapproxy.org/

MapProxy is an open source proxy for geospatial data. It caches, accelerates and transforms data from existing map services and serves any desktop or web GIS client.

 

https://github.com/NYPL/map-vectorizer

Vectorize raster maps including OCR of text

This project aims to automate a manual process: geographic polygon and attribute data extraction from maps including those from insurance atlases published in the 19th and early 20th centuries.

Tuesday, July 23, 2013

PowerShell–batch search/replace in filenames

I needed to rename a set of files , keeping the original name but adding a suffix. Powershell can do this quite easily using the following:

 

PS C:\data\photos> Dir | Rename-Item -NewName { $_.name -replace ".jpg","_840.jpg" }

 

this will take all .jpg files in the folder and change the name to include an _840.jpg… which in my case was the vertical dimensions of the image set.

Thursday, July 11, 2013

Powershell – how to renumber files sequentially

Sourced from  http://justanothersysadmin.wordpress.com/2008/03/22/bulk-rename-files-with-sequential-index/

here is how to use powershell to renumber files sequentially.. be careful not to renumber files you don’t want renumbered!! Best to move all the files to a new temp folder to do this….

1) copy paste as single line into powershell

function Rename-Bulk($prefix){$files = Get-ChildItem;$id = 1;$files | foreach { Rename-Item -Path $_.fullname -NewName ( $prefix + ((($id++).tostring()).padleft(($files.count.tostring()).length) -replace ' ','0' ) + $_.extension) }}

2) CD to folder in powershell

3)  Rename-Bulk('img')   where img is the prefix for all output with sequential number following

Powershell – Merging files to then load into PostgreSQL

Merging a set of files into one large file

Start PowerShell then use CD to move to the Directory with the files to merge
Get-Content .\*.txt | Out-File c:\temp\merged.txt
This will find all .txt (text) files and merge into a single document in c:\temp folder.

However I found the output was in Unicode format… and to then load this into PostgreSQL
So I  then loaded and saved the file using textpad in UTF-8 format
then create the table in PG….
create table houseprice03_msoa_ew
(la_code text,
la_name text,
msoa_code text,
msoa_name text,
price_all_dwellings_2percentile integer,
price_all_dwellings_lower_quartile integer,
price_all_dwellings__median integer,
price_all_dwellings__upper_quartile integer,
price_all_dwellings_98precentilentile integer,
price_all_dwellings__mean integer
)

and then copy the data into that table…

COPY houseprice03_msoa_ew FROM 'C:\Data\GIS\MartynDorey\CensusData\2003 Houseprices\houseprice2003_G080309_2288_GeoPolicy_MSOA.csv' DELIMITER ',' CSV HEADER;

OSM in 3D – F4

I read a Tweet about a new 3D visualisation of OSM using a new rendering engine.

It includes some animation (eg water surfaces, and fountains)…

Overall the graphic is pretty good.. but the actual data is still poor.

It assumes a flat world with no terrain, and building heights are somewhat arbitrary.

Here’s a view of Edinburgh (Scotland).. looking along Princes Street with Edinburgh Castle on the right, and Calton Hill in the distance. In reality the Castle is way up high on a volcanic plug (hill)… and the gardens infront of it are in a valley.

image

http://map.f4-group.com/#lon=-3.2010387&lat=55.9519892&zoom=17&camera.theta=79.141&camera.phi=-69.901

 

Here’s another view…. this time looking at the Castle from above East Princes Street Gardens (near The Mound)

 

image

 

Here’s a quick comparison of the first image from F4 and Google Earth… as you can see GE includes the topography.

image

Wednesday, June 26, 2013

Installing an ASPX app to IIS on Win2008r2

Steps to install a web app on IIS

1) Write ASPx code etc in Vis Studio

2) Make a folder somewhere and in VS choose publish to File- putting in that folder

3)Zip up that folder and copy folder to server somewhere

4) For some reason the install application button is missing on IIS…

Follow this to add the button:

http://randypaulo.wordpress.com/2011/08/22/iis-7-5-missing-import-application-deployment/

Which tells you to install web deploy from MS

http://www.iis.net/downloads/microsoft/web-deploy

5) Then IMPORT the application – set to the default web site

6) Right click on the folder you imported in IIS and CONVERT TO APPLICATION

7) Possible issues:

- you might need to make a new application pool (check left side of IIS management console for Application Pools) – then set the application to an application pool which is integrated and using .net 4+

- You might need to enable 32bit applications for that new application pool – advanced properties and set 32bit apps to TRUE

- you might find ASPX.NET service isn’t running.. check SERVICES from Start menu / control panel – and set from manual to automatic.. and start it running

- you might need to compile your code for ANY CPU

- don’t forget to copy across all .dlls should happen automatically but worth checking they’re all in the bin folder as required