Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions pywt/_extensions/_cwt.pyx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#cython: boundscheck=False, wraparound=False
cimport common, c_wt
from common cimport pywt_index_t, MODE
from . cimport common
from . cimport c_wt
from .common cimport pywt_index_t, MODE
from ._pywt cimport _check_dtype

cimport numpy as np
Expand Down
5 changes: 3 additions & 2 deletions pywt/_extensions/_dwt.pyx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#cython: boundscheck=False, wraparound=False
cimport common, c_wt
from common cimport pywt_index_t, MODE
from . cimport common
from . cimport c_wt
from .common cimport pywt_index_t, MODE
from ._pywt cimport _check_dtype

cimport numpy as np
Expand Down
2 changes: 1 addition & 1 deletion pywt/_extensions/_pywt.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cimport wavelet
from . cimport wavelet
cimport numpy as np
include "config.pxi"

Expand Down
8 changes: 4 additions & 4 deletions pywt/_extensions/_pywt.pyx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Copyright (c) 2006-2012 Filip Wasilewski <http://en.ig.ma/>
# Copyright (c) 2012-2016 The PyWavelets Developers
# Copyright (c) 2012-2018 The PyWavelets Developers
# <https://github.com/PyWavelets/pywt>
# See COPYING for license details.

Expand All @@ -11,8 +11,8 @@ __all__ = ['MODES', 'Modes', 'DiscreteContinuousWavelet', 'Wavelet',
import warnings
import re

cimport c_wt
cimport common
from . cimport c_wt
from . cimport common
from ._dwt cimport upcoef
from ._cwt cimport cwt_psi_single

Expand Down Expand Up @@ -1044,7 +1044,7 @@ cpdef np.dtype _check_dtype(data):
def keep(arr, keep_length):
length = len(arr)
if keep_length < length:
left_bound = (length - keep_length) / 2
left_bound = (length - keep_length) // 2
return arr[left_bound:left_bound + keep_length]
return arr

Expand Down
6 changes: 3 additions & 3 deletions pywt/_extensions/_swt.pyx
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#cython: boundscheck=False, wraparound=False
cimport common
cimport c_wt
from . cimport common
from . cimport c_wt

import warnings
import numpy as np
cimport numpy as np

from common cimport pywt_index_t
from .common cimport pywt_index_t
from ._pywt cimport c_wavelet_from_object, cdata_t, Wavelet, _check_dtype

include "config.pxi"
Expand Down
6 changes: 3 additions & 3 deletions pywt/_extensions/c_wt.pxd
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
# <https://github.com/PyWavelets/pywt>
# See COPYING for license details.

from common cimport (MODE, pywt_index_t, ArrayInfo, Coefficient,
DiscreteTransformType)
from wavelet cimport DiscreteWavelet, ContinuousWavelet
from .common cimport (MODE, pywt_index_t, ArrayInfo, Coefficient,
DiscreteTransformType)
from .wavelet cimport DiscreteWavelet, ContinuousWavelet

include "config.pxi"

Expand Down
2 changes: 1 addition & 1 deletion pywt/_extensions/wavelet.pxd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from common cimport pywt_index_t
from .common cimport pywt_index_t

cdef extern from "c/wavelets.h":
ctypedef enum SYMMETRY:
Expand Down
3 changes: 1 addition & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,7 @@ def get_cython_sources(use_cython):
for k, v in py_defines.items():
fd.write('%s = %d\n' % (k, int(v)))


cythonize_opts = {}
cythonize_opts = {'language_level': '3'}
if os.environ.get("CYTHON_TRACE"):
cythonize_opts['linetrace'] = True
cython_macros.append(("CYTHON_TRACE_NOGIL", 1))
Expand Down