1
0
mirror of https://github.com/gryf/coach.git synced 2025-12-17 11:10:20 +01:00

Printing input size as part of network summary (#310)

This commit is contained in:
Gal Novik
2019-05-12 15:40:02 +03:00
committed by shadiendrawis
parent ffb55b4142
commit aa9f3cefaf

View File

@@ -147,11 +147,11 @@ class InputEmbedder(object):
return self.name
def __str__(self):
result = []
result = ['Input size = {}'.format(self._input_size)]
if self.input_rescaling != 1.0 or self.input_offset != 0.0:
result.append('Input Normalization (scale = {}, offset = {})'.format(self.input_rescaling, self.input_offset))
result.extend([str(l) for l in self.layers_params])
if self.layers_params:
if not self.layers_params:
result.append('No layers')
return '\n'.join(result)
else:
return 'No layers'