keras-adabound icon indicating copy to clipboard operation
keras-adabound copied to clipboard

Can't set attribute

Open mminakshi opened this issue 5 years ago • 5 comments

File "/adabound.py", line 40, in init self.lr = K.variable(lr, name='lr') AttributeError: can't set attribute

mminakshi avatar Feb 03 '20 22:02 mminakshi

Change lr to learning_rate in adabound.py file to make it compatible with the latest version of Keras >= 2.3.0.

guptakhil avatar Mar 25 '20 04:03 guptakhil

I didn't work for me, can you be more specific, please.

reydenX avatar Jun 10 '20 14:06 reydenX

Same problem here, under Keras 2.3.1.

I simply changed l.40 to : self.lr = K.variable(learning_rate, name='lr') but that does not solve the issue. Do you know what could? Thanks !

nicolastonon avatar Jul 07 '20 12:07 nicolastonon

@nicolastonon:

You'll have to change L40 to self.learning_rate = K.variable(learning_rate, name='learning_rate'). Subsequently, self.lr to self.learning_rate everywhere.

Hope that helps.

guptakhil avatar Jul 13 '20 20:07 guptakhil

Use an earlier version of Keras to solve this problem

wuyun-long avatar Aug 01 '21 10:08 wuyun-long