1
$\begingroup$

enter image description here

For example, this image shows the output of a neural network I assume but I am not sure how the output is not symmetric. So if the neural network gives a .6 for signal it should give a .4 for background. enter image description here

This is my neural network output that is symmetric. However, I have not seen anyone else get a symmetric output like this. Does this mean that I'm doing something wrong or does it mean that the first graph is not the output of the neural network.

$\endgroup$
4
  • $\begingroup$ Could you elaborate a bit on what type of network you are training and how you define signal and background? Are those different types of input data? $\endgroup$
    – matthiaw91
    Oct 5 '19 at 9:38
  • $\begingroup$ @matthiaw91 Yes, I am training a DNN. The signal and background events are a set of 11 variables so the DNN has 11 inputs, each is a physical parameter like ‘bbmass’ (things like masses, momenta, and angles). The data was generated with 2 different monte Carlos, one generates 11 signal variables and the other generates 11 background variables, I just label background events as 0 and signals as 1 then use the to_categorical feature in keras to change them to one-hot vectors. I guess one of the things I’m wondering is how could you not get a symmetric output like the first graph. $\endgroup$
    – bigb123
    Oct 5 '19 at 18:19
  • $\begingroup$ Okay, one more question, then I might have an answer. So you have a two classes 0 and 1, which you convert to one-hot, so [0, 1] and [1,0], right? And the output of your network is a two-dimensional softmax, or two-dimensional sigmoid, or something else? $\endgroup$
    – matthiaw91
    Oct 5 '19 at 19:28
  • $\begingroup$ @matthiaw91 Yes that is what the labels look like. I use softmax activation. But before that I didn’t use one-hots I just had 0 and 1 labels and I used sparse-categorical-crossentropy loss but now I used categorical-crossentropy with one-hots. Both methods gave the same symmetric output. $\endgroup$
    – bigb123
    Oct 5 '19 at 23:41
0
$\begingroup$

Okay, your output makes sense, given what you wrote in the comments. But if you don't know where the other output comes from, all else is speculation. It could be that it was generated by a neural network with two sigmoid outputs, rather then softmax, and the classification was done based on which output was larger. In that case you are not guaranteed symmetric graphs. So the asymmetric graph does not necessarily imply that it's not generated by a neural network, only that the output does not come from a two-dimensional softmax or a pair of sigmoid/1-sigmoid.

$\endgroup$
4
  • $\begingroup$ Do you know if keras has a way to do 2 sigmoid outputs or would I have to use a different api? $\endgroup$
    – bigb123
    Oct 6 '19 at 15:25
  • $\begingroup$ The last layer would be two neurons with sigmoid-activation, so you'd do something like 'model.add(Dense(2, activation="sigmoid"))' $\endgroup$
    – matthiaw91
    Oct 6 '19 at 19:03
  • $\begingroup$ Oh, I see, thanks for your help I upvoted your answer but it doesn’t do anything because my reputation is too low. $\endgroup$
    – bigb123
    Oct 6 '19 at 19:09
  • $\begingroup$ Thanks and good luck! $\endgroup$
    – matthiaw91
    Oct 6 '19 at 23:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.