Skip to content

Instantly share code, notes, and snippets.

View danielballan's full-sized avatar

Dan Allan danielballan

View GitHub Profile
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@danielballan
danielballan / srx-pvs.yml
Last active August 29, 2015 14:15
sample pv yaml file
"Nano-positioners or Whatever This Name is for Humans":
EpicsMotor:
nptx:
read_pv: XF:23ID1...
upsample: 'linear'
downsample: 'mean'
npty:
read_pv: XP:2dID1-ES{Dif...
"Sample Positions":
import re
import tokenize
import keyword
import os
import sys
import yaml
from ophyd import controls
BEAMLINE_ALIASES = {
# project beamlines
import h5py
class AD_HDF5Handler(object):
def __init__(self, filename, frame_per_point):
dataset_name = '/entry/data/data'
f = h5py.File(filename)
self.dataset = f[dataset_name]
def __call__(self, point_number):
return self.dataset[point_number, :, :]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.