Madara
Madara

Reputation: 368

Is there any way to ensure that your CNN model predicts outputs following certain thresholds?

I have a network which takes in an input image and outputs 37 values that are essentially the features. For e.g. the entire output class is a series of questions whose values are the percentage of people who agreed upon the said feature. 0.60 for class1 and 0.4 for class12.

Now, there are some conditions such that the output of the model can't have one class that is higher than the other. E.g. class1.1 must be higher than class3.2 as it is a higher question in the decision tree. Is there any way we can implement this?

Upvotes: 0

Views: 30

Answers (1)

orlp
orlp

Reputation: 117701

Instead of directly outputting a, b from your neural network you can output a, a + ReLU(b) which ensures the second output is higher than or equal to the first.

Upvotes: 1

Related Questions