MalaGIS

Sharing GIS Technologies, Resources and News.

Displaying Selected Layer Count in QGIS with PyQGIS

When working with numerous layers in QGIS, it is often necessary to select multiple layers simultaneously for operations. However, with a large number of layers, it becomes difficult to quickly discern exactly how many are selected—don't worry, you can easily solve this by writing a small tool with PyQGIS!

Today, we share two methods to display the count of selected layers in real-time. These methods are straightforward to implement, with clear code, and can be tried by those in need.

more >>

How to Render Albers Projection in Web Maps Using OpenLayers and Leaflet

Recently, I was assigned another GIS dashboard project. My manager asked me to research the mainstream design styles currently on the market. Coincidentally, I had previously introduced a collection of such dashboard works in an article titled "Open-Source Dashboard Templates for GIS Developers: BigDataView Project". Combined with various examples shared within our community group, I managed to complete the task.

During the research process, I noticed an interesting phenomenon: many dashboards still use maps in the EPSG:3857 projection, which results in a "tilted" depiction of China's map. Therefore, using OpenLayers and Leaflet as examples, and with the help of various AI tools, I created two demos to implement the rendering of the Albers projection on the web.

more >>

AI-Powered Quick Map Production: A Case Study of China's 2024 Birth Rate Visualization

Yesterday, someone in a group shared a map of China's 2024 birth rate, which looked quite interesting. However, this map was different from the usual ones—regions with lower birth rates were colored redder. Someone asked if it could be quickly recreated.

Two years ago, I might have been too lazy to bother because redrawing the map would require manually extracting and recording data from the map one by one, then importing it into QGIS or ArcGIS for data processing, and finally producing the map. But in 2025, the era of AI, this task is a breeze. Today, I'll share a set of AI-based rapid map production methods. Next time you encounter such a demand, just go for it!

more >>

Converting China Standard Map Service EPS Files to SHP Format

Recently, many have asked why the China National Standard Map Service doesn’t offer SHP format downloads and whether EPS files can be converted to SHP format.

Regarding the first question, I don’t know the exact reason. Personally, I suspect it may relate to the unique coordinate system used by the standard map service (refer to "What Projection Coordinate System Does the National Standard Map Use?"). So, can we convert the currently provided EPS format maps to SHP?

The answer is: Yes, but it’s largely unnecessary.

I recently experimented with this process and documented the steps below for those interested.

more >>

Sentinel-2 Super-Resolution: SR4RS vs. S2DR3

Remote sensing imagery is crucial for global monitoring but often limited by sensor spatial resolution and the high cost of acquiring ultra-high-resolution data. The Sentinel-2 (S2) mission provides multispectral imagery across 13 bands at 10m, 20m, and 60m resolutions. However, these resolutions may not capture fine details required for tasks like land cover mapping, agricultural monitoring, or disaster assessment. Super-Resolution (SR) technology addresses this by reconstructing high-resolution images from low-resolution inputs, significantly enhancing spatial detail in S2 imagery for more precise data support.

more >>

Unlocking Global Insights: Google's AlphaEarth Foundations and Satellite Embedding Dataset Revolutionize Geospatial Analysis

Google has officially launched AlphaEarth Foundations, a PB-scale AI model for integrating satellite data, accompanied by a groundbreaking 64-dimensional Satellite Embedding Dataset. This innovation distills multi-year, multi-satellite observations into a single 10m × 10m pixel, compressing dozens of data sources – including satellite imagery, radar, elevation, and climate data – into unified 64-dimensional "information capsules". This fundamentally redefines geospatial analysis methodologies.

more >>

Recreating the 'Your Name in Landsat' Experience: A Step-by-Step Guide

In the previous article "Discover Landsat's New Tool: Turning Your Name into Artistic Maps", I introduced NASA's fun application "Your Name In Landsat". Recently, the official website became inaccessible, prompting inquiries from readers about alternatives. After searching without finding a viable solution, I decided to recreate the experience myself.

Access the demo: https://malagis.com/extension/demo/your-name-in-landsat/

Below is a brief overview of the implementation process.

more >>

Malicious CDN Traffic Attack: Analysis and Practical Solutions for GIS Web Systems

Three months ago, during preparations for a leadership inspection of our WebGIS dashboard project (arguably its most critical application), our project manager urgently contacted me the night before: "XXX, emergency! The basemap's peripheral elements on the GIS dashboard have disappeared—only data remains visible!"

Reluctantly accessing the system, I discovered the dynamic visualizations had vanished. Console errors revealed resource loading failures traced to our CDN service. Checking my personal CDN account (used due to small company scale), I found payment overdue—promptly recharging 200 CNY.

A month later, while debugging new features, CDN errors recurred. Initially attributing this to post-exhibition traffic spikes (even boasting about "high system usage" to my manager), I recharged another 200 CNY.

When another billing alert arrived just weeks later—despite the exhibition ending months prior—abnormal traffic patterns became undeniable.

Initial Investigation

Qiniu Cloud's backend revealed alarming patterns:

more >>

Efficiently Downloading USGS Earthquake Data in Batches Using Excel

In previous articles, such as "Using Aria2 to Download GIS Data" and "Recommended Websites for Downloading Earthquake Data", the USGS (United States Geological Survey) was introduced as a source for global earthquake data. However, this website has a limitation: it will reject download requests if the query exceeds 2000 records. Therefore, a practical workaround is to construct download requests by month and download the data in batches. If I wanted to download all the data from 1900 until now, manually creating each download link would be very tedious. Hence, I came up with the following solution.

more >>

Zoom to the Maximum Value Cell in a Large Raster in QGIS

When working with large raster datasets in QGIS, especially Float64 GeoTIFFs with hundreds of millions of cells, you may want to locate and zoom into the pixel that holds the maximum value. This can be useful in terrain analysis, remote sensing, or any context where the peak value matters.

A common approach involves converting the raster into a point or polygon layer. However, this is resource-intensive and often impractical for large datasets. This tutorial introduces an efficient alternative using PyQGIS and NumPy to directly zoom to the maximum value without raster reclassification or vectorization.

more >>

Copyright © 2020-2025 MalaGIS Drive by Typecho & Lingonberry Sitemap

Back to top