QGIS提升速度

This commit is contained in:
wzy-warehouse
2026-06-21 13:29:19 +08:00
parent fe3ccd005d
commit 5169ed2f33
28 changed files with 444 additions and 394 deletions
+6
View File
@@ -138,6 +138,12 @@ def main():
# 初始化 QgsApplication(只做一次)
qgs_app = _init_qgis()
# 从磁盘恢复已缓存的模板(跨进程加速)
from app.services.qgis.map_service import template_cache
cached_count = template_cache.load_persistent_cache()
if cached_count > 0:
print(f"[qgis_runner] 磁盘缓存命中: {cached_count} 个模板", file=sys.stderr)
try:
from app.services.qgis.map_service import MapService