Did I find the right examples for you? yes no

All Samples(11)  |  Call(7)  |  Derive(0)  |  Import(4)

src/p/y/pyFASST-0.9.2/pyfasst/tftransforms/nsgt/nsgfwin_sl.py   pyFASST(Download)
 
import numpy as N
from util import hannwin,blackharr,blackharrcw
from math import ceil
from warnings import warn
        g = [blackharr(m) for m in M]
    else:
        g = [hannwin(m) for m in M]
 
    if sliced:
        for kk in (1,lbas+2):
            if M[kk-1] > M[kk]:
                g[kk-1] = N.ones(M[kk-1],dtype=g[kk-1].dtype)
                g[kk-1][M[kk-1]//2-M[kk]//2:M[kk-1]//2+ceil(M[kk]/2.)] = hannwin(M[kk])
        M = N.array([ceil(m/4)*4 for m in M],dtype=int)
    else:
        g = [hannwin(m) for m in M]
 
 
            if M[kk-1] > M[kk]:
                g[kk-1] = N.ones(M[kk-1],dtype=g[kk-1].dtype)
                g[kk-1][M[kk-1]//2-M[kk]//2:M[kk-1]//2+ceil(M[kk]/2.)] = hannwin(M[kk])
 
        rfbas = N.round(fbas/2.).astype(int)*2

src/p/y/pyFASST-0.9.2/pyfasst/tftransforms/nsgt/unslicing.py   pyFASST(Download)
import numpy as N
from itertools import izip,cycle,chain
from util import hannwin
 
def slicequads(frec_sliced,hhop):
        htr = tr_area//2
        htr2 = tr_area2//2
        hw = hannwin(tr_area2)
        tw = N.zeros(sl_len,dtype=dtype)
        tw[max(hhop-htr-htr2,0):hhop-htr] = hw[htr2:]

src/p/y/pyFASST-0.9.2/pyfasst/tftransforms/nsgt/slicing.py   pyFASST(Download)
 
import numpy as N
from util import hannwin
from reblock import reblock
from itertools import chain,izip,cycle
def makewnd(sl_len,tr_area):
    hhop = sl_len//4
    htr = tr_area//2
    # build window function within one slice (centered with transition areas around sl_len/4 and 3*sl_len/4    
    w = hannwin(2*tr_area)  # window is shifted

src/p/y/pyFASST-0.9.2/pyfasst/tftransforms/nsgt/nsgfwin.py   pyFASST(Download)
 
import numpy as N
from util import hannwin,_isseq
 
def nsgfwin(fmin,fmax,bins,sr,Ls,min_win=4):
 
    M = N.clip(M,min_win,N.inf).astype(int)    
    g = [hannwin(m) for m in M]
 
    fbas[lbas] = (fbas[lbas-1]+fbas[lbas+1])/2