This is code to consume processed data from XPD back into document model
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class FileStoreSquashing(FileStorePluginBase): | |
'''Write out 'squashed' files | |
.. note:: | |
See :class:`FileStoreBase` for the rest of the required parametrs | |
This mixin will also configure the ``cam`` and ``proc`` plugins | |
on the parent. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
if [ -a $1/bin/conda ]; then | |
# we are in a conda env | |
# save old QT_PLUGIN_PATH | |
OLD_QT=$QT_PLUGIN_PATH |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git+https://github.com/pcdshub/QDarkStyleSheet.git | |
git+https://github.com/pcdshub/happi.git | |
git+https://github.com/pcdshub/typhon.git | |
git+https://github.com/slaclab/pydm.git | |
git+https://github.com/tacaswell/caproto.git@fix_alarm_subscriptions | |
git+https://github.com/tacaswell/timechart.git@fix_future_pydm | |
jinja2 | |
numpy | |
ophyd | |
prettytable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from epics import caput, caget | |
from itertools import count | |
for j in count(): | |
try: | |
ret = caget('XF:31IDA-BI{Cam:Tbl}cam1:PortName_RBV') | |
if ret is None: | |
raise TimeoutError('failed on XF:31IDA-BI{Cam:Tbl}cam1:PortName_RBV') | |
ret = caget('XF:31IDA-BI{Cam:Tbl}image1:EnableCallbacks_RBV') | |
if ret is None: | |
raise TimeoutError('failed on XF:31IDA-BI{Cam:Tbl}image1:EnableCallbacks_RBV') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/bash | |
set -e | |
TARGET_ENV=bleeding | |
OSPATH=~/source/other_source/ | |
PSPATH=~/source/p | |
DSPATH=~/source/bnl | |
pull_build () { | |
git pull || echo failed |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
*.h5 | |
.ipynb_checkpoints/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Python 3.9.0a5+ (heads/master:799d7d61a9, Apr 6 2020, 17:38:49) | |
Type 'copyright', 'credits' or 'license' for more information | |
IPython 8.0.0.dev -- An enhanced Interactive Python. Type '?' for help. | |
In [1]: 1 /0 | |
Traceback (most recent call last): | |
File "/home/tcaswell/.virtualenvs/bleeding/lib/python3.9/site-packages/IPython/core/interactiveshell.py", line 3331, in run_code | |
exec(code_obj, self.user_global_ns, self.user_ns) | |
File "<ipython-input-1-a37332903225>", line 1, in <module> | |
1 /0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from event_model import compose_run | |
import datetime | |
import dateutil.parser | |
import itertools | |
from io import StringIO | |
import subprocess | |
import numpy as np | |
import functools | |
def extract_event(ts, batch): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def format_frac(fr): | |
'''Convert a/b to latex''' | |
sp = str(fr).split('/') | |
if len(sp) == 1: | |
return sp[0] | |
else: | |
return r'$\frac{%s}{%s}$' % tuple(sp) | |
frac_size = 4 |