#NEWLINE# def current_learning_rate( schedule , idx ) : #NEWLINE# #INDENT# s = schedule . keys ( ) #NEWLINE# s . sort ( ) #NEWLINE# current_lr = schedule [ 0 ] #NEWLINE# for i in schedule : #NEWLINE# #INDENT# if ( idx >= i ) : #NEWLINE# #INDENT# current_lr = schedule [ i ] #NEWLINE# #UNINDENT# #UNINDENT# return current_lr