T-bone 7 years ago
parent
commit
18d1e2e69c
3 changed files with 7 additions and 30 deletions
  1. 1
    1
      akvo/gui/akvoGUI.py
  2. 2
    2
      akvo/tressel/filtfilt.py
  3. 4
    27
      setup.py

+ 1
- 1
akvo/gui/akvoGUI.py View File

1
 #/usr/bin/env python 
1
 #/usr/bin/env python 
2
 import sys
2
 import sys
3
-import readline
3
+#import readline
4
 try: 
4
 try: 
5
     from akvo.gui.main_ui import Ui_MainWindow
5
     from akvo.gui.main_ui import Ui_MainWindow
6
     uicerr = False
6
     uicerr = False

+ 2
- 2
akvo/tressel/filtfilt.py View File

35
     edge=ntaps*3
35
     edge=ntaps*3
36
 
36
 
37
     if x.ndim != 1:
37
     if x.ndim != 1:
38
-        raise ValueError, "Filiflit is only accepting 1 dimension arrays."
38
+        raise ValueError("Filiflit is only accepting 1 dimension arrays.")
39
 
39
 
40
     #x must be bigger than edge
40
     #x must be bigger than edge
41
     if x.size < edge:
41
     if x.size < edge:
42
-        raise ValueError, "Input vector needs to be bigger than 3 * max(len(a),len(b)."
42
+        raise ValueError("Input vector needs to be bigger than 3 * max(len(a),len(b).")
43
 
43
 
44
     if len(a) < ntaps:
44
     if len(a) < ntaps:
45
         a=r_[a,zeros(len(b)-len(a))]
45
         a=r_[a,zeros(len(b)-len(a))]

+ 4
- 27
setup.py View File

1
 #!/usr/bin/env python
1
 #!/usr/bin/env python
2
-import sys
3
 
2
 
4
-# optionally use qt4
5
-# if sys.argv[1] == "build_ui":
6
-#     try:
7
-#         from pyqt_distutils.build_ui import build_ui
8
-#         cmdclass = {'build_ui': build_ui}
9
-#     except ImportError:
10
-#         build_ui = None  # user won't have pyqt_distutils when deploying
11
-#         cmdclass = {}
12
-# else:
13
-#     build_ui = None  # user won't have pyqt_distutils when deploying
14
-#     cmdclass = {}
15
-
16
-# Require PyQt5 and compiltion of GUI files via pyuic 
3
+# Requires PyQt5 and compiltion of GUI files via pyuic 
17
 from setuptools import setup, Extension
4
 from setuptools import setup, Extension
18
 from setuptools.command.build_py import build_py
5
 from setuptools.command.build_py import build_py
19
 from pyqt_distutils.build_ui import build_ui
6
 from pyqt_distutils.build_ui import build_ui
23
         self.run_command('build_ui')
10
         self.run_command('build_ui')
24
         build_py.run(self)
11
         build_py.run(self)
25
 
12
 
26
-try:
27
-    from Cython.Build import cythonize as cythonise
28
-except ImportError:
29
-    def cythonise(*args, **kwargs):
30
-        #from Cython.Build import cythonize
31
-        #return cythonize(*args, **kwargs)
32
-        return 
33
-
34
-#from distutils.core import setup
35
-
36
 setup(name='Akvo',
13
 setup(name='Akvo',
37
       version='1.0.5',
14
       version='1.0.5',
38
       description='Surface nuclear magnetic resonance workbench',
15
       description='Surface nuclear magnetic resonance workbench',
42
       #setup_requires=['PyQt5'],
19
       #setup_requires=['PyQt5'],
43
       setup_requires=[
20
       setup_requires=[
44
         # Setuptools 18.0 properly handles Cython extensions.
21
         # Setuptools 18.0 properly handles Cython extensions.
45
-        'PyQt5','setuptools>=18.0',
22
+        #'PyQt', 
23
+        'pyqt_distutils','setuptools>=18.0',
46
       ],
24
       ],
47
 #      ext_modules = cythonise("akvo/tressel/*.pyx"), 
25
 #      ext_modules = cythonise("akvo/tressel/*.pyx"), 
48
 #      build_requires=['cython'],
26
 #      build_requires=['cython'],
52
           'matplotlib',
30
           'matplotlib',
53
           'scipy',
31
           'scipy',
54
           'numpy',
32
           'numpy',
55
-          'PyQt5',
33
+#          'PyQt5',
56
           'pyyaml',
34
           'pyyaml',
57
           'pyqt-distutils',
35
           'pyqt-distutils',
58
           'cmocean'
36
           'cmocean'
69
           'build_ui': build_ui,
47
           'build_ui': build_ui,
70
           'build_py': custom_build_py,
48
           'build_py': custom_build_py,
71
       },
49
       },
72
-      #cmdclass=cmdclass,
73
       # Mechanism to include auxiliary files
50
       # Mechanism to include auxiliary files
74
       include_package_data=True,
51
       include_package_data=True,
75
       package_data={
52
       package_data={

Loading…
Cancel
Save