-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added the mapper tool to map trace to vSwarm proxies #541
base: main
Are you sure you want to change the base?
Conversation
Added documentation for the mapper tool. Signed-off-by: KarthikL1729 <[email protected]>
bc1d3a7
to
a8f3342
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This a very brief look into a single function of the mapper. Please fix all of possible problems before submitting the PR.
log.info( | ||
f"Getting closest proxy function for every trace function. Note: Mapping may not be unique" | ||
) | ||
trace_functions, err = get_closest_proxy_function( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is extremely unexpected behavior. If something goes sideways in the unique assignment, I'll get a non-unique one. I would be pretty annoyed to find that my tool tried to be too smart about the operation that I asked it to do. If operation is not possible, the tool should just exit.
try: | ||
|
||
trace_functions = OrderedDict(trace_functions) | ||
proxy_functions = OrderedDict(proxy_functions) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Again, why do you need ordereddict here?
for tf in trace_functions: | ||
if row_index == trace_functions[tf]["index"]: | ||
trace = tf | ||
break |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You linearly search in the dict. Are sure that this data structure is suitable for the task? You also literally created trace_list that has all of them in the index order.
cea515f
to
a8f3342
Compare
Added documentation for the mapper tool.
Summary
A small summary of the requirements (in one/two sentences).
The mapper tool is used to map the Azure trace functions to the vSwarm proxy functions based on the profiles of vSwarm functions and their correlation with the Azure trace function durations and memory utilization.
Implementation Notes ⚒️
This PR adds the mapper tool, which loads the function duration and memory trace with Pandas, finds the optimal mapping based on modelling the problem as a linear sum assignment, and then outputs a file which maps each HashFunction in the trace to a proxy function in vSwarm. The profile needs to be unzipped before using the mapper, and the profile is included in a tar.gz file in the mapper directory.
External Dependencies 🍀
Breaking API Changes⚠️
Simply specify none (N/A) if not applicable.