ImageOverlay behaviour with WG84 rasters
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- javascript, python
- Lĩnh vực
- data-visualization, web-dev
Hướng nghiên cứu
Bắt đầu bằng cách tái hiện ví dụ TIFF được cung cấp với rasterio và folium.ImageOverlay, sau đó so sánh cách xử lý EPSG:4326 của nó với kết quả EPSG:3857 trong QGIS. Đọc cách ImageOverlay xử lý projection và bounds cùng với các kỳ vọng của Leaflet đối với image-overlay; được xem là hoàn tất khi sự khác biệt được giải thích và cách render dự kiến hoặc giới hạn của issue được ghi lại.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
I have a non-expected result when using this code (the raster used is attached to this message):
raster_path = '2019-06-15.tiff'
with rasterio.open(raster_path) as src:
raster_data = src.read(1)
bounds = src.bounds
m = folium.Map(location=[(bounds.top + bounds.bottom) / 2, (bounds.left + bounds.right) / 2], zoom_start=10)
# Create an ImageOverlay
img_overlay = ImageOverlay(
image=raster_data,
bounds=[[bounds.bottom, bounds.left], [bounds.top, bounds.right]],
opacity=0.6,
interactive=False,
cross_origin=True,
zindex=1,
mercator_project=True
)
# Add the overlay to the map
img_overlay.add_to(m)
m.save('map.html')
Indeed, my result html map presents shapes that are not consistent with the same map I could have just by using QGIS.
For instance the result of this code gives this in a specific region:
while using QGIS in an EPSG:3857 projection system gives this:
My raster has natively an EPSG:4326 projection system. I suspect the issue comes from how ImageOverlay changes the projection system.
Can anyone reproduce this and explain how I could obtain the same result as in QGIS which is the correct reference for me?
Thanks,
Vivien
- Ngôn ngữ chính
- Python
- Star
- 7.4k
- Fork
- 2.3k
- Merge trung bình
- 17 giờ 22 phút
- Pull request đã merge (30 ngày)
- 11
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của python-visualization/folium
-
documentation
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
python-visualization/folium#2092 · 5 bình luận ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 67/100
python-visualization/folium#2278 · 1 bình luận ·
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
python-visualization/folium#2259 ·
-
Map output from OSM returns blocked tiles, due to defective request or not following referer-policy Đang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 55/100
python-visualization/folium#2236 · 5 bình luận · 1 reaction ·
-
Touch Screen often fails Đang mở
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 10/100
python-visualization/folium#2219 · 2 bình luận ·
Tất cả issue của python-visualization/folium
Issue tương tự
-
essnmx good first issue
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 95/100
-
[Feature] 奇物选择添加优先级 Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
syfoud/Simulated_Scepter#174 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
Giskard-AI/giskard-oss#2840 · 1 bình luận ·
-
A claim comment carrying the issue number is silently declined while the workflow reports success Đang mởarea: repo bug perceived difficulty: 2
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
yeti-platform/yeti#1380 ·