Advertisement
Guest User

Untitled

a guest
Jan 19th, 2017
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. //The function that i am trying to minimize, inputArr is constant while it is the weights that i want to optimize
  2. FunctionToMinimize(weights, inputArr)
  3. totalCost = 0
  4.  
  5. for input in inputArr
  6. //For each input (which is a vector) i let it propogate through an ANN which gives me an ouput (also vector)
  7. output = PropegateThroughANN(weights, input)
  8.  
  9. //The total cost is calculated using the output. However this is blackboxed and i can not get, for example, the derivative
  10. totalCost += CostCalculatingFunction(output)
  11.  
  12. return totalCost
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement