Spaces:
Running
on
Zero
Running
on
Zero
derektan
commited on
Commit
·
b05951e
1
Parent(s):
3162ed3
More time analysis
Browse files
Taxabind/TaxaBind/SatBind/clip_seg_tta.py
CHANGED
|
@@ -438,7 +438,9 @@ class ClipSegTTA:
|
|
| 438 |
)
|
| 439 |
|
| 440 |
# Save final heatmap after TTA steps
|
|
|
|
| 441 |
self.generate_heatmap(img, imo, txt, sound=sound, modality=modality)
|
|
|
|
| 442 |
|
| 443 |
## NOTE: Added due to app.py (to allocate to GPU only when needed on HF)
|
| 444 |
# if self.device.type == "cuda":
|
|
|
|
| 438 |
)
|
| 439 |
|
| 440 |
# Save final heatmap after TTA steps
|
| 441 |
+
time_start = time.time()
|
| 442 |
self.generate_heatmap(img, imo, txt, sound=sound, modality=modality)
|
| 443 |
+
print(f"Time taken to generate heatmap after TTA steps: {(time.time()-time_start):.2f}")
|
| 444 |
|
| 445 |
## NOTE: Added due to app.py (to allocate to GPU only when needed on HF)
|
| 446 |
# if self.device.type == "cuda":
|