Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • iain.morton/locklost
  • oli.patane/locklost-olifork
  • timothy.ohanlon/locklost
  • benjaminrobert.mannix/locklost
  • austin.jennings/locklost
  • camilla.compton/locklost
  • arnaud.pele/locklost
  • yamamoto/locklost
  • marc.lormand/locklost
  • saravanan.tiruppatturrajamanikkam/locklost
  • nikhil-mukund/locklost
  • patrick.godwin/locklost
  • yannick.lecoeuche/locklost
  • jameson.rollins/locklost
14 results
Show changes
Showing
with 1162 additions and 271 deletions
This diff is collapsed.
import numpy as np
from gwpy.segments import Segment
from .. import logger
from .. import config
from .. import data
##############################################
def check_soft_limiters(event):
"""Checks if ASC limits are reached for Pitch and Yaw and creates a tag if railed.
"""
if config.IFO == 'L1':
logger.info("followup is not configured or not applicable to LLO.")
return
mod_window = [config.SOFT_SEARCH_WINDOW[0], config.SOFT_SEARCH_WINDOW[1]]
segment = Segment(mod_window).shift(int(event.gps))
data_collect = data.fetch(config.ASC, segment, as_dict=True)
# collects all ASC data for analysis
soft_limits = False
ASC_INMON = [val.data for key, val in data_collect.items() if key in config.ASC_INMON]
# ASC raw input signal
ASC_LIMIT = [val.data for key, val in data_collect.items() if key in config.ASC_LIMIT]
# ASC soft loop limits
ASC_ENABLE = [val.data for key, val in data_collect.items() if key in config.ASC_ENABLE]
# ASC soft loop switch
inputs = [max(i) for i in ASC_INMON]
# pull inmon channels into a list
inputs_max = [max(i) for i in ASC_LIMIT]
# pull threshold values
switch = [max(i) for i in ASC_ENABLE]
# pull toggle values
finallist = []
abs_set_diff = np.abs(inputs)
# take absolute value
sub = np.subtract(abs_set_diff, inputs_max)
# subtract array from limits, if array > 0 it is railed
sub = sub.tolist()
finallist.append(sub)
for el, s in zip(finallist[0], switch):
if el > 0 and s == 1:
soft_limits = True
logger.info('{} is railed.'.format(config.ASC_INMON[finallist[0].index(el)]))
break
if soft_limits:
event.add_tag('SOFT_LIMITERS')
else:
logger.info('No ASC channel hit its soft limit.')
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -11,6 +11,7 @@
<h5 class="panel-title"><a data-toggle="collapse" href="#{{id}}">{{title}} (click to show)</a></h5>
% end
</div>
<br/>
% if expand == True:
<div id="{{id}}" class="panel-collapse">
......
This diff is collapsed.
This diff is collapsed.
% rebase('base.tpl', IFO=IFO, web_script=web_script, online_status=online_status, is_home=is_home)
% import os
% from locklost import config
<h4>Summary Plots: {{epoch}}</h4>
% for id in [epoch]:
<div id={{id}} class="tabcontent">
% plot_dir = os.path.join(config.SUMMARY_ROOT, id)
% for plotname in os.listdir(plot_dir):
% plot_url = os.path.join(config.WEB_ROOT, 'summary', id, plotname)
% include('plots.tpl', plots=[plot_url], size=8)
% end
</div>
% end
This diff is collapsed.
[flake8]
ignore = E226,E501
exclude = locklost/plugins/__init__.py
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.