comparison deep/stacked_dae/stacked_dae.py @ 191:3632e6258642

Ajouts mineurs à stacked_dae, juste printé l'heure je crois.
author fsavard
date Tue, 02 Mar 2010 14:47:18 -0500
parents d364a130b221
children e656edaedb48
comparison
equal deleted inserted replaced
190:70a9df1cd20e 191:3632e6258642
136 self.cost = T.mean(self.L) 136 self.cost = T.mean(self.L)
137 137
138 self.params = [ self.W, self.b, self.b_prime ] 138 self.params = [ self.W, self.b, self.b_prime ]
139 139
140 140
141
142
143 class SdA(object): 141 class SdA(object):
144 def __init__(self, train_set_x, train_set_y, batch_size, n_ins, 142 def __init__(self, train_set_x, train_set_y, batch_size, n_ins,
145 hidden_layers_sizes, n_outs, 143 hidden_layers_sizes, n_outs,
146 corruption_levels, rng, pretrain_lr, finetune_lr, input_divider=1.0): 144 corruption_levels, rng, pretrain_lr, finetune_lr, input_divider=1.0):
147 # Just to make sure those are not modified somewhere else afterwards 145 # Just to make sure those are not modified somewhere else afterwards
148 hidden_layers_sizes = copy.deepcopy(hidden_layers_sizes) 146 hidden_layers_sizes = copy.deepcopy(hidden_layers_sizes)
149 corruption_levels = copy.deepcopy(corruption_levels) 147 corruption_levels = copy.deepcopy(corruption_levels)
148
150 update_locals(self, locals()) 149 update_locals(self, locals())
151 150
152 self.layers = [] 151 self.layers = []
153 self.pretrain_functions = [] 152 self.pretrain_functions = []
154 self.params = [] 153 self.params = []