샘플 데이터와 Stacking Classification
·
Machine Learning/Boosting
샘플 데이터와 Stacking Classification¶ In [1]: import pandas as pd import numpy as np import matplotlib.pyplot as plt np.random.seed(2021) 1. Data¶ 1.1 Sample Data¶ In [2]: from sklearn.datasets import make_classification data, label = make_classification( n_samples=1000, n_features=20, n_informative=15, n_redundant=5, random_state=2021 ) In [3]: data.shape, label.shape Out[3]: ((1000, 20), (1000,)) 1..
샘플 데이터와 Stacking Regression
·
Machine Learning/Boosting
샘플 데이터와 Stacking Regression¶ In [1]: import pandas as pd import numpy as np import matplotlib.pyplot as plt np.random.seed(2021) 1. Data¶ 1.1 Sample Data¶ In [2]: from sklearn.datasets import make_regression data, label = make_regression(n_samples=1000, n_features=20, n_informative=15, noise=0.1, random_state=1) In [3]: data.shape, label.shape Out[3]: ((1000, 20), (1000,)) 1.2 Data EDA¶ In [4]: ..
Boosting Classification 심화 실습- 뉴스 분류
·
Machine Learning/Boosting
뉴스 분류하기¶ In [1]: !pip install catboost Requirement already satisfied: catboost in /usr/local/lib/python3.7/dist-packages (1.0.0) Requirement already satisfied: plotly in /usr/local/lib/python3.7/dist-packages (from catboost) (4.4.1) Requirement already satisfied: pandas>=0.24.0 in /usr/local/lib/python3.7/dist-packages (from catboost) (1.1.5) Requirement already satisfied: scipy in /usr/local/li..
Boosting Regression 심화 실습 - 부동산 가격 예측
·
Machine Learning/Boosting
부동산 가격 예측하기¶ In [16]: pip install lightgbm Collecting lightgbm Downloading lightgbm-4.1.0-py3-none-win_amd64.whl (1.3 MB) ---------------------------------------- 1.3/1.3 MB 3.1 MB/s eta 0:00:00 Requirement already satisfied: numpy in c:\users\sjy99\appdata\local\programs\python\python311\lib\site-packages (from lightgbm) (1.23.5) Requirement already satisfied: scipy in c:\users\sjy99\appdata\lo..
샘플 데이터와 Boosting Classification
·
Machine Learning/Boosting
샘플 데이터와 Boosting Classification¶ In [1]: import pandas as pd import numpy as np import matplotlib.pyplot as plt np.random.seed(2021) 1. Data¶ 1.1 Sample Data¶ 실습에서 사용할 데이터를 생성해보겠습니다. In [2]: from sklearn.datasets import make_gaussian_quantiles data_1, label_1 = make_gaussian_quantiles( cov=2, n_samples=200, n_features=2, n_classes=2, random_state=2021 ) data_2, label_2 = make_gaussian_quantiles(..
샘플 데이터와 Boosting Regression
·
Machine Learning/Boosting
샘플 데이터와 Boosting Regression¶ In [1]: import pandas as pd import numpy as np import matplotlib.pyplot as plt np.random.seed(2021) 1. Data¶ 1.1 Sample Data¶ 실습에서 사용할 데이터를 생성해보겠습니다. In [2]: data = np.linspace(0, 6, 150)[:, np.newaxis] label = np.sin(data).ravel() + np.sin(6 * data).ravel() noise = np.random.normal(data.shape[0]) * 0.01 label += noise In [3]: plt.scatter(data, label) Out[3]: 1.2 Dat..