spyder

Builtin function not working with Spyder

痞子三分冷 提交于 2019-11-26 04:01:40
问题 I\'m trying to use the max function in Python 3,6: print(\'Maximum is:\', max(1, 3, 2, 5, 4)) And the result is File \"E:/ProgramyRobione/untitled1.py\", line 2, in <module> print(\'Maximum is:\', max(1, 3, 2, 5, 4)) TypeError: \'int\' object is not callable I\'m using Spyder and that line is all that code should do. 回答1: This is a bit of an iPython headshot that comes with Spyder. I've fallen foul of this when copy/pasting random bits of code from SO to test only to find really odd behaviour

Adding a module (Specifically pymorph) to Spyder (Python IDE)

余生颓废 提交于 2019-11-26 03:06:35
问题 I have managed to get spyder installed and functioning on my mac but I want to add in a few modules that it doesn\'t include by default (mahotas and pymorph). I installed both via easy_install in the terminal and both seemed to install without any error messages. Running python from a terminal and using import mahotas and import pymorph works just fine without error messages. However, when I run the same lines from a script within spyder I get the following error: Traceback (most recent call