提交 20a4e2d4 编写于 作者: L LielinJiang

add init module

上级 7b1e2849
......@@ -25,7 +25,7 @@ dataset:
train:
name: PairedDataset
dataroot: data/cityscapes
num_workers: 0
num_workers: 4
phase: train
max_dataset_size: inf
direction: BtoA
......
......@@ -298,15 +298,3 @@ def init_weights(net, init_type='normal', init_gain=0.02):
print('initialize network with %s' % init_type)
net.apply(init_func) # apply the initialization function <init_func>
# if __name__ == "__main__":
# paddle.disable_static()
# conv1 = paddle.nn.Conv2d(3, 8, 1)
# print('bias before', conv1.bias)
# constant_init(conv1, -1., -1.)
# print('bias before', conv1.bias)
# kaiming_init(conv1)
# print('bias after kaiming', conv1.bias)
# xavier_init(conv1)
# print('bias after xavier', conv1.bias)
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册