SciSharp / TensorFlow.NET

.NET Standard bindings for Google's TensorFlow for developing, training and deploying Machine Learning models in C# and F#.
https://scisharp.github.io/tensorflow-net-docs
Apache License 2.0
3.2k stars 514 forks source link

Let the Dense layer support regularization #1094

Closed Beacontownfc closed 1 year ago

Beacontownfc commented 1 year ago

Update the Dense Layer in Tensorflow.Keras.Layers You can use your code like this: var l1 = new L1(); x = layers.Dense(256, kernel_regularizer: l1, bias_regularizer: l1, activation: "relu");