[Qgis-user] Re: Fwd: Load PostGIS Raster Plugin

Mauricio de Paulo mauricio.dev at gmail.com
Mon Apr 9 19:33:55 PDT 2012


Hi Piotr,
Well, i'm glad to see that you are able to use the plugin. The GDAL 
driver has some performance issues. The solution is use the overviews 
and tiling scheme to improved raster display.

I've just read in the GDAL site that the mosaic inside a table is not 
allowed yet. But another workaround is to create a virtual mosaic using 
VRT and then import it to the database. This way the loader treats every 
file as a single raster and will tile everything together.

I hope these solutions help you achieve your goals.
All the best,
Ps.: I'm copying to qgis user since these solutions might be of interest 
for other users.

Mauricio C. M. de Paulo
Engenheiro Cartógrafo
Mestrando em Sensoriamento Remoto (INPE)


On 04/09/2012 07:41 PM, Piotr Pachół wrote:
> Hello,
> Yes, I would like to load many rasters.
> It's for me important because rasters should cover the area of region 
> or district.
>
> But I made 2 tests loading to PostGIS one raster and two rasters.
>
> With one raster your plugin works OK.
> Both options 'read one row as a raster' and  'read one table as raster'
> are working good although displaying raster is very time consuming.
>
> With two rasters only option 'read one row as a raster' work OK.
> I can display each tile from first and second raster.
> But option 'read one table as raster' doesn't work.
> The message appear: ' could not load PG ...'
>
> Best,
> Piotr
>
> W dniu 2012-04-07 00:16, Mauricio de Paulo pisze:
>> Hi,
>> You used *.tif on your loading command. Are there more than 1 raster 
>> file in that path?
>> I don't know if GDAL's driver is able to read properly more than one 
>> raster file in a table. The last time i checked it was not possible, 
>> but I still have to catch up with their development.
>> You could try loading a single raster and check if it works. That 
>> might be the problem.
>> All the best
>>
>> Mauricio C. M. de Paulo
>> Engenheiro Cartógrafo
>> Mestrando em Sensoriamento Remoto (INPE)
>>
>> On 04/06/2012 05:54 PM, Piotr Pachół wrote:
>>> Hello,
>>> I loaded raster to PostGIS executing following commands:
>>>
>>> raster2pgsql -s 2180 -I -C -M "my path/*.tif" -F -t 128x128 
>>> public.raster128na128 > file1.sql
>>> psql -d raster -f file1.sql
>>>
>>> where:
>>> raster - name of my database
>>> raster128na128 - table in database raster
>>>
>>> loading was OK but as  I wrote before I can display only tile of 
>>> raster but not all raster extent
>>> Regards,
>>> Piotr
>>>
>>> W dniu 2012-04-06 19:39, Mauricio de Paulo pisze:
>>>> Hi Piotr,
>>>> Could you please give me any information on what parameters you set 
>>>> while loading the raster file to postgis?
>>>> I had to disable the loader for a while since the python loader was 
>>>> discontinued by postgis. I'm still researching on how to reactivate 
>>>> it as it is a desired feature.
>>>> All the best,
>>>> Mauricio C. M. de Paulo
>>>> Engenheiro Cartógrafo
>>>> Mestrando em Sensoriamento Remoto (INPE)
>>>>
>>>> On 04/06/2012 10:08 AM, Piotr Pachół wrote:
>>>>> Hello,
>>>>> Could you please help me with below described problem ?
>>>>>
>>>>> Question was sent to qgis-user forum : 
>>>>> http://lists.osgeo.org/pipermail/qgis-user/2012-April/016499.html
>>>>> but I don't know if you check it so I am mailing directly to you.
>>>>>
>>>>> Regards,
>>>>> Piotr
>>>>>
>>>>> ------ Wiadomość oryginalna ------
>>>>> Temat: 	Load PostGIS Raster Plugin
>>>>> Data: 	Wed, 04 Apr 2012 22:32:29 +0200
>>>>> Nadawca: 	Piotr Pachół <piotrpachol at gmail.com>
>>>>> Adresat: 	qgis-user at lists.osgeo.org
>>>>>
>>>>>
>>>>> Hello,
>>>>> I have problems with Load PostGIS Raster Plugin ver. 0.5.3:
>>>>>
>>>>> 1. Icon/function  'Load Raster to PostGIS' is not active. What should I
>>>>> do to make it active ?
>>>>> 2. In icon/function 'Add a PostGIS Raster' Layer I can't load/view
>>>>> raster (in full extent) when I use option 'read one table as raster'
>>>>>      The message appear: ' could not load PG ...'
>>>>>      Option 'read one row as a raster' works OK but I can view only one
>>>>> tile of raster.
>>>>>      May be I used bad options during loading raster files with
>>>>> raster2pgsql command ?
>>>>>      I loaded raster to PostGIS with following options:
>>>>>      raster2pgsql -s 2180 -I -C -M "my path/*.tif" -F -t 128x128
>>>>>
>>>>> My configuration:
>>>>> Windows XP, Qgis 1.9.90-107, PostGIS 2.0
>>>>>
>>>>> Any ideas?
>>>>> Piotr
>>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20120409/f21741d6/attachment.html>


More information about the Qgis-user mailing list