SHARE
TWEET

Untitled

a guest Jun 24th, 2019 59 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # Initalizign the ANN
  2. classifier = Sequential()
  3.  
  4. # Adding the input layer and the first hidden layer
  5. classifier.add(Dense(units = 6, kernel_initializer = 'uniform', activation = 'relu', input_dim = 11))
  6.  
  7. # Adding the second hidden layer
  8. classifier.add(Dense(units = 6, kernel_initializer = 'uniform', activation = 'relu'))
  9.  
  10. # Adding the output layer
  11. classifier.add(Dense(units = 1, kernel_initializer = 'uniform', activation = 'sigmoid'))
  12.  
  13. #Compiling the ANN
  14. classifier.compile(optimizer = 'adam', loss = 'binary_crossentropy', metrics = ['accuracy'])
  15.      
  16. classifier.fit(X_train, Y_train, batch_size = 10, epochs = 100)
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top