Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
seminar-breakout
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Shashank Suhas
seminar-breakout
Commits
4c59718f
Commit
4c59718f
authored
Jan 05, 2018
by
Yuxin Wu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix initializer mode
parent
a963b01d
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
3 deletions
+3
-3
examples/ResNet/cifar10-resnet.py
examples/ResNet/cifar10-resnet.py
+1
-1
examples/ResNet/resnet_model.py
examples/ResNet/resnet_model.py
+1
-1
examples/Saliency/CAM-resnet.py
examples/Saliency/CAM-resnet.py
+1
-1
No files found.
examples/ResNet/cifar10-resnet.py
View file @
4c59718f
...
...
@@ -74,7 +74,7 @@ class Model(ModelDesc):
with
argscope
([
Conv2D
,
AvgPooling
,
BatchNorm
,
GlobalAvgPooling
],
data_format
=
'NCHW'
),
\
argscope
(
Conv2D
,
nl
=
tf
.
identity
,
use_bias
=
False
,
kernel_shape
=
3
,
W_init
=
tf
.
variance_scaling_initializer
(
scale
=
2.0
,
mode
=
'
FAN_OUT
'
)):
W_init
=
tf
.
variance_scaling_initializer
(
scale
=
2.0
,
mode
=
'
fan_out
'
)):
l
=
Conv2D
(
'conv0'
,
image
,
16
,
nl
=
BNReLU
)
l
=
residual
(
'res1.0'
,
l
,
first
=
True
)
for
k
in
range
(
1
,
self
.
n
):
...
...
examples/ResNet/resnet_model.py
View file @
4c59718f
...
...
@@ -115,7 +115,7 @@ def resnet_group(l, name, block_func, features, count, stride):
def
resnet_backbone
(
image
,
num_blocks
,
group_func
,
block_func
):
with
argscope
(
Conv2D
,
nl
=
tf
.
identity
,
use_bias
=
False
,
W_init
=
tf
.
variance_scaling_initializer
(
scale
=
2.0
,
mode
=
'
FAN_OUT
'
)):
W_init
=
tf
.
variance_scaling_initializer
(
scale
=
2.0
,
mode
=
'
fan_out
'
)):
logits
=
(
LinearWrap
(
image
)
.
Conv2D
(
'conv0'
,
64
,
7
,
stride
=
2
,
nl
=
BNReLU
)
.
MaxPooling
(
'pool0'
,
shape
=
3
,
stride
=
2
,
padding
=
'SAME'
)
...
...
examples/Saliency/CAM-resnet.py
View file @
4c59718f
...
...
@@ -47,7 +47,7 @@ class Model(ModelDesc):
defs
,
block_func
=
cfg
[
DEPTH
]
with
argscope
(
Conv2D
,
nl
=
tf
.
identity
,
use_bias
=
False
,
W_init
=
tf
.
variance_scaling_initializer
(
scale
=
2.0
,
mode
=
'
FAN_OUT
'
)),
\
W_init
=
tf
.
variance_scaling_initializer
(
scale
=
2.0
,
mode
=
'
fan_out
'
)),
\
argscope
([
Conv2D
,
MaxPooling
,
GlobalAvgPooling
,
BatchNorm
],
data_format
=
'NCHW'
):
convmaps
=
(
LinearWrap
(
image
)
.
Conv2D
(
'conv0'
,
64
,
7
,
stride
=
2
,
nl
=
BNReLU
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment