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
OpenDAS
vision
Commits
989d52a0
Commit
989d52a0
authored
Mar 16, 2017
by
Sam Gross
Committed by
Soumith Chintala
Mar 16, 2017
Browse files
Fix location of dropout in VGG (#107)
parent
9ec78dab
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
9 deletions
+9
-9
torchvision/models/__init__.py
torchvision/models/__init__.py
+4
-4
torchvision/models/vgg.py
torchvision/models/vgg.py
+5
-5
No files found.
torchvision/models/__init__.py
View file @
989d52a0
...
...
@@ -37,10 +37,10 @@ ResNet-101 22.63 6.44
ResNet-152 21.69 5.94
Inception v3 22.55 6.44
AlexNet 43.45 20.91
VGG-11 3
2.14
1
2.12
VGG-13 3
1
.0
4
1
1.40
VGG-16 2
9.1
1
10.17
VGG-19 2
8.4
2 9.
69
VGG-11 3
0.98
1
1.37
VGG-13 3
0
.0
7
1
0.75
VGG-16 2
8.4
1
9.62
VGG-19 2
7.6
2 9.
12
SqueezeNet 1.0 41.90 19.58
SqueezeNet 1.1 41.81 19.38
======================== ============= =============
...
...
torchvision/models/vgg.py
View file @
989d52a0
...
...
@@ -10,10 +10,10 @@ __all__ = [
model_urls
=
{
'vgg11'
:
'https://download.pytorch.org/models/vgg11-
fb7e83b2
.pth'
,
'vgg13'
:
'https://download.pytorch.org/models/vgg13-
58758d87
.pth'
,
'vgg16'
:
'https://download.pytorch.org/models/vgg16-
82412952
.pth'
,
'vgg19'
:
'https://download.pytorch.org/models/vgg19-
341d7465
.pth'
,
'vgg11'
:
'https://download.pytorch.org/models/vgg11-
bbd30ac9
.pth'
,
'vgg13'
:
'https://download.pytorch.org/models/vgg13-
c768596a
.pth'
,
'vgg16'
:
'https://download.pytorch.org/models/vgg16-
397923af
.pth'
,
'vgg19'
:
'https://download.pytorch.org/models/vgg19-
dcbb9e9d
.pth'
,
}
...
...
@@ -23,12 +23,12 @@ class VGG(nn.Module):
super
(
VGG
,
self
).
__init__
()
self
.
features
=
features
self
.
classifier
=
nn
.
Sequential
(
nn
.
Dropout
(),
nn
.
Linear
(
512
*
7
*
7
,
4096
),
nn
.
ReLU
(
True
),
nn
.
Dropout
(),
nn
.
Linear
(
4096
,
4096
),
nn
.
ReLU
(
True
),
nn
.
Dropout
(),
nn
.
Linear
(
4096
,
1000
),
)
self
.
_initialize_weights
()
...
...
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