add append and module list

This commit is contained in:
Dun Liang 2020-05-17 22:35:23 +08:00
parent f4fe1ccf75
commit 0053692a00
1 changed files with 4 additions and 0 deletions

View File

@ -603,3 +603,7 @@ class Sequential(Module):
parents.pop()
if callback_leave:
callback_leave(parents, k, self, n_children)
def append(mod):
self.layers.append(mod)
ModuleList = Sequential