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
d38d22bf
Commit
d38d22bf
authored
Oct 28, 2017
by
Yuxin Wu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
keep the '-summary' suffix
parent
b0297e64
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
12 additions
and
4 deletions
+12
-4
.github/ISSUE_TEMPLATE.md
.github/ISSUE_TEMPLATE.md
+5
-0
tensorpack/callbacks/monitor.py
tensorpack/callbacks/monitor.py
+2
-1
tensorpack/models/regularize.py
tensorpack/models/regularize.py
+1
-0
tensorpack/tfutils/summary.py
tensorpack/tfutils/summary.py
+3
-3
tox.ini
tox.ini
+1
-0
No files found.
.github/ISSUE_TEMPLATE.md
View file @
d38d22bf
...
...
@@ -2,6 +2,11 @@ Bug Reports/Feature Requests/Usage Questions Only:
Bug Reports:
Some part of code (either the library or examples) doesn't work as expected.
Always include the following:
1.
What you did. (command you run if using examples; post or describe your code if not)
2.
What you observed. (training logs)
3.
What you expected, if not obvious
4.
Your environment (TF version, GPUs), if it matters.
Feature Requests:
1.
Improve an existing feature.
...
...
tensorpack/callbacks/monitor.py
View file @
d38d22bf
...
...
@@ -130,7 +130,8 @@ class Monitors(Callback):
if
val
.
WhichOneof
(
'value'
)
==
'simple_value'
:
val
.
tag
=
re
.
sub
(
'tower[0-9]+/'
,
''
,
val
.
tag
)
# TODO move to subclasses
# TODO This hack not needed any more, can remove this in the future
# TODO This hack is still needed, seem to disappear only when
# compiled from source.
suffix
=
'-summary'
# tensorflow#6150, tensorboard#59
if
val
.
tag
.
endswith
(
suffix
):
val
.
tag
=
val
.
tag
[:
-
len
(
suffix
)]
...
...
tensorpack/models/regularize.py
View file @
d38d22bf
...
...
@@ -41,6 +41,7 @@ def regularize_cost(regex, func, name='regularize_cost'):
cost = cost + regularize_cost("fc.*/W", l2_regularizer(1e-5))
"""
assert
len
(
regex
)
ctx
=
get_current_tower_context
()
if
not
ctx
.
is_training
:
# Currently cannot build the wd_cost correctly at inference,
...
...
tensorpack/tfutils/summary.py
View file @
d38d22bf
...
...
@@ -119,8 +119,8 @@ def add_tensor_summary(x, types, name=None, collections=None,
return
SUMMARY_TYPES_DIC
=
{
'scalar'
:
lambda
:
tf
.
summary
.
scalar
(
name
,
x
,
collections
=
collections
),
'histogram'
:
lambda
:
tf
.
summary
.
histogram
(
name
,
x
,
collections
=
collections
),
'scalar'
:
lambda
:
tf
.
summary
.
scalar
(
name
+
'-summary'
,
x
,
collections
=
collections
),
'histogram'
:
lambda
:
tf
.
summary
.
histogram
(
name
+
'-histogram'
,
x
,
collections
=
collections
),
'sparsity'
:
lambda
:
tf
.
summary
.
scalar
(
name
+
'-sparsity'
,
tf
.
nn
.
zero_fraction
(
x
),
collections
=
collections
),
...
...
@@ -246,7 +246,7 @@ def add_moving_summary(*args, **kwargs):
ema_ops
.
append
(
ema_op
)
with
tf
.
name_scope
(
None
):
# cannot add it into colocate group -- will force everything to cpus
tf
.
summary
.
scalar
(
name
,
ema_op
)
# write the EMA value as a summary
tf
.
summary
.
scalar
(
name
+
'-summary'
,
ema_op
)
# write the EMA value as a summary
if
coll
is
not
None
:
for
op
in
ema_ops
:
# TODO a new collection to summary every step?
...
...
tox.ini
View file @
d38d22bf
...
...
@@ -7,5 +7,6 @@ exclude = .git,
snippet,
docs,
examples,
examples-old,
_test.py,
docs/conf.py
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