Kaggle competition: Titanic - Machine Learning from Disaster
<SOS> metric: categorizationaccuracy Kaggle data source: titanic-machine-learning-from-disaster<drop_column>
train_data = pd.read_csv('.. /input/titanic/train.csv')
 test_data = pd.read_csv('.. /input/titanic/test.csv')
 features = ["Pclass", "Sex", "SibSp", "Parch"]
X_train = pd.get_dummies(train_data[features])
 y_train = train_data["Survived"]
final_X_test = pd.get_dummies(test_data[features])
 input_dim = len(X_train.columns)
 n_neurons = 50
epochs = 100
model = Sequential()
model.add(Dense(n_neurons, input_dim=input_dim, activation='relu'))
model.add(Dense(1, activation='sigmoid'))
model.compile(loss='binary_crossentropy', optimizer='adam', metrics=['accuracy'])
 model.fit(X_train, y_train, epochs=epochs, verbose=0)
 predictions = model.predict(final_X_test)
 predictions =(predictions > 0.5)*1
output = pd.DataFrame({'PassengerId': test_data.PassengerId, 'Survived': predictions.flatten() })
 output.to_csv('submission.csv', index=False )