kotlindl
kotlindl copied to clipboard
Add basic Constraints support
Add basic constraints to the following list of layers:
- [ ] Dense
- [ ] Conv2d
- [ ] Conv1d
- [ ] (optional) SeparableConv2D
- [ ] (optional) DepthwiseConv2D
The following constraints should be implemented:
- [ ] MaxNorm
- [ ] MinMaxNorm
- [ ] NonNeg
- [ ] UnitNorm
Please take into account my refactor of conv layers which is going to be done here. I created AbstractConv so I suppose it would be easier to introduce these constrains after merge of this change if possible (case looks similar to regularizers as i think about it)
@avan1235 looks like the constraint will be postponed because I have no idea how to apply them to the variables. It should become a part of the weight update in the optimizer, but I could not pass it to the optimizer and minimize function to apply on each step. The weight update mechanism is hidden from our control in the optimizer functions provided via TF Java API