Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ModelZoo
ResNet50_tensorflow
Commits
abc62005
Commit
abc62005
authored
Jul 31, 2018
by
Reed
Committed by
Taylor Robie
Jul 31, 2018
Browse files
Fix crash on single-core systems. (#4957)
parent
e6353fe5
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
official/recommendation/data_preprocessing.py
official/recommendation/data_preprocessing.py
+2
-1
No files found.
official/recommendation/data_preprocessing.py
View file @
abc62005
...
@@ -327,7 +327,8 @@ def construct_cache(dataset, data_dir, num_data_readers):
...
@@ -327,7 +327,8 @@ def construct_cache(dataset, data_dir, num_data_readers):
data during training.
data during training.
"""
"""
cache_paths
=
rconst
.
Paths
(
data_dir
=
data_dir
)
cache_paths
=
rconst
.
Paths
(
data_dir
=
data_dir
)
num_data_readers
=
num_data_readers
or
int
(
multiprocessing
.
cpu_count
()
/
2
)
num_data_readers
=
(
num_data_readers
or
int
(
multiprocessing
.
cpu_count
()
/
2
)
or
1
)
approx_num_shards
=
int
(
movielens
.
NUM_RATINGS
[
dataset
]
approx_num_shards
=
int
(
movielens
.
NUM_RATINGS
[
dataset
]
//
rconst
.
APPROX_PTS_PER_TRAIN_SHARD
)
or
1
//
rconst
.
APPROX_PTS_PER_TRAIN_SHARD
)
or
1
...
...
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