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
95cdb963
Commit
95cdb963
authored
Sep 21, 2018
by
Yuxin Wu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use ImageNetModel for CAM; fix memory fraction
parent
7538cc66
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
2 deletions
+6
-2
examples/ImageNetModels/shufflenet.py
examples/ImageNetModels/shufflenet.py
+1
-0
tensorpack/tfutils/common.py
tensorpack/tfutils/common.py
+5
-2
No files found.
examples/ImageNetModels/shufflenet.py
View file @
95cdb963
...
...
@@ -205,6 +205,7 @@ def get_config(model, nr_tower):
ScheduledHyperParamSetter
(
'learning_rate'
,
[(
0
,
0.5
),
(
max_iter
,
0
)],
interp
=
'linear'
,
step_based
=
True
),
EstimatedTimeLeft
()
]
infs
=
[
ClassificationError
(
'wrong-top1'
,
'val-error-top1'
),
ClassificationError
(
'wrong-top5'
,
'val-error-top5'
)]
...
...
tensorpack/tfutils/common.py
View file @
95cdb963
...
...
@@ -22,7 +22,10 @@ def get_default_sess_config(mem_fraction=0.99):
You can modify the returned config to fit your needs.
Args:
mem_fraction(float): fraction of memory to use.
mem_fraction(float): see the `per_process_gpu_memory_fraction` option
in TensorFlow's GPUOptions protobuf:
https://github.com/tensorflow/tensorflow/blob/master/tensorflow/core/protobuf/config.proto
Returns:
tf.ConfigProto: the config to use.
"""
...
...
@@ -36,7 +39,7 @@ def get_default_sess_config(mem_fraction=0.99):
# TF benchmark use cpu_count() - gpu_thread_count(), e.g. 80 - 8 * 2
# Didn't see much difference.
conf
.
gpu_options
.
per_process_gpu_memory_fraction
=
0.99
conf
.
gpu_options
.
per_process_gpu_memory_fraction
=
mem_fraction
# This hurt performance of large data pipeline:
# https://github.com/tensorflow/benchmarks/commit/1528c46499cdcff669b5d7c006b7b971884ad0e6
...
...
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