[MapProxy] Difficulty setting up Custom Projections

Oliver Tonnhofer olt at omniscale.de
Wed Jun 9 11:46:51 EDT 2010


On 09.06.2010, at 16:29, Marc Harter wrote:
>> Yes. I should be the same as the data dir from proj4. For EPSG  
>> codes only the epsg file is needed, AFAIK. Can you try to copy the  
>> pyproj data dir to your MapProxy etc dir? And use:
>> srs:
>> proj_data_dir: ./data
> Oh it should be the same.  That makes sense.  I find that data  
> directory under the pyproj folder in the MapProxy install.  Seems  
> like that is what is being used by default if nothing is specified  
> in proxy.yaml.

No, not the same :) Sorry, I mean that the directory should have the  
same structure as the (py)proj data directory. Pyproj uses the files  
in the data dir ('../site-packages/pyproj/data') by default. If you  
want to use you own definitions you can configure another location  
with the proj_data_dir option. Pyproj will look in that directory for  
the srs definitions.

You can modify the pyproj data files in-place, but its not recommended  
since the files might be removed/modified when pyproj gets updated.

>> And can you tell me the versions of PyProj, Python and MapProxy you  
>> use?
> I'm running MapProxy 0.8.3, so whatever PyProj comes with that and  
> Python 2.6.

Hmmm, I can't reproduce that. It works for me with a proxy.yaml:
   proj_data_dir: './srs'

and the following directory structure:

(mapproxy)os at proxy-debian:~/mapproxy/conf$ find etc/

You should see an info message when you start MapProxy with paster:
(mapproxy)os at proxy-debian:~/mapproxy/conf$ paster serve etc/develop.ini
2010-06-09 02:51:37,068 - INFO - 3076:mapproxy.core.srs:_init_proj -  
loading proj data from /home/os/mapproxy/conf/etc/./srs


Oliver Tonnhofer <olt at omniscale.de>
Omniscale - Dominik Helle, Oliver Tonnhofer GbR
Nadorster Str. 60, 26123 Oldenburg
Tel: +49(0)441/9392774-2 (Fax: 9)

More information about the MapProxy mailing list