def freeze(self, number=None):
if number is None:<EOL><INDENT>number = self.head_layers<EOL><DEDENT>for idx, child in enumerate(self.model.children()):<EOL><INDENT>if idx < number:<EOL><INDENT>mu.freeze_layer(child)<EOL><DEDENT><DEDENT>
Freeze given number of layers in the model