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
Swin-Transformer_pytorch
Commits
60aeae99
Commit
60aeae99
authored
Nov 07, 2024
by
dcuai
Browse files
Update main.py ——add epochs and local-rank
parent
f761d05b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
main.py
main.py
+3
-1
No files found.
main.py
View file @
60aeae99
...
...
@@ -42,6 +42,8 @@ def parse_option():
# easy config modification
parser
.
add_argument
(
'--batch-size'
,
type
=
int
,
help
=
"batch size for single GPU"
)
parser
.
add_argument
(
'--train-epochs'
,
type
=
int
,
help
=
'epochs'
,
default
=
300
)
parser
.
add_argument
(
'--warmup-epochs'
,
type
=
int
,
help
=
'warmup-epochs'
,
default
=
20
)
parser
.
add_argument
(
'--data-path'
,
type
=
str
,
help
=
'path to dataset'
)
parser
.
add_argument
(
'--zip'
,
action
=
'store_true'
,
help
=
'use zipped dataset instead of folder dataset'
)
parser
.
add_argument
(
'--cache-mode'
,
type
=
str
,
default
=
'part'
,
choices
=
[
'no'
,
'full'
,
'part'
],
...
...
@@ -64,7 +66,7 @@ def parse_option():
parser
.
add_argument
(
'--throughput'
,
action
=
'store_true'
,
help
=
'Test throughput only'
)
# distributed training
parser
.
add_argument
(
"--local
_
rank"
,
type
=
int
,
required
=
True
,
help
=
'local rank for DistributedDataParallel'
)
parser
.
add_argument
(
"--local
-
rank"
,
type
=
int
,
required
=
True
,
help
=
'local rank for DistributedDataParallel'
)
# for acceleration
parser
.
add_argument
(
'--fused_window_process'
,
action
=
'store_true'
,
...
...
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