Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
gstlal
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Duncan Macleod
gstlal
Commits
8ed9f751
Commit
8ed9f751
authored
6 years ago
by
chad.hanna
Browse files
Options
Downloads
Patches
Plain Diff
lloidhandler.py: fix some of the eye candy
parent
8571da06
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
gstlal-inspiral/python/lloidhandler.py
+11
-1
11 additions, 1 deletion
gstlal-inspiral/python/lloidhandler.py
with
11 additions
and
1 deletion
gstlal-inspiral/python/lloidhandler.py
+
11
−
1
View file @
8ed9f751
...
...
@@ -160,6 +160,7 @@ class EyeCandy(object):
self
.
ifo_snr_history
=
dict
((
instrument
,
deque
(
maxlen
=
300
))
for
instrument
in
instruments
)
self
.
dqvectors
=
{}
self
.
statevectors
=
{}
self
.
strain
=
{}
for
instrument
in
instruments
:
name
=
"
%s_state_vector
"
%
instrument
elem
=
pipeline
.
get_by_name
(
name
)
...
...
@@ -167,6 +168,9 @@ class EyeCandy(object):
name
=
"
%s_dq_vector
"
%
instrument
elem
=
pipeline
.
get_by_name
(
name
)
self
.
dqvectors
[
instrument
]
=
elem
name
=
"
%s_strain_audiorate
"
%
instrument
elem
=
pipeline
.
get_by_name
(
name
)
self
.
strain
[
instrument
]
=
elem
self
.
time_since_last_state
=
None
#
...
...
@@ -206,7 +210,7 @@ class EyeCandy(object):
if
last_coincs
:
latency_val
=
None
snr_val
=
(
0
,
0
)
like_val
=
(
0
,
0
)
like_val
=
(
0
,
float
(
"
-inf
"
)
)
far_val
=
(
0
,
0
)
coinc_inspiral_index
=
last_coincs
.
coinc_inspiral_index
coinc_event_index
=
last_coincs
.
coinc_event_index
...
...
@@ -259,6 +263,12 @@ class EyeCandy(object):
self
.
producer
.
send
(
self
.
tag
,
{
"
%s/statevector_on
"
%
instrument
:
"
%s
\t
%s
"
%
(
t
,
elem
.
get_property
(
"
on-samples
"
))})
self
.
producer
.
send
(
self
.
tag
,
{
"
%s/statevector_off
"
%
instrument
:
"
%s
\t
%s
"
%
(
t
,
elem
.
get_property
(
"
off-samples
"
))})
self
.
producer
.
send
(
self
.
tag
,
{
"
%s/statevector_gap
"
%
instrument
:
"
%s
\t
%s
"
%
(
t
,
elem
.
get_property
(
"
gap-samples
"
))})
for
instrument
,
elem
in
self
.
strain
.
items
():
# I know the name is strain_drop even though it
# comes from the "add" property. that is
# because audiorate has to "add" samples when
# data is dropped.
self
.
producer
.
send
(
self
.
tag
,
{
"
%s/strain_dropped
"
%
instrument
:
"
%s
\t
%s
"
%
(
t
,
elem
.
get_property
(
"
add
"
))})
# Actually flush all of the kafka messages
self
.
producer
.
flush
()
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment