neural_compressor.ux.utils.templates.metric
¶
Metric class.
Module Contents¶
Classes¶
Metric represents data which is sent from Optimization and Benchmark. |
- class neural_compressor.ux.utils.templates.metric.Metric¶
Bases:
neural_compressor.ux.utils.json_serializer.JsonSerializer
Metric represents data which is sent from Optimization and Benchmark.
- property accuracy: float | None¶
Accuracy for model.
- property latency: float | None¶
Latency for model.
- property throughput: float | None¶
Throughput for model.
- property acc_input_model: float | None¶
Accuracy for input model.
- property acc_optimized_model: float | None¶
Accuracy for input model.
- property size_input_model: float | None¶
Model size for float32.
- property size_optimized_model: float | None¶
Get optimized model size.
- property path_optimized_model: str | None¶
Get optimized model path.
- property optimization_time: float | None¶
Optimization time.
- property profiling_data: List[dict] | None¶
Get profiling data.
- insert_data(attribute: str, value: str) None ¶
Set attribute value.
- static calculate_throughput(value: float) float ¶
Calculate throughput based on latency.
Right now 1000 represents number of images in dataset. TODO: change 1000 to the batch size when Benchmark is ready