MERHABA BEN BU SAYFADA KENDİMİ MOTİVE ETMEK İÇİN KURDUM. BU SİTE BENİM
Bias & variance
# for building linear regression models from sklearn.linear_model import LinearRegression, Ridge # import lab utility functions in utils.py import utils # Split the dataset into train, cv, and test x_train, y_train, x_cv, y_cv, x_test, y_test = utils.prepare_dataset('data/c2w3_lab2_data1.csv') print(f"the shape of the training set (input) is: {x_train.shape}") print(f"the shape of the training set (target) is: {y_train.shape}\n") print(f"the shape of the cross validation set (input) is: {x_cv.shape}") print(f"the shape of the cross validation set (target) is: {y_cv.shape}\n") # Preview the first 5 rows print(f"first 5 rows of the training inputs (1 feature):\n {x_train[:5]}\n") # Instantiate the regression model class model = LinearRegression() # Train and plot polynomial regression models utils.train_plot_poly(model, x_train, y_train, x_cv, y_cv, max_degree=10, baseline=400) # Train and plot polynomial regression mode...
Hocam site boş!!!
YanıtlaSilBu yorum yazar tarafından silindi.
Sil