Skip to content

Why ignore cut_point_averages[0] when computing averages time? #4

@cucrui

Description

@cucrui

I could not figure out that in benchmarking_server.py line 274, why the averages time computed by sum(cut_point_averages[1:]) / (cut_frequency - 1), and why not include cut_point_averages[0]. The code show as below.

if self.requests_answered != 0 and q % cut_frequency == 0:
        averages.append(sum(cut_point_averages[1:]) / (cut_frequency - 1))
        cut_point_averages = []
        
        edge_averages.append(sum(edge_only_averages[1:]) / (cut_frequency - 1))
        edge_only_averages = []
        
        cloud_averages.append(sum(cloud_only_averages[1:]) / (cut_frequency - 1))
        cloud_only_averages = []
        
        cps.append(cut_point)
        print('cps', cps)

Another question is in benchmarking_server.py line 337, why the denominator is a fixed value, while list cut_point_averages[] is dynamic increasing, the code show as below.

print(cut_point_averages, 'avg:', sum(cut_point_averages[1:]) / (cut_frequency - 1))

Thanks for your reply!

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