Answers.Body: <p>You make a valid point, vanilla neural networks cannot give you more than a point estimate of class confidence. If one wanted to actually gain an idea of variance, you need a framework that allows such a mechanism.   </p>
  
  <p>A popular methodology to this is Bayesian modeling. In other words given some data, <span class="math-container">$\Omega$</span>, you want to create some form of descriminative model <span class="math-container">$p(y|x;\theta)$</span> where <span class="math-container">$\theta$</span> denotes the parameters that are random variables. This is unline NN's where they also learn some descriminative model <span class="math-container">$p(y|x;\theta)$</span> where <span class="math-container">$\theta$</span> are fixed. This difference is key to your goal, because if <span class="math-container">$\theta$</span> is fixed, <span class="math-container">$Var(Y|X) = 0$</span> since any time you put in the same <span class="math-container">$X$</span> into the network, itll always come out the same. On the other hand a bayesian model will have a variance, <span class="math-container">$Var(Y|X) = E[(Y - E[Y|X])^2 | X]$</span> and <span class="math-container">$(Y - E[Y|X])^2 | X$</span>  is no longer gauranteed to be 0 and can be empirically measured through some MC method (or analytically based on your model).  </p>
  
  <p>Note that your idea is on the right track, that the more data points you have, the more confident your estimates will be, but the only issue is that just considering <span class="math-container">$\frac{P}{(P+N)}$</span> in a neural network will be just a heuristic and is difficult to quantify its association to the variance.  </p>
  
  <p>I think this may fit your fancy: <a href="https://medium.com/neuralspace/bayesian-neural-network-series-post-1-need-for-bayesian-networks-e209e66b70b2" rel="nofollow noreferrer">high level overview of bayesian network blog post</a>. This is a high level overview of using a neural netowrk paradigm but including uncertainty in the weights. Theres tons of tricks out there to make it so you can still even train these with gradient descent and such.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-07-10T16:38:38.030Z
Answers.LastActivityDate: 2019-07-10T16:38:38.030Z
Answers.UserDisplayName: mshlis
Body: <p>If I see a hundred elephants and fifty of them are grey I'd say the probability of an elephant being grey is 50%. And my certainty of that probability is high.</p>
  
  <p>However, if I see two elephants and one of them is grey. Still the probability is 50%. But my certaintity of this is low.</p>
  
  <p>Are there any AI models where not only the probability is given by the AI but it's certainty is also?</p>
  
  <p>"Certainty" might be thought of as the probability that the probability is correct.</p>
  
  <p>This could go up more levels. </p>
  
  <p>Is there any advantage in doing this?</p>
  
  <p>One way I can envisage this working is instead of a weight, the NN stores two integers <span class="math-container">$(P,N)$</span> which represent positive and negative evidence and the weight is given by <span class="math-container">$P/(P+N)$</span>. And each iteration <span class="math-container">$P$</span> or <span class="math-container">$N$</span> can only be incremented by 1. </p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-08-18T06:11:10.717Z
Comments.Text: I think you might need to explain this : *"Certainty" might be thought of as the probability that the probability is correct.* a bit more. This is just not helping the question.
Comments.UserDisplayName: naive
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-08-18T06:12:57.137Z
Comments.Text: I think you might be looking for [confidence intervals](https://en.wikipedia.org/wiki/Confidence_interval)
Comments.UserDisplayName: naive
Tags: <neural-networks><probability>
Title: Is there an AI model with "certainty" built in?
UserDisplayName: zooby
ThreadText: # Is there an AI model with "certainty" built in?
  
  (Asked by: username_0 on 2019-07-10)
  
  If I see a hundred elephants and fifty of them are grey I'd say the probability of an elephant being grey is 50%. And my certainty of that probability is high.
  
  However, if I see two elephants and one of them is grey. Still the probability is 50%. But my certaintity of this is low.
  
  Are there any AI models where not only the probability is given by the AI but it's certainty is also?
  
  "Certainty" might be thought of as the probability that the probability is correct.
  
  This could go up more levels.
  
  Is there any advantage in doing this?
  
  One way I can envisage this working is instead of a weight, the NN stores two integers $(P,N)$ which represent positive and negative evidence and the weight is given by $P/(P+N)$. And each iteration $P$ or $N$ can only be incremented by 1.
  
  **Tags:** neural-networks, probability
  > **Comments:**
  > **username_1**: I think you might need to explain this : *"Certainty" might be thought of as the probability that the probability is correct.* a bit more. This is just not helping the question.  
  > **username_1**: I think you might be looking for [confidence intervals](https://en.wikipedia.org/wiki/Confidence_interval)  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_2 on 2019-07-10. Score: 1
  
  You make a valid point, vanilla neural networks cannot give you more than a point estimate of class confidence. If one wanted to actually gain an idea of variance, you need a framework that allows such a mechanism.
  
  A popular methodology to this is Bayesian modeling. In other words given some data, $\Omega$, you want to create some form of descriminative model $p(y|x;\theta)$ where $\theta$ denotes the parameters that are random variables. This is unline NN's where they also learn some descriminative model $p(y|x;\theta)$ where $\theta$ are fixed. This difference is key to your goal, because if $\theta$ is fixed, $Var(Y|X) = 0$ since any time you put in the same $X$ into the network, itll always come out the same. On the other hand a bayesian model will have a variance, $Var(Y|X) = E[(Y - E[Y|X])^2 | X]$ and $(Y - E[Y|X])^2 | X$ is no longer gauranteed to be 0 and can be empirically measured through some MC method (or analytically based on your model).
  
  Note that your idea is on the right track, that the more data points you have, the more confident your estimates will be, but the only issue is that just considering $\frac{P}{(P+N)}$ in a neural network will be just a heuristic and is difficult to quantify its association to the variance.
  
  I think this may fit your fancy: [high level overview of bayesian network blog post](https://medium.com/neuralspace/bayesian-neural-network-series-post-1-need-for-bayesian-networks-e209e66b70b2). This is a high level overview of using a neural netowrk paradigm but including uncertainty in the weights. Theres tons of tricks out there to make it so you can still even train these with gradient descent and such.
  
  
  ---
  
  