初次提交
This commit is contained in:
20
tests/test1.py
Normal file
20
tests/test1.py
Normal file
@@ -0,0 +1,20 @@
|
||||
import sys
|
||||
import os
|
||||
os.environ["OGR_ORGANIZE_POLYGONS"] = "SKIP"
|
||||
|
||||
from pathlib import Path
|
||||
|
||||
# 添加项目根目录到路径
|
||||
sys.path.insert(0, str(Path(__file__).parent.parent))
|
||||
|
||||
import geo_tools
|
||||
|
||||
gdb_path = r"E:\@三普\@临时文件夹\临时数据库.gdb"
|
||||
|
||||
# 列出图层
|
||||
# layers = geo_tools.list_gdb_layers(gdb_path)
|
||||
# print(layers)
|
||||
|
||||
# 读取图层
|
||||
gdf = geo_tools.read_gdb(gdb_path, layer="马关综合后图斑")
|
||||
print(gdf.crs)
|
||||
Reference in New Issue
Block a user