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
85722689
Commit
85722689
authored
Jun 21, 2016
by
Luke LaFountaine
Browse files
remove unneeded assignment
parent
03790394
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
1 deletion
+0
-1
swivel/prep.py
swivel/prep.py
+0
-1
No files found.
swivel/prep.py
View file @
85722689
...
@@ -111,7 +111,6 @@ def create_vocabulary(lines):
...
@@ -111,7 +111,6 @@ def create_vocabulary(lines):
vocab
=
[(
tok
,
n
)
for
tok
,
n
in
vocab
.
iteritems
()
if
n
>=
FLAGS
.
min_count
]
vocab
=
[(
tok
,
n
)
for
tok
,
n
in
vocab
.
iteritems
()
if
n
>=
FLAGS
.
min_count
]
vocab
.
sort
(
key
=
lambda
kv
:
(
-
kv
[
1
],
kv
[
0
]))
vocab
.
sort
(
key
=
lambda
kv
:
(
-
kv
[
1
],
kv
[
0
]))
num_words
=
max
(
len
(
vocab
),
FLAGS
.
shard_size
)
num_words
=
min
(
len
(
vocab
),
FLAGS
.
max_vocab
)
num_words
=
min
(
len
(
vocab
),
FLAGS
.
max_vocab
)
if
num_words
%
FLAGS
.
shard_size
!=
0
:
if
num_words
%
FLAGS
.
shard_size
!=
0
:
num_words
-=
num_words
%
FLAGS
.
shard_size
num_words
-=
num_words
%
FLAGS
.
shard_size
...
...
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