@@ -1,7 +1,7 | |||||
1 | import numpy |
|
1 | import numpy | |
2 | cimport numpy |
|
2 | cimport numpy | |
3 |
|
3 | |||
4 |
def decoder(numpy.ndarray[numpy. |
|
4 | def decoder(numpy.ndarray[numpy.complex_t, ndim=2] fft_code, numpy.ndarray[numpy.complex_t, ndim=2] data): | |
5 |
|
5 | |||
6 | fft_data = numpy.fft.fft(data, axis=1) |
|
6 | fft_data = numpy.fft.fft(data, axis=1) | |
7 | conv = fft_data*fft_code |
|
7 | conv = fft_data*fft_code |
@@ -629,7 +629,7 class Decoder(Operation): | |||||
629 | return ndatadec, datadec |
|
629 | return ndatadec, datadec | |
630 |
|
630 | |||
631 | def convolutionInFreqOpt(self, data): |
|
631 | def convolutionInFreqOpt(self, data): | |
632 |
|
632 | ini = time.time() | ||
633 | fft_code = self.fft_code[self.__profIndex].reshape(1,-1) |
|
633 | fft_code = self.fft_code[self.__profIndex].reshape(1,-1) | |
634 |
|
634 | |||
635 | data = cfunctions.decoder(fft_code, data) |
|
635 | data = cfunctions.decoder(fft_code, data) | |
@@ -642,7 +642,7 class Decoder(Operation): | |||||
642 | return ndatadec, datadec |
|
642 | return ndatadec, datadec | |
643 |
|
643 | |||
644 | self.__profIndex += 1 |
|
644 | self.__profIndex += 1 | |
645 |
|
645 | print time.time() - ini | ||
646 | return ndatadec, datadec |
|
646 | return ndatadec, datadec | |
647 |
|
647 | |||
648 | def convolutionInTime(self, data): |
|
648 | def convolutionInTime(self, data): |
General Comments 0
You need to be logged in to leave comments.
Login now