improve profiling

This commit is contained in:
Vladimir Mandic
2024-09-23 11:07:24 -04:00
parent ddefb38030
commit 92f2a2902f
14 changed files with 128 additions and 77 deletions
+1
View File
@@ -59,6 +59,7 @@ def wrap_gradio_call(func, extra_outputs=None, add_stats=False, name=None):
else:
res = list(res)
if shared.cmd_opts.profile:
pr.disable()
errors.profile(pr, 'Wrap')
except Exception as e:
errors.display(e, 'gradio call')