def createEncoder():
 consumption_encoder = ScalarEncoder(21, 0.0, 100.0, n=50, name='consumption', clipInput=True)
 time_encoder = DateEncoder(timeOfDay=(21, 9.5), name='timestamp_timeOfDay')
 encoder = MultiEncoder()
 encoder.addEncoder('consumption', consumption_encoder)
 encoder.addEncoder('timestamp', time_encoder)
 return encoder

def createEncoder ( ) : consumption_encoder = ScalarEncoder ( 21 , 0.0 , 100.0 , n = 50 , name = 'consumption' , clipInput = True ) time_encoder = DateEncoder ( timeOfDay = ( 21 , 9.5 ) , name = 'timestamp_timeOfDay' ) encoder = MultiEncoder ( ) encoder . addEncoder ( 'consumption' , consumption_encoder ) encoder . addEncoder ( 'timestamp' , time_encoder ) return encoder
creates and returns a #multiencoder including a scalarencoder for energy consumption and a dateencoder for the time of the day .