I've been studying Logistic regression for a few weeks and I have a doubt.
According to what I've been studying, Logistic regression fits a sigmoid function $$ \frac{1}{1+e^{-(wx+b)}}$$ to the data and gives us the probability of an example being $y=1$ based on input features $x$. And then we set a threshold value to classify the examples, usually $0.5$, so if $y=0.6$, then it's classified as $y=1$. But also, the algorithm fits a straight line $wx+b=0$ to separate data that is called "decision boundary".
The relationship between the threshold, the sigmoid and the decision boundary confuses me a lot, especially when I see graphically logistic regression.
I don't understand, where is the sigmoid function?

And in this graph, where is the decision boundary? Sometimes I see that the threshold is called decision boundary, but I don't think that is correct.
