neural_compressor.ux.utils.workload.config
¶
Configuration module.
Module Contents¶
Classes¶
Configuration class. |
- class neural_compressor.ux.utils.workload.config.Config(data: Dict[str, Any] = {})¶
Bases:
neural_compressor.ux.utils.json_serializer.JsonSerializer
Configuration class.
- initialize(data: Dict[str, Any] = {}) None ¶
Initialize config from dict.
- remove_dataloader() None ¶
Remove datalader.
- remove_accuracy_metric() None ¶
Remove accuracy metric in config.
- set_evaluation_dataloader(dataloader: dict) None ¶
Udpate dataloader in evaluation config.
- set_evaluation_dataset_path(dataset_path: str) None ¶
Update dataset path in evaluation config.
- get_performance_configs() neural_compressor.ux.utils.workload.evaluation.Configs | None ¶
Get evaluation.performance.configs.
- set_performance_cores_per_instance(cores_per_instance: int) None ¶
Update cores_per_instance evaluation config.
- get_performance_cores_per_instance() int | None ¶
Get cores_per_instance evaluation config.
- set_performance_num_of_instance(num_of_instance: int) None ¶
Update num_of_instance evaluation config.
- get_performance_num_of_instance() int | None ¶
Get num_of_instance evaluation config.
- set_accuracy_and_performance_batch_sizes(batch_size: int) None ¶
Update batch_size evaluation configs.
- set_quantization_dataloader(dataloader: dict) None ¶
Update dataloader in quantization config.
- set_quantization_dataset_path(dataset_path: str) None ¶
Update dataset path in quantization config.
- set_quantization_batch_size(batch_size: str) None ¶
Update batch_size in quantization config.
- set_workspace(path: str) None ¶
Update tuning workspace path in config.
- set_accuracy_goal(accuracy_goal: float) None ¶
Update accuracy goal in config.
- set_accuracy_metric(metric: dict) None ¶
Update accuracy metric in config.
- set_transform(transform: List[Dict[str, Any]]) None ¶
Set transforms metrics in config.
- static process_transform(config: collections.OrderedDict, transform: List[Dict[str, Any]]) None ¶
Process transformation.
- set_quantization_approach(approach: str) None ¶
Update quantization approach in config.
- set_inputs(inputs: List[str]) None ¶
Update inputs in config.
- set_outputs(outputs: List[str]) None ¶
Update outputs in config.
- set_quantization_sampling_size(sampling_size: str) None ¶
Update quantization sampling size in config.
- set_performance_warmup(warmup: int) None ¶
Update performance evaluation warmup iteration number.
- set_performance_iterations(iterations: int) None ¶
Update performance evaluation iteration number.
- set_optimization_precision(framework: str, precision: str) None ¶
Update graph optimization precision.
- load(path: str) None ¶
Load configuration from file.
- dump(yaml_path: str) None ¶
Dump configuration to file.