예제 #1
0
파일: test_apod.py 프로젝트: fenglb/nmrpro
 def test_apod_gmb(self):
     spec = fromBruker(self.filename, False, False)
     spec = apod(spec, w=lambda s: GMB(s, 2, 0.5))
     C = converter()
     u = guess_udic(self.dic,self.data)
     C.from_bruker(self.dic, self.data, u)
     
     pipe_dic, pipe_data = C.to_pipe()
     test_data = pipep.gmb(pipe_dic, pipe_data, lb=2, gb=0.5)[1]
     ts.assert_allclose(spec, test_data, 1e-7,1e-3, 'GBM apodization not equal to NMRPipe processed one.')
예제 #2
0
파일: gmb.py 프로젝트: rpbarnes/nmrglue
#! /usr/bin/env python

import nmrglue.fileio.pipe as pipe
import nmrglue.process.pipe_proc as p

d,a = pipe.read("time_complex.fid")
d,a = p.gmb(d,a,lb=2.0,gb=0.5,c=1.0,inv=True)
pipe.write("gmb.glue",d,a,overwrite=True)

d,a = pipe.read("time_complex.fid")
d,a = p.gmb(d,a,lb=10,gb=0.2,c=0.5,start=20,size=800)
pipe.write("gmb2.glue",d,a,overwrite=True)
예제 #3
0
파일: to_fix.py 프로젝트: winter27/nmrglue
pipe.write("rft10.glue", d, a, overwrite=True)

d, a = pipe.read("freq_real.ft2")
d, a = p.rft(d, a)
pipe.write("rft11.glue", d, a, overwrite=True)

# HT
# ps90-180 mode doesn't match
d, a = pipe.read("1D_freq_real.dat")
d, a = p.ht(d, a, mode="ps90-180")
pipe.write("ht4.glue", d, a, overwrite=True)

# Integration tests
# process 2D mixed mode data
d, a = pipe.read("time_real.fid")
d, a = p.gmb(d, a, gb=0.1, lb=-8, c=0.5)
d, a = p.zf(d, a, auto=True)
d, a = p.ft(d, a, alt=True)  # BUG glue seems to double the data...?
d, a = p.ps(d, a, p0=0, p1=0)
d, a = p.tp(d, a, hyper=True)
d, a = p.sp(d, a, off=0.5, pow=2, c=0.5)
d, a = p.zf(d, a, auto=True)
d, a = p.ft(d, a, auto=True)
d, a = p.ps(d, a, p0=0, p1=0)
d, a = p.di(d, a)
pipe.write("2d_mixed_processing1.glue", d, a, overwrite=True)

# process 2D mixed mode data
d, a = pipe.read("time_real.fid")
d, a = p.em(d, a, lb=8)
d, a = p.zf(d, a, auto=True)
예제 #4
0
#! /usr/bin/env python

import nmrglue.fileio.pipe as pipe
import nmrglue.process.pipe_proc as p

d, a = pipe.read("time_complex.fid")
d, a = p.gmb(d, a, lb=2.0, gb=0.5, c=1.0, inv=True)
pipe.write("gmb.glue", d, a, overwrite=True)

d, a = pipe.read("time_complex.fid")
d, a = p.gmb(d, a, lb=10, gb=0.2, c=0.5, start=20, size=800)
pipe.write("gmb2.glue", d, a, overwrite=True)