[CI] split tests to avoid timeout (#883)
Signed-off-by: zjy0516 <riverclouds.zhu@qq.com>
This commit is contained in:
1 parent
72a8553310
commit
6d5ceaebcc
4 files changed
+25
-7
No files matched your search
@@ -38,8 +38,10 @@ def test_cpu_offload_diffusion_model(model_name: str):
|
||||
guidance_scale=0.0,
|
||||
generator=torch.Generator("cuda").manual_seed(42),
|
||||
)
|
||||
peak = monitor.peak_used_mb
|
||||
monitor.stop()
|
||||
|
||||
return monitor.peak_used_mb
|
||||
return peak
|
||||
|
||||
offload_peak_memory = inference(offload=True)
|
||||
no_offload_peak_memory = inference(offload=False)
|
||||
|
||||
@@ -119,7 +119,7 @@ def _run_zimage_generate(
|
||||
|
||||
return _extract_single_image([last_output]), median_time_s, peak_memory_mb
|
||||
finally:
|
||||
m.close()
|
||||
monitor.stop()
|
||||
cleanup_dist_env_and_memory()
|
||||
|
||||
|
||||
@@ -160,7 +160,7 @@ def test_zimage_tensor_parallel_tp2(tmp_path: Path):
|
||||
|
||||
mean_abs_diff, max_abs_diff = _diff_metrics(tp1_img, tp2_img)
|
||||
mean_threshold = 3e-2
|
||||
max_threshold = 3.5e-1
|
||||
max_threshold = 5e-1
|
||||
print(
|
||||
"Z-Image TP image diff stats (TP=1 vs TP=2): "
|
||||
f"mean_abs_diff={mean_abs_diff:.6e}, max_abs_diff={max_abs_diff:.6e}; "
|
||||
|
||||
+1
-1
@@ -500,7 +500,7 @@ class GPUMemoryMonitor:
|
||||
pass
|
||||
time.sleep(self.interval)
|
||||
|
||||
self._thread = threading.Thread(target=monitor_loop, daemon=True)
|
||||
self._thread = threading.Thread(target=monitor_loop, daemon=False)
|
||||
self._thread.start()
|
||||
|
||||
def stop(self) -> None:
|
||||
|
||||
Reference in new issue
Block a user