简体   繁体   中英

OSError: [WinError 193] %1 is not a valid Win32 application (Pandas)

I have been trying a simple code on Pycharm 2019.2.1 on windows 10 (64bit)

'''
import pandas as pd
from sklearn.model_selection import train_test_split
from sklearn.linear_model import LinearRegression
df = pd.read_csv('covid_19_clean_complete.csv')
X = df[["Deaths"]]
Y = df["Confirmed"]
X_train, X_test, Y_train, Y_test = train_test_split(X, Y, test_size=.25, random_state=42)
acr = LinearRegression()    
acr.fit(X_train,Y_train)
print(acr.score(X_test,Y_test))
'''

but showing me this error

error massage

I've already uninstalled pandas once and installed again using pip uninstall pandas and pip install pandas through cmd. pandas installed photo

Interpreter photo

Did much google search but the links I found, were not clear to me(as I faced such problem first). Here's the link OSError: [WinError 193] %1 is not a valid Win32 application

Hope to find a solution. Thank You

Finally, all I did was uninstall Pycharm and python as well from my system. Obviously, again I had to install those. Then the problem solved.

happy_coding_

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM