From acf441db4a8b4554ab07df33e90675738173a821 Mon Sep 17 00:00:00 2001 From: chenzenghui <3045316072@qq.com> Date: Thu, 9 Oct 2025 13:57:34 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BA=86=E8=BF=9B=E5=BA=A6?= =?UTF-8?q?=E6=89=93=E5=8D=B0=E7=BB=93=E6=9E=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../PredictProcessRaster_AC.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/generatorRasterSlicesTools/PredictProcessRaster_AC.py b/generatorRasterSlicesTools/PredictProcessRaster_AC.py index 7f364fd..b705cee 100644 --- a/generatorRasterSlicesTools/PredictProcessRaster_AC.py +++ b/generatorRasterSlicesTools/PredictProcessRaster_AC.py @@ -55,11 +55,11 @@ def preProcessTiFF(tiffpath,txtpath,preFolderPath): if os.system(cmdtxt) ==2: print("sucess:",cmdtxt) writeoutlog(logPath, "sucess: {}\n".format(cmdtxt)) - return 2 + return "sucess: {}\n".format(cmdtxt) else: print("failed:",cmdtxt) writeoutlog(logPath, "failed: {}\n".format(cmdtxt)) - return 3 + return "failed: {}\n".format(cmdtxt) def processMJPort(srcFolderPath,outMJPortSumTxtPath,outMJPortFolderPath,MLCShapeFilePath,JLCShapeFilePath,MJLCShapeFilePath): @@ -107,8 +107,8 @@ def preProcessShipPortTools(srcFolderPath,targetFolderPath,outTargetFolderPath): MLCShapeFilePath=r"D:\TYSAR-德清院\目标点位信息更新\0828目标点位\港口(民船).shp" JLCShapeFilePath=r"D:\TYSAR-德清院\目标点位信息更新\0828目标点位\军港.shp" # 数据BM,不公开 MJLCShapeFilePath=r"D:\TYSAR-德清院\目标点位信息更新\0828目标点位\军民一体港口.shp" - - processMJPortflag=processMJPort(srcFolderPath,outMJPortSumTxtPath,outMJPortFolderPath,MLCShapeFilePath,JLCShapeFilePath,MJLCShapeFilePath) + processMJPortflag=2 + # processMJPortflag=processMJPort(srcFolderPath,outMJPortSumTxtPath,outMJPortFolderPath,MLCShapeFilePath,JLCShapeFilePath,MJLCShapeFilePath) # 港口归属 if processMJPortflag==2: # 逐行处理 @@ -146,8 +146,8 @@ def preProcessShipPortTools(srcFolderPath,targetFolderPath,outTargetFolderPath): # 处理分块 for pidx in range(len(async_results)): async_result=async_results[pidx] - print("{}/{} {}".format(pidx+1,len(async_results)),async_result.get()) - writeoutlog(logPath,"{}/{} {}".format(pidx+1,len(async_results),async_result.get())) + print("{}/{}".format(pidx+1,len(async_results))) + # writeoutlog(logPath,"{}/{}".format(pidx+1,len(async_results),async_result.get())) pass else: pass @@ -184,7 +184,7 @@ if __name__ == '__main__': # 20250930-不分类 条带模式 srcFolderPath = r"R:\TYSAR-德清院\TYSAR-条带模式(SM)\航道\20250930-不分类\0-原图" - preFolderPath = r"R:\TYSAR-德清院\TYSAR-条带模式(SM)\航道\20250930-不分类\A-预处理" + preFolderPath = r"R:\TYSAR-德清院\TYSAR-条带模式(SM)\航道\20250930-不分类\A-预处理2" targetfolderPath = r"R:\TYSAR-德清院\TYSAR-条带模式(SM)\港口\20250826-不分类\A-预处理" preProcessShipPortTools(srcFolderPath, preFolderPath, targetfolderPath)