Browse Source

fix bug of can not change activate after define conv2d

tags/v1.1.0
wangnan39@huawei.com wangnan39 5 years ago
parent
commit
3e123e35a9
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      mindspore/nn/cell.py

+ 2
- 0
mindspore/nn/cell.py View File

@@ -401,6 +401,8 @@ class Cell(Cell_):
if self._auto_prefix:
value.update_parameters_name(name + '.')
cells[name] = value
if hasattr(self, '_cell_init_args'):
self.cell_init_args += str({name: value})
elif params and name in params:
if isinstance(value, Tensor) and self._params[name] is not None:
self._params[name].set_data(value)


Loading…
Cancel
Save