Skip to content

Implement total core-hours and distribution of time of an experiment in /v3/performance/{expid} #185

@MissterP

Description

@MissterP

Hi!

The predecessor of this issue is this one.

This issue is related to this one.

I plan to enhance the API endpoint /v3/performance/{expid} by adding the total core-hours and distribution of time of an experiment. I would like to do the implementation to the file performance_metrics.py, this way:

  • Total core-hours: Add to the function def to_json(self) -> Dict: a new atribute called Total_core_hours; the value would be self.valid_sim_core_hours_sum which is a new class attribute of PerformanceMetrics,that would be calculated at def _calculate_global_metrics and would use a new function called def _calculate_total_energy(self): which returns the sum of the core-hours of the considered SIM jobs.

  • Distribution of time: Add to the function def to_json(self) -> Dict: two new atribute called phases_total_time and phases_critical_path_time which represent two embedded vectors with the time of each phase of an experiment for the two approaches (Total time and critical path); the values would be self.phases_total_time and self.phases_critical_path_time which are two new class attributes of PerformanceMetrics, they would be calculated at def _calculate_global_metrics and would use two new functions called def _calculate_phases_total_time(self) and def _calculate_phases_critical_path_time(self); which returns a vector with the total time used in the different phases depending of the approach. Also, between the def _calculate_global_metrics and the two functions to calculate the times there will be a new function called def _extract_phases_jobs which returns a list of the jobs of each phase.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions