Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
tsn-measures
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
tsn-measures
Commits
ba5ecdf7
Commit
ba5ecdf7
authored
Jun 10, 2020
by
Joanne Hugé
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix small mistakes
parent
1a06b0f0
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
2 deletions
+5
-2
scripts/txtime_stats.py
scripts/txtime_stats.py
+5
-2
No files found.
scripts/txtime_stats.py
View file @
ba5ecdf7
...
...
@@ -26,9 +26,12 @@ import csv
import
struct
import
math
import
sys
import
json
def
compute_offsets_stats
(
file_path
,
interval
):
interval
=
int
(
interval
)
measure_set
=
{}
measure_set
[
"measure_type"
]
=
"packet_jitter_tcpdump"
measure_set
[
"props_names"
]
=
[
"packet_jitter_tcpdump"
]
...
...
@@ -51,7 +54,7 @@ def compute_offsets_stats(file_path, interval):
if
i
>
0
:
val
=
arrival_tstamp
-
prev_tstamp
jitter
=
(
val
-
interval
)
/
1000
histogram_index
=
1000
+
jitter
histogram_index
=
int
(
1000
+
jitter
)
if
histogram_index
<
0
or
histogram_index
>
2000
:
print
(
"jitter too high: {}
\
n
"
.
format
(
jitter
))
else
:
...
...
@@ -70,7 +73,7 @@ def compute_offsets_stats(file_path, interval):
measure_set
[
"props"
]
=
[
histogram
]
data
=
{}
data
[
"measure_sets"
]
=
[{
measure_set
}]
data
[
"measure_sets"
]
=
[{
"measure_sets"
:
measure_set
}]
path
=
"tcpdump_histogram"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment