import numpy as np import matplotlib.pyplot as plt from demod_filter import demod_filter import code.common.filehandler as fh import glob samp_rate = 50e6 / 100. / 22. / 38. df = demod_filter(25, 2.0) col = 2 row = 14 fig1 = plt.figure(1) ax1 = fig1.add_subplot(111) inter = np.zeros(131072) inter2 = np.zeros(131072) files = glob.glob( '/data/cryo/20151204/det_on_2000_triangle_scan_call_0.5mms_25hz0.011') #files=glob.glob('/data/cryo/20151203/det_on_2000_overnight_0.5mms_25hz0.???') #files=glob.glob('/data/cryo/20151204/det_on_2000_triangle_scan_0.5mms_25hz0.???') for f in files: print f data = fh.get_mce_data(f, row_col=True) tes = data[row, col, :] - np.mean(data[row, col, :]) tes2 = data[14, col, :] - np.mean(data[14, col, :]) d_filter, d_fft = df.demod(tes, samp_rate) d_filter2, d_fft2 = df.demod(tes2, samp_rate) min_filter = np.min(d_filter) max_filter = np.max(d_filter)
import numpy as np import matplotlib.pyplot as plt from demod_filter import demod_filter import code.common.filehandler as fh import glob from scipy import signal import mce_data samp_rate = 50e6 / 100. / 22. / 38. df = demod_filter(25, 4) col_best = 2 row_best = 14 num_points = 131072 nrows = 22 ncols = 4 c0 = [0, 1, 10, 11, 12, 15, 19, 21] c1 = [1, 2, 5, 6, 7, 14, 15, 17, 18] c2 = [7, 8, 10, 11, 12, 14] c3 = [1, 2, 3, 7, 8, 9, 10, 11, 12, 13] row_arrays = [c0, c1, c2, c3] if 1 == 0: data = mce_data.SmallMCEFile( '/data/cryo/20151204/det_on_2000_triangle_scan_call_0.5mms_25hz0.0') ctime_init = data.header['runfile_id'] demod_all = np.array([]) for i in np.arange(273):