title: Predict outcome based on user input with Neural Network
body: <p>I have wrote a code for simple <code>neural network</code> in <code>Python</code>. Neural network uses <code>Sigmoid</code> function to predict outcome (0 or 1).
  My question is, how can I predict outcome based on my own input?</p>
  
  <p>For example, I want to make prediction for these input values:</p>
  
  <pre><code>input 1: 0.3
  input 2: -0.1
  input 3: 0.1
  
  my_input = [0.3, -0.1, 0.1]
  </code></pre>
  
  <p>Where should I pass this parameters / inputs?
  This is the code that I have:</p>
  
  <pre><code>import numpy as np
  import pandas as pd
  
  
  df = pd.DataFrame({'input 1':[0.5, 0.3, 0, 0.1, 0.4, -0.4, 0.4, 0.1, -0.6, 0.2, 0.6, 0, 0.2, 0.2, -0.1, -0.1, 0, 0.4, -0.2, -0.4],
                     'input 2':[0.3, 0.6, -0.4, -0.2, 0.9, 0, 0.35, -0.4, -0.9, 0.4, 0.3, -0.1, 0.1, 0.3, 0.1, 0.1, 0.3, 0.1, 0.3, 0.3],
                     'input 3':[0, 0.4, 0, -0.1, 0.4, -0.2, 0.7, -0.3, -0.1, 0.1, 0.3, 0, 0.5, 0.4, -0.31, 0.1, 0.3, 0.1, 0.1, 0.2],
                     'result':[1, 1, 0, 0, 1, 0, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 1, 1, 1, 0]})
  
  print(df)
  
  def sigmoid(x):
      return 1 / (1 + np.exp(-x))
  
  def sigmoid_derivate(x):
      return x * (1 - x)
  
  
  features = df.iloc[:,:-1].to_numpy()
  results =  df.iloc[:,-1:].to_numpy()
  
  np.random.seed(1)
  
  weights = 2 * np.random.random((3,1)) - 1
  
  print('These are my random weights:\n')
  print(weights)
  
  for iteration in range(100000):
  
      input_layer = features
  
      outputs = sigmoid(np.dot(input_layer, weights))
      error = results - outputs
      adjustments = error * sigmoid_derivate(outputs)
      weights += np.dot(input_layer.T, adjustments)
  
  
  df['output prediction'] = outputs.round(0)
  print(df)
  </code></pre>
  
  <p>So, output should be only one value, zero or one.</p>
  
  <p>Thanks for your help</p>