@@ -1,7 +1,7 | |||
|
1 | 1 | import numpy |
|
2 | 2 | cimport numpy |
|
3 | 3 | |
|
4 | def decoder(numpy.ndarray[numpy.float32, ndim=2] fft_code, numpy.ndarray[numpy.complex, ndim=2] data): | |
|
4 | def decoder(numpy.ndarray[numpy.float32_t, ndim=2] fft_code, numpy.ndarray[numpy.complex_t, ndim=2] data): | |
|
5 | 5 | |
|
6 | 6 | fft_data = numpy.fft.fft(data, axis=1) |
|
7 | 7 | conv = fft_data*fft_code |
@@ -596,7 +596,7 class Decoder(Operation): | |||
|
596 | 596 | |
|
597 | 597 | self.__nChannels, self.__nHeis = shape |
|
598 | 598 | |
|
599 | self.__codeBuffer = numpy.zeros((self.nCode, self.__nHeis), dtype=numpy.float) | |
|
599 | self.__codeBuffer = numpy.zeros((self.nCode, self.__nHeis), dtype=numpy.float32) | |
|
600 | 600 | |
|
601 | 601 | self.__codeBuffer[:,0:self.nBaud] = self.code |
|
602 | 602 | |
@@ -686,7 +686,10 class Decoder(Operation): | |||
|
686 | 686 | if mode == 1: |
|
687 | 687 | print "This function is not implemented" |
|
688 | 688 | # ndatadec, datadec = self.convolutionInTime(dataOut.data) |
|
689 |
|
|
|
689 | ||
|
690 | if mode == 3: | |
|
691 | ndatadec, datadec = self.convolutionInFreqOpt(dataOut.data) | |
|
692 | ||
|
690 | 693 | dataOut.data = datadec |
|
691 | 694 | |
|
692 | 695 | dataOut.heightList = dataOut.heightList[0:ndatadec] |
General Comments 0
You need to be logged in to leave comments.
Login now