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
e1bb7c2f
Commit
e1bb7c2f
authored
Feb 01, 2017
by
Yuxin Wu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix BN on FC layer
parent
3e0a861e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
tensorpack/models/batch_norm.py
tensorpack/models/batch_norm.py
+3
-0
No files found.
tensorpack/models/batch_norm.py
View file @
e1bb7c2f
...
@@ -181,6 +181,9 @@ def BatchNorm(x, use_local_stat=None, decay=0.9, epsilon=1e-5):
...
@@ -181,6 +181,9 @@ def BatchNorm(x, use_local_stat=None, decay=0.9, epsilon=1e-5):
xn
=
tf
.
nn
.
batch_normalization
(
xn
=
tf
.
nn
.
batch_normalization
(
x
,
moving_mean
,
moving_var
,
beta
,
gamma
,
epsilon
)
x
,
moving_mean
,
moving_var
,
beta
,
gamma
,
epsilon
)
if
len
(
shape
)
==
2
:
xn
=
tf
.
squeeze
(
xn
,
[
1
,
2
])
# TODO for other towers, maybe can make it depend some op later
# TODO for other towers, maybe can make it depend some op later
# TODO update it later (similar to slim) might be faster?
# TODO update it later (similar to slim) might be faster?
if
ctx
.
is_main_training_tower
:
if
ctx
.
is_main_training_tower
:
...
...
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