[postgis-users] help in storing tif file

Gregory S. Williamson gsw at globexplorer.com
Fri Mar 24 05:09:58 PST 2006


Harshal D. asked:

> 
> can u elaborate further details. that will be great help.
> 
> Thanks and Regards

Well, not wanting to speak Msr. Ribot, but as far as our site goes, we have quite a lot of raster imagery (many terabytes) from many sources and of quite different types (resolution, color, etc.).

When we started the web site we decided that stuffing the various images, which range in size from small (< 20k) to quite large (I think there may be some MrSid files that are gigabytes in size), it didn't make sense to put in the database itself. We used, and still use, these wildly expensive beasts called filers which can support *many* simulataneous requests. If we used the DB to hold them the sheer volume of data moving throught he system would cause the cache of DB stuff to thrash. [I have done systems where we could tune the page size of the database and stuff BLOBs with images].

What we do need to be able to get quickly is a description of the imagery in an area, so in our runtime database we have a unique id for each image, the primary and secondary locations of the image itself, some basic information (color, resolution, source) and the shape [the idea of using just the bounding box is a good one but for various reasons we use the actual shape of the image].

When our middleware process gets a request it queries the database and gets a list of tiles (raster images) that are in that box; another program composes the image a client sees based on quality and the like. If a client needs precise data on an image we handle that in a metadata table which does not store spatial data; only the unique identifier of the tile and then a whole slew of stuff [who, where, when, how the image was taken].

Since most of the vector data -- the image itself -- does not have data that is queriable we only put stuff into the database that a user might need to ask about in a relational database context. We let the filers and other image related systems handle the streaming of the vector data, and let the databases build a cache of spatial data. Typically our DBs have several hundred connections each, and handle many dozens of spatial queries a second at peak, almost all of it cached.

HTH, and that I haven't gone overboard. Others may have equally valid experience in putting images into the database itself.

Greg Williamson
DBA
GlobeXplorer LLC

Nicolas Ribot wrote:

>>Dear all,
>>
>>I am newbie in the postgis. I am trying to store tif image file to postgis.
>>
>>pls suggest me the way.
>>
>>    
>>
>
>Hi Harshal,
>I personally leave the raster files on the disk and just reference
>them in Postgis, by putting in some table(s) raster's bounding box,
>full path to the file, some raster informations (bands, domain of
>study, etc.)
>
>Nicolas
>_______________________________________________
>postgis-users mailing list
>postgis-users at postgis.refractions.net
>http://postgis.refractions.net/mailman/listinfo/postgis-users
>
>
>  
>


_______________________________________________
postgis-users mailing list
postgis-users at postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users

!DSPAM:4423dcac64591222944467!








More information about the postgis-users mailing list