dongchangxi 10 months ago
parent
commit
7783163028
  1. 21
      new_studio_to_reg/tools_to_xmps.py
  2. 21
      old_to_new_build/tools_to_xmps.py

21
new_studio_to_reg/tools_to_xmps.py

@ -128,13 +128,13 @@ def create_rate_xmps(pid): @@ -128,13 +128,13 @@ def create_rate_xmps(pid):
#photos1_count = len(os.listdir(photo1_path))
photos2_count = len(os.listdir(photo2_path))
if photos2_count < 22:
print(f'{time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())} {pid} photo2数量{photos2_count},未能覆盖所有相机,是否继续计算相机位姿?')
continue_or_not = input('是否继续计算相机位姿?(y/n)')
if continue_or_not == 'y':
pass
else:
sys.exit(0)
# if photos2_count < 22:
# print(f'{time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())} {pid} photo2数量{photos2_count},未能覆盖所有相机,是否继续计算相机位姿?')
# continue_or_not = input('是否继续计算相机位姿?(y/n)')
# if continue_or_not == 'y':
# pass
# else:
# sys.exit(0)
#清除图片exif信息, 旋转图片 180度
rateImages(pid)
@ -162,9 +162,10 @@ def create_rate_xmps(pid): @@ -162,9 +162,10 @@ def create_rate_xmps(pid):
if alignNums == 26:
upload_xmp(pid)
else:
upload_or_not = input(f'当前照片数量为{photos2_count},对齐数量为{alignNums},是否上传oss?(y/n)')
if upload_or_not == 'y':
upload_xmp(pid)
# upload_or_not = input(f'当前照片数量为{photos2_count},对齐数量为{alignNums},是否上传oss?(y/n)')
# if upload_or_not == 'y':
# upload_xmp(pid)
pass
print(f'{time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())} {pid} xmps_new_studio_rate文件生成完成,共费时{libs.diff_time(start_time)}')

21
old_to_new_build/tools_to_xmps.py

@ -128,13 +128,13 @@ def create_rate_xmps(pid): @@ -128,13 +128,13 @@ def create_rate_xmps(pid):
photos1_count = len(os.listdir(photo1_path))
photos2_count = len(os.listdir(photo2_path))
if photos1_count + photos2_count < 162:
print(f'{time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())} {pid} photo1数量{photos1_count} photo2数量{photos2_count},未能覆盖所有相机,是否继续计算相机位姿?')
continue_or_not = input('是否继续计算相机位姿?(y/n)')
if continue_or_not == 'y':
pass
else:
sys.exit(0)
# if photos1_count + photos2_count < 162:
# print(f'{time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())} {pid} photo1数量{photos1_count} photo2数量{photos2_count},未能覆盖所有相机,是否继续计算相机位姿?')
# continue_or_not = input('是否继续计算相机位姿?(y/n)')
# if continue_or_not == 'y':
# pass
# else:
# sys.exit(0)
#清除图片exif信息, 旋转图片 180度
rateImages(pid)
@ -182,9 +182,10 @@ def create_rate_xmps(pid): @@ -182,9 +182,10 @@ def create_rate_xmps(pid):
if xmpAligns == (photos1_count+photos2_count):
upload_xmp(pid)
else:
upload_or_not = input(f'当前照片总数{photos1_count+photos2_count},对齐数量{xmpAligns},没有全部对齐,是否上传oss?(y/n)')
if upload_or_not == 'y':
upload_xmp(pid)
# upload_or_not = input(f'当前照片总数{photos1_count+photos2_count},对齐数量{xmpAligns},没有全部对齐,是否上传oss?(y/n)')
# if upload_or_not == 'y':
# upload_xmp(pid)
pass
print(f'{time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())} {pid} rate_xmps文件生成完成,共费时{libs.diff_time(start_time)}')

Loading…
Cancel
Save