From 79c56aaf0b1db8845be7b833a71d04a9faa2ee46 Mon Sep 17 00:00:00 2001 From: dongchangxi <458593490@qq.com> Date: Wed, 15 Jan 2025 17:34:35 +0800 Subject: [PATCH 1/2] 1 --- .gitignore | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.gitignore b/.gitignore index b3b4820..d09c79c 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,9 @@ old_to_new_build/__pycache__/tools_to_xmps.cpython-310.pyc pid.text task_distributed_error.log export_build_info/__pycache__/export_already_build.cpython-310.pyc +yj_local_build/dist/ +yj_local_build/build/ +yj_local_build/build/main_step1/main_step1.exe +new_studio_to_reg/__pycache__ +new_studio_to_reg/__pycache__/tools_to_xmps.cpython-310.pyc +new_studio_to_reg/__pycache__/tools_to_xmps.cpython-310.pyc From 298be82317c372fb3333bf029d63ed2c3c37cf24 Mon Sep 17 00:00:00 2001 From: dongchangxi <458593490@qq.com> Date: Mon, 20 Jan 2025 17:05:10 +0800 Subject: [PATCH 2/2] 1 --- manual_service.py | 4 ++-- new_studio_to_reg/get_new_studio_reg_info.py | 8 +++++--- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/manual_service.py b/manual_service.py index 8aef172..e5c5afc 100644 --- a/manual_service.py +++ b/manual_service.py @@ -59,12 +59,12 @@ def cmd_run(pid,usePhoto = "1",lock=False): if lock: exportxmp = ' -exportXMP "D:\\make2\\config\\exportXMP.config.lock.xml" ' else: - exportxmp = ' -exportXMP "D:\\make2\\config\\exportXMP.config.xml" ' + exportxmp = ' -exportXMP "D:\\make2\\config\\exportXMP.config.lock.xml" ' usePhoto = "photo"+str(usePhoto) #执行命令 - cmd = f'{config.rcbin} {config.r2["init"]} -setInstanceName "{pid}" \ + cmd = f'{config.rcbin} -setInstanceName "{pid}" \ -save "{os.path.join(config.workdir, pid, f"{pid}.rcproj")}" \ -addFolder "{os.path.join(config.workdir, pid, usePhoto)}" -selectAllImages \ -detectMarkers "D:\\make2\\config\\detectMarkers.config.xml" \ diff --git a/new_studio_to_reg/get_new_studio_reg_info.py b/new_studio_to_reg/get_new_studio_reg_info.py index 08e6b63..38271e2 100644 --- a/new_studio_to_reg/get_new_studio_reg_info.py +++ b/new_studio_to_reg/get_new_studio_reg_info.py @@ -55,12 +55,12 @@ def get_photo2_align_info(pid): #下载照片 libs.down_from_oss_photo2(config.oss_bucket, config.workdir, pid) - #判断对齐的图片数量和photo2的数量是否一致,不一致要进行通知处理 - photosNums = len(os.listdir(os.path.join(config.workdir, pid, "photo2"))) + #判断是否存在该目录 filename = f'xmps_new_studio_rate/{psid}/texture/11_2.xmp' print(f"影棚号:{psid} , {config.oss_bucket.object_exists(filename)}") isRate = False + photosNums = 0 if not config.oss_bucket.object_exists(filename): # #提示是否进行 xmps_new_studio_rate 文件夹的创建 # yes_or_not = input('当前该影棚没有对应的对齐坐标,是否创建?(y/n)') @@ -69,6 +69,7 @@ def get_photo2_align_info(pid): # isRate = True # else: # sys.exit(0) + photosNums = len(os.listdir(os.path.join(config.workdir, pid, "photo2"))) tools_to_xmps.create_rate_xmps(pid) isRate = True @@ -76,7 +77,8 @@ def get_photo2_align_info(pid): if isRate == False: print(f"旋转图片:{pid}") tools_to_xmps.rateImages(pid) - + #判断对齐的图片数量和photo2的数量是否一致,不一致要进行通知处理 + photosNums = len(os.listdir(os.path.join(config.workdir, pid, "photo2"))) #下载对齐信息 get_xmps(psid,pid)