score:1
Accepted answer
you may compare python path under eclipse and terminal by
import sys
print ( sys.path )
the order of entries does matter. my guess is that the fact that your python file is in a folder called sklearn
( i.e .../project/src/sklearn
) is messing the import statement.
requested edit: as it turned out, the problem was that the python script was in a folder called sklearn
and python would look into that folder to import svm
.
Source: stackoverflow.com
Related Query
- Python code get error in eclipse while it runs fine in terminal
- OpenCV C++ code runs fine in terminal but error in running from eclipse - Ubuntu 12.04
- Python code works, but eclipse shows error - Syntax error while detecting tuple
- Pretty Printers Error while executing Python code in Eclipse Ubuntu 14
- Execution fails via java -jar while the same code runs fine through eclipse
- Code fail with name is not defined error running with pydev but runs fine from terminal
- Python script runs fine from command line, file not found error when using Eclipse and PyDev
- I am getting result while debug the code but I see error when I run the code in python using eclipse IDE
- Can't connect to any URI error while commiting code from Eclipse to Git Repository
- I get java code 13 error when i try to run eclipse
- Code in IntelliJ IDEA marked with compiler error where it works fine in Eclipse
- A short c++ file and makefile: I can make in the shell, but get lots of error while building it in the Eclipse
- array_map showing syntax error in eclipse , but code is working fine
- Error occurs while calling Scala code in Java in Eclipse
- While installing android plugin for eclipse indigo get the following error
- While debugging in eclipse the code navigation buttons get disabled, the stackframe also is not visible
- Error while configuring python with eclipse pydev plugin on WIndows
- Get error when coding Python in Eclipse
- Running a Java code in cmd is not working while everything is fine in Eclipse
- Java code working fine in Eclipse but jar file throwing error
- ruby splat operator compilation error in eclipse but runs fine on command line
- I keep getting this error when I run this code while working with OpenGL in Eclipse
- Python 'unexpected EOF while parsing' eclipse pydev run selected code
- RMI - run client code on Eclipse throws MarshalException while execute from console works fine
- JFuzzyLogic gives error in Eclipse IDE while code working well with another IDE
- Maven not copying .class files to target while in building though build runs fine in Unix,but the same works in eclipse
- Python & Eclipse - Get curent filename error
- This code datasource configurarion in tomme is running without eclipse fine but when i run in eclipse then its giving error
- Egit transport error while connecting to eclipse source code
- Getting Error during while porting code from Eclipse to Android Studio
More Query from same tag
- importing source code of mysql Jdbc driver into eclipse workspace
- Nothing is being output to the console! (Java, Eclipse Mars)
- What is the right way to create JUnit tests for Eclipse fragments?
- Verification Errors while trying to port Android application to BlackBerry 10
- Implement text search in eclipse across workspace
- Eclipse putting each parameter on new lines, how to stop this formatting
- Customize Eclipse's java stack trace console formatter
- how to swap clipboard content with selection upon keyboard shortcut
- How can I make a connection with a device, on which an API is running, through IP?
- Running two instances of android device in Eclipse
- Can't check a target for my AVD
- java - Editor does not contain a main type
- How to make Eclipse (pydev) automatically fold all comments when opening a file?
- Eclipse shortcut for 'Expand All' in Synchronize view
- Eclipse shortcut to open run/debug configuration list
- Not able to connect Oracle 10g XE to Eclipse
- Persistent object in BlackBerry Application
- How to find xml.xsd in Tomcat 9
- How to install OAuth (e.g. apache oltu) in order to use an API with Eclipse for Java
- how to invoke viewpart by java code in eclipse plugin
- Error in C++ eclipse project using Boost libraries
- How do I debug errors in Eclipse with Java? What do these exceptions mean?
- There was protected in a file created automatically what was private
- Error while installing PMD in eclipse kepler
- Using the Android SDK on a Mac, Eclipse is really slow. How can I speed it up?
- Why does the String not reset to null?
- if else if not outputing else if statement java
- Variables in PDE map files
- Set up Run Configuration for embedded system
- Can Eclipse Tomcat automatically pick up added files in common project?