-
Notifications
You must be signed in to change notification settings - Fork 48
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 performance metrics LabGraph issue 78 #88
base: main
Are you sure you want to change the base?
Conversation
Hi @wixair! Thank you for your pull request and welcome to our community. Action RequiredIn order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you. ProcessIn order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with If you have received this in error or have any questions, please contact us at [email protected]. Thanks! |
Added real-time performance metrics of Latency, Throughput, and Data rate. Demoed at maintainer meeting 8/11/22 and maintainer said good to pull request |
|
||
|
||
data = deque() |
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.
In the future, deque can be replaced by a more performant buffer data structure.
global data | ||
global throughput_data | ||
global datarate_data | ||
global one_second_must_pass |
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.
Please try to avoid using global here.
global data | ||
global throughput_data | ||
global datarate_data | ||
global one_second_must_pass |
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.
Same here for global.
(state: RootState) => state.ws | ||
); | ||
const { mockGraph } = useSelector((state: RootState) => state.mock); | ||
// const mockData = useSelector( |
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.
Remove dead code.
@@ -12,7 +12,7 @@ import { | |||
SettingsApplicationsRounded, | |||
AlignHorizontalLeftOutlined, | |||
AlignVerticalTopOutlined, | |||
Mode, | |||
// Mode, |
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.
Remove all the dead codes.
@@ -56,6 +56,10 @@ def add_message_1(self, message: RandomMessage) -> None: | |||
"grouping": grouping, | |||
"timestamp": message.timestamp, | |||
"numpy": list(message.data), | |||
|
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.
Unnecessary space, have the black and flake8 checks been run? Reference: #76
@@ -1,17 +1,14 @@ | |||
#!/usr/bin/env python3 | |||
# Copyright 2004-present Facebook. All Rights Reserved. | |||
# -*- coding: utf-8 -*- | |||
# Copyright 2004-present Facebook. All Rights Reserve |
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.
Use the correct header.
data: np.ndarray | ||
|
||
latency: any = 1.0 |
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.
Use the correct type, try to avoid using any unless it intends to be generic.
@@ -0,0 +1,959 @@ | |||
{ |
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.
Is this autogenerated file or a compulsory file for this PR?
Please add the relevant tests and clear description on how the tests can be run in relevant places (e.g. documentation and PR description update). |
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.
I definitely agree with all of the comments left by Jimmy, but overall it looks good to me too!
Make sure to add the contributor license agreement though! |
Description
Please include a summary of the feature or issue being fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.
Fixes #(issue)
Type of change
Please delete options that are not relevant.
Feature/Issue validation/testing
Please describe the tests [UT/IT] that you ran to verify your changes and relevent result summary. Provide instructions so it can be reproduced.
Please also list any relevant details for your test configuration.
Test A
Test B
Unit Test / Integration Test (UT/IT) execution results
Logs
Checklist: