Skip to main content
16 events
when toggle format what by license comment
Aug 9, 2022 at 18:00 history tweeted twitter.com/StackGIS/status/1557064176392183808
Aug 8, 2022 at 19:08 history edited Kadir Şahbaz CC BY-SA 4.0
added 3 characters in body
Aug 8, 2022 at 17:29 answer added Bằng Rikimaru timeline score: 0
Nov 26, 2021 at 6:38 history edited Taras CC BY-SA 4.0
added 269 characters in body; edited title
Nov 26, 2021 at 3:51 answer added user2856 timeline score: 1
Nov 25, 2021 at 23:25 comment added LostinSpatialAnalysis Success! This worked! Thank you! I see that the out-of-scale issue is caused by a discrepancy between degrees and lon/lat, but how did you know to choose exactly 0.0001? Sorry I have always been a bit confused between pixel size and resolution. Is 0.0001 the one "correct" size value or just the best approximation? I am just trying to understand so I know how to set the most appropriate pixel size next time.
Nov 25, 2021 at 19:42 comment added LostinSpatialAnalysis Good point there. I had tried changing the burn value there to 1, but this resulted in a raster that just a black square with all 0 value. I tried your gdal.Rasterize() suggestion and it works, and produces the .tif raster like I want, but when I open the file in QGIS, it is as well just a black square, with all 0 value pixels. I tried leaving xRes and yRes blank, but that didn't work. I then tried setting them both to 100, but then the black square was far beyond the extent of the NYC polygons. I am just trying to get the output raster to match the size/extent of the input shapefile.
Nov 24, 2021 at 23:51 answer added snowman2 timeline score: 2
Nov 24, 2021 at 23:12 history edited LostinSpatialAnalysis CC BY-SA 4.0
added 1271 characters in body
S Nov 24, 2021 at 23:10 history suggested user78863 CC BY-SA 4.0
Edited title for clarity.
Nov 24, 2021 at 23:08 review Suggested edits
S Nov 24, 2021 at 23:10
Nov 24, 2021 at 21:48 answer added user78863 timeline score: 0
Nov 24, 2021 at 21:07 comment added LostinSpatialAnalysis Good suggestion, thanks. I used gdal.UseExceptions() and pasted the new error traceback message in my post. The error is telling my my 0x0 dataset is illegal, and I am not sure what this means, but perhaps it could be an error with my projection. I am trying to figure out what this means, or which step resulted in this problem raster.
Nov 24, 2021 at 21:05 history edited LostinSpatialAnalysis CC BY-SA 4.0
added 384 characters in body
Nov 24, 2021 at 20:57 comment added mikewatt Try enabling exceptions and seeing if you get a more helpful error
Nov 24, 2021 at 20:47 history asked LostinSpatialAnalysis CC BY-SA 4.0