Skip to content

Commit

Permalink
Added description of the new activation_func arguments to clustered.py.
Browse files Browse the repository at this point in the history
  • Loading branch information
DilyOng committed Feb 27, 2024
1 parent a3931c5 commit f7ea848
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions margarine/clustered.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,11 @@ class clusterMAF():
each neural network. The default is two hidden layers with
50 nodes each and each network in the chain has the same hidden
layer structure.
activation_func: **string / default = 'tanh'**
| The choice of activation function. It must be an activation
function keyword recognisable by TensorFlow. The default is
'tanh', the hyperbolic tangent activation function.
cluster_labels: **list / default = None**
| If clustering has been performed externally to margarine you can
Expand Down Expand Up @@ -77,6 +82,7 @@ def __init__(self, theta, **kwargs):
self.cluster_labels = kwargs.pop('cluster_labels', None)
self.cluster_number = kwargs.pop('cluster_number', None)
self.parameters = kwargs.pop('parameters', None)
self.activation_func = kwargs.pop('activation_func', 'tanh')

# Avoid unintended side effects by copying theta
theta = theta.copy()
Expand Down

0 comments on commit f7ea848

Please sign in to comment.