What do you want to save?
Add Code snippet
New code examples
-
Python 2021-10-29 09:11:09
naive bayes classifier calculating sigma
# Naive Bayes On The Iris Dataset from csv import reader from random import seed from random import randrange from math import sqrt from math import exp from math import pi # Load a CSV file def load_csv(filename): dataset = list() with open(filename, ... Add solution -
Other 2021-10-23 03:27:08
cross validation python
# SVC: support vector classifier (one of the "built-in" classifiers in scikit-learn) # X, y: array-like representing input and target variables # X.shape = (N, num_of_features) # y.shape = (N, 1) in case of classification problem from sklearn.m... Add solution -
Python 2021-08-27 16:13:01
neural network hyperparameter tuning
# random search cross validation in neural network model from keras.models import Sequential from keras.layers import Dense, Dropout from keras.wrappers.scikit_learn import KerasClassifier def report(results, n_top=3): for i in range(1, n_top + 1): ... Add solution