aitune.torch.task
Task module.
Subpackages
Submodules
Package Contents
Classes
Functions
API
Strategy when to stop collecting measurements for given batch size.
Get events to use for measuring stop strategy.
Check if the measurement should be stopped.
Parameters:
list[ ProfilingResultEvent ] — List of profiling results events for a one measurement.
Returns: bool
True if the measurement should be stopped, False otherwise.
Strategy how do the measurement and create a ProfilingResultEvent(s).
Do the measurement and create a ProfilingResultEvent(s).
Parameters:
Batch size of the measurement.
Model to measure.
Sample to measure.
Additional keyword arguments.
Returns: list[ ProfilingResultEvent ]
List of ProfilingResultEvent(s).
Bases: MeasuringStrategy
Strategy to measure execution time.
Do the measurement and create a ProfilingResultEvent(s) for the model.
Bases: MeasuringStopStrategy
Strategy to stop collecting measurements after a given number of steps.
Get final measured events after should_stop() has returned True.
Check if the measurement should be stopped.
Configuration for profiling.
Note: all profiling configuration strategies are deepcopied before use.
List of batch sizes to profile.
Whether profiling should batch samples together.
Strategy to stop collecting measurements.
Strategy to measure the model.
Strategy to stop profiling.
Post-init.
Profiling result event.
Details of the backend.
Batch size of the measurement.
Execution time of the measurement.
Unique identifier for the measurement.
Phase of the measurement.
Timestamp of the measurement.
Profiling results.
Profiling status.
Bases: MeasuringStopStrategy
Strategy to stop collecting measurements after a stable sliding window has been collected.
Get events to use for measuring stop strategy.
Check if the measurement should be stopped.
Get inference events.
Profile a callable with given dataset.
Parameters:
Function to profile.
DatasetLike | DataLoaderFactory | torch.Tensor — Dataset to profile.
ProfilingConfig — Configuration for profiling.
Name of the model, optional.
Detailed information of the backend, optional.
Returns: ProfilingStatus
Status of the profiling.