fix: SCP utilise glob frame_*.jpg au lieu de -r (évite création sous-dossiers)
This commit is contained in:
@@ -428,9 +428,10 @@ def _extract_on_remote_host(job_id: int, worker: dict, src_host: str, src_path:
|
|||||||
|
|
||||||
set_status(job_id, step=f"scp frames {vid_num}/{n_videos} -> {worker['host']}")
|
set_status(job_id, step=f"scp frames {vid_num}/{n_videos} -> {worker['host']}")
|
||||||
print(f" scp frames {remote_tmp}/ -> {worker['host']}:{frames_dir}/")
|
print(f" scp frames {remote_tmp}/ -> {worker['host']}:{frames_dir}/")
|
||||||
|
# Use glob instead of -r to copy files directly (scp -r creates a subdir named after source)
|
||||||
pull_cmd = (
|
pull_cmd = (
|
||||||
f"scp -r -o BatchMode=yes "
|
f"scp -o BatchMode=yes "
|
||||||
f"{shlex.quote(src_host)}:{shlex.quote(remote_tmp + '/')} "
|
f"'{src_host}:{remote_tmp}/frame_*.jpg' "
|
||||||
f"{shlex.quote(frames_dir)}/"
|
f"{shlex.quote(frames_dir)}/"
|
||||||
)
|
)
|
||||||
rc2, _, err2 = ssh(worker["ssh_alias"], pull_cmd, timeout=3600)
|
rc2, _, err2 = ssh(worker["ssh_alias"], pull_cmd, timeout=3600)
|
||||||
|
|||||||
Reference in New Issue
Block a user