deephyper.evaluator.callback.ProfilingCallback#
- class deephyper.evaluator.callback.ProfilingCallback[source]#
Bases:
Callback
Collect profiling data. Each time a
Job
is completed by theEvaluator
a the different timestamps corresponding to the submit and gather (and run function start and end if theprofile
decorator is used on the run function) are collected.An example usage can be:
>>> profiler = ProfilingCallback() >>> evaluator.create(method="ray", method_kwargs={..., "callbacks": [profiler]}) ... >>> profiler.profile
Methods
Called each time a Job is completed by the Evaluator.
Called each time a Job is collected from an other process.
Called each time a
Job
is created by theEvaluator
.Attributes
profile
- on_done(job)[source]#
Called each time a Job is completed by the Evaluator.
- Parameters:
job (Job) – The completed job.