Hot answers tagged

6

Your source tif is in Pseudo mercator, but the extent stored inside the file is in degrees. This can not be interpreted correctly by gdalwarp, and so it delivers the untouched source file. You can get the correct extent in pseudo mercator coordinates from https://github.com/mapnik/mapnik/wiki/XMLConfigReference : -20037508.34, -20037508.34, 20037508.34, ...


5

Depending on where you create the VRT, it will either become a relative path, or an absolute path. You can manually set this, by modifying the relativeToVRT="1"to a 0, and then write a complete path in the instead of just the image filename. See the example below of a full path VRT. <VRTRasterBand dataType="Byte" band="1"> <ColorInterp>...


5

This can be achieved with the help of GDAL's Virtual Raster Format. With this you can essentially skip the step of creating one giant DEM. The VRT will be handled by GDAL like a giant, merged DEM but is just a small XML file containing the file paths for each tile as well as some metadata. This can then be fed to gdalwarp together with a bounding box or a ...


4

It doesn't have to read the whole thing. GDAL is heavily geared to sensible access either line by line or block by block (for tiles). It won't matter if you are selecting bands, and no the answer won't change if it's compressed - but the real details will depend on which compression and which internal tiling is used. See "Reading Raster Data" here http://...


4

Your values aren't in 0,255 since they are UInt16. You can try rescaling to 0,255 (GDAL works it out by default from input min/max and output default 0,255): gdal_translate -b 1 -b 2 -b 3 -mask "none" "input.tif" "output.tif" -scale Note you can add params if the defaults aren't sensible: -scale [src_min src_max [dst_min dst_max]] http://www.gdal.org/...


4

Once your geotiff is loaded into QGIS, right click on the image in the layers list, select properties. In 'Render type' select 'Singleband pseudocolor', then in the box on the right, choose a colour map you like the look of, and click on 'Classify'. You can tweak other settings here to get the desired affect e.g. manually changing the range of each colour ...


3

The GDAL section of the Options from the Settings menu will tell you which raster file formats GDAL in your QGIS can load. I can't find a corresponding list for OGR (vector) drivers, but the popup on the "Load Vector Layer" probably has all the file-based ones:


3

GDAL supports NetCDF: http://www.gdal.org/frmt_netcdf.html gdal_translate input.cdf output.tif


3

Use the ASCII to Raster tool. import arcpy arcpy.ASCIIToRaster_conversion("/path/to/file.asc", "/path/to/output.tif", "INTEGER") Note: A GeoTIFF is just a TIFF file with some extra metadata tags, and the only file extension that should be used for TIFFS in ArcGIS is .tif, not .tiff or .geotiff.


3

The syntax of your geo_transform is wrong (for this reason "No transformation is visible") but, with these parameters ("complete random/arbitrary numbers") probably QGIS it'll be closed (if you use its Python Console). You should use geo_transform with these guidelines: geotransform[0] = top left x geotransform[1] = w-e pixel resolution geotransform[2] = 0 ...


3

File-oriented operations rarely "read the whole image into memory", however: It will always need to read the full header (which varies in size by format) It will always need to allocate a row buffer (or tile buffer, if the format is tile-oriented) for input and another for output (in the case of conversion). If a compression algorithm is used, additional ...


3

Check this here is one discussion about reducing size of tiff images. http://www.cvisiontech.com/library/file-formats/tiff/reduce-tiff-file-size.html or You can use this • Flatten your layers if any. • Use LZW compression to reduce tiff file size. • For pdf, try experimenting with compression settings in the Distiller job options.


3

Ciao, an observation on number VS size of files. Opening more than 10 to 20 file to respond to a request would hinder scalability of WMS and WCS. On the other side having Geotiff that are too large (hard to say but >> 20gb as a start) would make the internal structure too big for fast serving. As such you need to balance size and # of files to read on each ...


3

This can be done with the OGC standard WCS. Think that WCS is something like WFS but for raster. But, as @simogeo explains If your goal is to download plain geotif files with no processing (crop, scale, reproject) I would suggest to go for a specific WPS process (that you have to create) that simple give access to the original file. I mean, using ...


3

Rather than reinvent the wheel, I strongly recommend Geoserver. It does exactly what you want, plus has integrated tile caching. It is open source and the de facto implementation of the various OCG web mapping protocols and can simplify your tool chain a lot (as you won't need to implement mapnik and mod_tile. It integrates well with PostGis too. EDIT: ...


3

While Save As ... works easily with vector data, it is not useful to do raster reprojections with it. Instead, use Raster -> Projections -> Warp for reprojection, or Raster -> Convert -> Translate ... for a different file format. For large files, it might be better to use the OSGEO4W Command Shell. You can use gdalwarp or gdal_translate with ...


3

To cut an image (tif file) by using GDAL python library, and without gdalwarp utility, you need to find row and column raster indexes of top point [p1=(minX, maxY)] and bottom point [p2=(maxX, minY)]. The formulas, based in your code, are: i1 = int((p1[0] - xOrigin) / pixelWidth) j1 = int((yOrigin - p1[1] ) / pixelHeight) i2 = int((p2[0] - xOrigin) / ...


2

Draw the area(s) you want to hide from the image and save as vectors into shapefile or other format if you prefer. Then use the gdal_rasterize utility http://www.gdal.org/gdal_rasterize.html which burns fixed, non-transparent pixels into your image and removes permanently image data below the polygons. Here is an example. The map is a RGB tiff image with ...


2

I assume the GeoTiff is in WGS84 EPSG:4326 with degrees as units. As you may know, degrees of latitude and degrees of longitude have different lengths if you are away from the equator. What you expect to see is a projected CRS, like Web Mercator EPSG:3857 or the UTM zone of your part of the world. In QGIS, you can set the project CRS to change the view ...


2

As an alternative to Custom Maps mentioned below, I would suggest GeoViewer. It can do what you need. It can load MrSID and JPEG2000 formats from local storage and arrange them automatically. https://play.google.com/store/apps/details?id=com.lizardtech.activity


2

A big question is whether you are going to read the entire raster from the file into memory before processing it, or whether the file is so large that you will process it incrementally, or process some subset of the overall file. If you will load it all into memory, then you will be doing mostly sequential access, and the fastest format will be a tossup ...


2

-a_srs just assigns the given SRS into metadata but nothing else. I believe this is what you did already and I don't know any better way for doing it: gdalbuildvrt -a_srs epsg:4326 ortho_4326.vrt ortho-*.tif gdalwarp -of VRT -s_srs epsg:4326 -t_srs epsg:3857 ortho_4326.vrt ortho_3857.vrt. There is one exception, if your final goal is to use VRT as a ...


2

there's two tasks here extract the geotag info from the EXIF in your photos rendering that info on your geotiff (or over it, as a separate point layer) From the wording, it sounds like you want to render this directly into a geotiff. This is a bit tricky. If you really do want to go down this route you'll probably need to code. I'd recommend the simpler ...


2

Try r.out.gdal. First, at the layer properties, you can see the raster data type of the original raster. Afterward, at the Modules List of next image, you have the parameters used by me for exporting the raster as *.tif. At the next image you can see that the process was successfully finished. The resulting raster (it was as I expected; without the ...


2

Openlayers and leaflet usually render tiles in World Mercator EPSG:3857. So you have to reproject your source file into that projection using gdalwarp, then start the tiling.


2

Your issue is rooted in a well known GDAL Python gotcha - a dataset needs to be closed for it to be written to disk. In Python this happens when the object goes out of scope and is garbage collected or when you manually dereference it. This is usually done by setting it to None or deleting it. In your particular code the error is in the last line: del ...


2

If your question is how to stitch UAV jpgs together, here are some software options for mosaicing drone imagery Open Drone Map (free, open source) http://opendronemap.github.io/odm/ Palentier (free) http://www.palentier.com/index.html Pix4D (commercial, but there is a limited free version) https://pix4d.com/buy_rent/ Agisoft Photoscan (commercial) http:/...


2

What ever the format, the raster tiles can be loaded faster using the GeoWebCache, where all the tiles has been pre generated and the tiles can be loaded directly without generating it for each request. GeoWebCache is integrated with geoserver no additional component is required. check out this link GeoWebCache for integrating this with geoserver ...


2

I once wrote some functions to automate data download and processing of TRMM 3B42 binary data. downloadTRMM and rasterizeTRMM are included in our working group's Rsenal package. You can either install it via devtools devtools::install_github("environmentalinformatics-marburg/Rsenal") library(Rsenal) or, if installation fails (after all, it's a package in ...


2

The in-memory limit for one row in PostgreSQL is 1 GB. Try using a less memory hungry pixel type. You can also try to pass a compression parameter to ST_AsTiff() but I think internal work is done without compression. Try also to compress tiles BEFORE ST_Union() them just in case... Rasters in PostGIS are desinged to work well as small raster chunk. Not to ...



Only top voted, non community-wiki answers of a minimum length are eligible