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
wangsen
paddle_dbnet
Commits
d666de85
Commit
d666de85
authored
Feb 07, 2022
by
LDOUBLEV
Browse files
delete debug
parent
28996943
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
9 deletions
+8
-9
test_tipc/benchmark_trainv2.sh
test_tipc/benchmark_trainv2.sh
+7
-8
tools/program.py
tools/program.py
+1
-1
No files found.
test_tipc/benchmark_trainv2.sh
View file @
d666de85
...
@@ -117,7 +117,7 @@ if [ ${precision} = "null" ];then
...
@@ -117,7 +117,7 @@ if [ ${precision} = "null" ];then
fi
fi
# set env
# set env
python
=
python
3.7
python
=
python
export
model_branch
=
`
git symbolic-ref HEAD 2>/dev/null |
cut
-d
"/"
-f
3
`
export
model_branch
=
`
git symbolic-ref HEAD 2>/dev/null |
cut
-d
"/"
-f
3
`
export
model_commit
=
$(
git log|head
-n1
|awk
'{print $2}'
)
export
model_commit
=
$(
git log|head
-n1
|awk
'{print $2}'
)
export
str_tmp
=
$(
echo
`
pip list|grep paddlepaddle-gpu|awk
-F
' '
'{print $2}'
`
)
export
str_tmp
=
$(
echo
`
pip list|grep paddlepaddle-gpu|awk
-F
' '
'{print $2}'
`
)
...
@@ -129,6 +129,7 @@ export frame_commit=$(echo `${python} -c "import paddle;print(paddle.version.com
...
@@ -129,6 +129,7 @@ export frame_commit=$(echo `${python} -c "import paddle;print(paddle.version.com
# line export_py: 30
# line export_py: 30
func_sed_params
"
$FILENAME
"
"24"
"null"
func_sed_params
"
$FILENAME
"
"24"
"null"
func_sed_params
"
$FILENAME
"
"30"
"null"
func_sed_params
"
$FILENAME
"
"30"
"null"
func_sed_params
"
$FILENAME
"
"3"
"python"
if
[
${#
gpu_id
}
-le
1
]
;
then
if
[
${#
gpu_id
}
-le
1
]
;
then
...
@@ -165,15 +166,14 @@ if [ ${#gpu_id} -le 1 ];then
...
@@ -165,15 +166,14 @@ if [ ${#gpu_id} -le 1 ];then
# parser log
# parser log
_model_name
=
"
${
model_name
}
_bs
${
batch_size
}
_
${
precision
}
_
${
run_process_type
}
_
${
run_mode
}
"
_model_name
=
"
${
model_name
}
_bs
${
batch_size
}
_
${
precision
}
_
${
run_process_type
}
_
${
run_mode
}
"
# cmd="${python} ${BENCHMARK_ROOT}/scripts/analysis.py --filename ${log_path}/${log_name} \
cmd
=
"
${
python
}
${
BENCHMARK_ROOT
}
/scripts/analysis.py --filename
${
log_path
}
/
${
log_name
}
\
cmd
=
"
${
python
}
analysis.py --filename
${
log_path
}
/
${
log_name
}
\
--speed_log_file '
${
speed_log_path
}
/
${
speed_log_name
}
'
\
--speed_log_file '
${
speed_log_path
}
/
${
speed_log_name
}
'
\
--model_name
${
_model_name
}
\
--model_name
${
_model_name
}
\
--base_batch_size
${
batch_size
}
\
--base_batch_size
${
batch_size
}
\
--run_mode
${
run_mode
}
\
--run_mode
${
run_mode
}
\
--run_process_type
${
run_process_type
}
\
--run_process_type
${
run_process_type
}
\
--fp_item
${
precision
}
\
--fp_item
${
precision
}
\
--keyword
ip
s:
\
--keyword
samples/
s:
\
--skip_steps 2
\
--skip_steps 2
\
--device_num
${
device_num
}
\
--device_num
${
device_num
}
\
--speed_unit images/s
\
--speed_unit images/s
\
...
@@ -203,15 +203,14 @@ else
...
@@ -203,15 +203,14 @@ else
# parser log
# parser log
_model_name
=
"
${
model_name
}
_bs
${
batch_size
}
_
${
precision
}
_
${
run_process_type
}
_
${
run_mode
}
"
_model_name
=
"
${
model_name
}
_bs
${
batch_size
}
_
${
precision
}
_
${
run_process_type
}
_
${
run_mode
}
"
# cmd="python3.7 ${BENCHMARK_ROOT}/scripts/analysis.py --filename ${log_path}/${log_name} \
cmd
=
"
${
python
}
${
BENCHMARK_ROOT
}
/scripts/analysis.py --filename
${
log_path
}
/
${
log_name
}
\
cmd
=
"
${
python
}
analysis.py --filename
${
log_path
}
/
${
log_name
}
\
--speed_log_file '
${
speed_log_path
}
/
${
speed_log_name
}
'
\
--speed_log_file '
${
speed_log_path
}
/
${
speed_log_name
}
'
\
--model_name
${
_model_name
}
\
--model_name
${
_model_name
}
\
--base_batch_size
${
batch_size
}
\
--base_batch_size
${
batch_size
}
\
--run_mode
${
run_mode
}
\
--run_mode
${
run_mode
}
\
--run_process_type
${
run_process_type
}
\
--run_process_type
${
run_process_type
}
\
--fp_item
${
precision
}
\
--fp_item
${
precision
}
\
--keyword
ip
s:
\
--keyword
samples/
s:
\
--skip_steps 2
\
--skip_steps 2
\
--device_num
${
device_num
}
\
--device_num
${
device_num
}
\
--speed_unit images/s
\
--speed_unit images/s
\
...
...
tools/program.py
View file @
d666de85
...
@@ -273,7 +273,7 @@ def train(config,
...
@@ -273,7 +273,7 @@ def train(config,
(
global_step
>
0
and
global_step
%
print_batch_step
==
0
)
or
(
global_step
>
0
and
global_step
%
print_batch_step
==
0
)
or
(
idx
>=
len
(
train_dataloader
)
-
1
)):
(
idx
>=
len
(
train_dataloader
)
-
1
)):
logs
=
train_stats
.
log
()
logs
=
train_stats
.
log
()
strs
=
'epoch: [{}/{}], global_step: {}, {}, avg_reader_cost: {:.5f} s, avg_batch_cost: {:.5f} s, avg_samples: {},
ip
s: {:.5f}'
.
format
(
strs
=
'epoch: [{}/{}], global_step: {}, {}, avg_reader_cost: {:.5f} s, avg_batch_cost: {:.5f} s, avg_samples: {},
samples/
s: {:.5f}'
.
format
(
epoch
,
epoch_num
,
global_step
,
logs
,
train_reader_cost
/
epoch
,
epoch_num
,
global_step
,
logs
,
train_reader_cost
/
print_batch_step
,
(
train_reader_cost
+
train_run_cost
)
/
print_batch_step
,
(
train_reader_cost
+
train_run_cost
)
/
print_batch_step
,
total_samples
/
print_batch_step
,
print_batch_step
,
total_samples
/
print_batch_step
,
...
...
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