Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

joblib

from sklearn.externals import joblib
joblib.dump(svc,'project21-carcomforttype.obj')
----------------------------------------------------------------------
model=joblib.load('project21-carcomforttype.obj')
----------------------------------------------------------------------
Final_predictions=model.predict(x_test)
Final_predictions=pd.DataFrame(Final_predictions,columns=['unacc(0),acc(1),good(2),vgood(3)'])
Final_predictions[:5]
----------------------------------------------------------------------
Final_predictions.sample(n=10)
--------------------------------------------------------------------
#Saving final predictions in file.csv format
Final_predictions.to_csv('E:final_predictionscarcomforttype',index=False)
Comment

joblib example

from math import sqrt
>>> from joblib import Parallel, delayed
>>> Parallel(n_jobs=2)(delayed(sqrt)(i ** 2) for i in range(10))
[0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0]
Comment

joblib

joblib.dump(svc,'project21-carcomforttype.obj')
model=joblib.load('project21-carcomforttype.obj')
Comment

PREVIOUS NEXT
Code Example
Python :: python use variable in another file 
Python :: combine two dataframe in pandas 
Python :: what is python used for 
Python :: case insensitive replace python 
Python :: python ndim 
Python :: write results in csv file python 
Python :: remove all instances from list python 
Python :: self.app = Tk() 
Python :: Configuring Django to Send Emails with mailgun 
Python :: save plotly figure as png python 
Python :: argeparse can it take a type list 
Python :: Simple way to measure cell execution time in ipython notebook 
Python :: python join with int 
Python :: how to take input from user in python 
Python :: how to search a file in windows 10 using python 
Python :: check if anything in a list is in a string python 
Python :: capitalise words in a column pandas 
Python :: with open python 
Python :: mac why is python installed in usr and application 
Python :: tkmessagebox not found 
Python :: how to select python 3 interpreter in linux 
Python :: convert string to dictionary python 
Python :: Palindrome Check using for loop in python 
Python :: get index of highest value in array python 
Python :: check if date is valid python 
Python :: create new env in anaconda 
Python :: django __str__ self multiple 
Python :: The int type in Python3 cannot represent a number greater than 2^31-1. 
Python :: how to remove rows with certain values pandas 
Python :: python socket check if still connected 
ADD CONTENT
Topic
Content
Source link
Name
8+9 =