Hi,
This boils down to perform a classification task where each task is a possible value of the threshold?
That might work !
As I said above. It’s not that it’s impossible to do, just that there is no one approach and it will be problem dependent. Your approach for example only works if you have a relatively small number of possible values. Also you need to have examples where you know in advance the correct value. This is not the case for network architecture for example.