コード例 #1
0
ファイル: iirfile.py プロジェクト: oscarbenjamin/electro
 def __init__(self, *args, **kwargs):
     self._order = kwargs.pop('order', 4)
     flow = kwargs.pop('lowpass', None)
     fhigh = kwargs.pop('highpass', None)
     if None not in [flow, fhigh]:
         self._btype = 'band'
         self._fcrit = numpy.array([flow, fhigh])
     elif flow is not None:
         self._btype = 'low'
         self._fcrit = numpy.array([flow])
     elif fhigh is not None:
         self._btype = 'high'
         self._fcrit = numpy.array([fhigh])
     else:
         raise NotImplementedError
     FilterFile.__init__(self, *args, **kwargs)