Top "Machine-learning" questions

Implementation questions about machine learning algorithms.

gradient descent using python and numpy

def gradient(X_norm,y,theta,alpha,m,n,num_it): temp=np.array(np.zeros_like(theta,float)) for …

python numpy machine-learning linear-regression gradient-descent
How to write a confusion matrix in Python?

I wrote a confusion matrix calculation code in Python: def conf_mat(prob_arr, input_arr): # confusion matrix conf_arr = [[0, 0], [0, 0]] …

python machine-learning
Accuracy Score ValueError: Can't Handle mix of binary and continuous target

I'm using linear_model.LinearRegression from scikit-learn as a predictive model. It works and it's perfect. I have a problem …

python machine-learning scikit-learn linear-regression prediction
What are advantages of Artificial Neural Networks over Support Vector Machines?

ANN (Artificial Neural Networks) and SVM (Support Vector Machines) are two popular strategies for supervised machine learning and classification. It's …

machine-learning neural-network classification svm
Can Keras with Tensorflow backend be forced to use CPU or GPU at will?

I have Keras installed with the Tensorflow backend and CUDA. I'd like to sometimes on demand force Keras to use …

python machine-learning tensorflow keras
How to concatenate two layers in keras?

I have an example of a neural network with two layers. The first layer takes two arguments and has one …

python machine-learning keras neural-network
What is the meaning of the word logits in TensorFlow?

In the following TensorFlow function, we must feed the activation of artificial neurons in the final layer. That I understand. …

tensorflow machine-learning neural-network deep-learning cross-entropy
Save classifier to disk in scikit-learn

How do I save a trained Naive Bayes classifier to disk and use it to predict data? I have the …

python machine-learning scikit-learn classification
scikit-learn random state in splitting dataset

Can anyone tell me why we set random state to zero in splitting train and test set. X_train, X_…

python random machine-learning scikit-learn
How to implement the ReLU function in Numpy

I want to make a simple neural network which uses the ReLU function. Can someone give me a clue of …

python numpy machine-learning neural-network