kopia lustrzana https://github.com/OpenDroneMap/ODM
fix #1151 - check for symbolic links before removing directories in run_opensfm.py
rodzic
74b47be0bd
commit
85ea7c39a4
|
@ -34,10 +34,12 @@ class ODMOpenSfMStage(types.ODM_Stage):
|
|||
self.update_progress(70)
|
||||
|
||||
if args.optimize_disk_space:
|
||||
shutil.rmtree(octx.path("features"))
|
||||
shutil.rmtree(octx.path("matches"))
|
||||
shutil.rmtree(octx.path("exif"))
|
||||
shutil.rmtree(octx.path("reports"))
|
||||
for folder in ["features", "matches", "exif", "reports"]:
|
||||
folder_path = octx.path(folder)
|
||||
if os.path.islink(folder_path):
|
||||
os.unlink(folder_path)
|
||||
else:
|
||||
shutil.rmtree(folder_path)
|
||||
|
||||
# If we find a special flag file for split/merge we stop right here
|
||||
if os.path.exists(octx.path("split_merge_stop_at_reconstruction.txt")):
|
||||
|
|
Ładowanie…
Reference in New Issue