未验证 提交 ab44bf5a 编写于 作者: R ruri 提交者: GitHub

fix bugs in run script and utility.py (#2756) (#2757)

上级 5c751d8f
...@@ -20,7 +20,6 @@ python train.py \ ...@@ -20,7 +20,6 @@ python train.py \
# --batch_size=256 \ # --batch_size=256 \
# --total_images=1281167 \ # --total_images=1281167 \
# --image_shape=3,224,224 \ # --image_shape=3,224,224 \
# --input_dtype=float32 \
# --class_dim=1000 \ # --class_dim=1000 \
# --lr_strategy=cosine_decay \ # --lr_strategy=cosine_decay \
# --lr=0.1 \ # --lr=0.1 \
...@@ -38,7 +37,6 @@ python train.py \ ...@@ -38,7 +37,6 @@ python train.py \
# --batch_size=256 \ # --batch_size=256 \
# --total_images=1281167 \ # --total_images=1281167 \
# --image_shape=3,224,224 \ # --image_shape=3,224,224 \
# --input_dtype=float32 \
# --class_dim=1000 \ # --class_dim=1000 \
# --lr_strategy=piecewise_decay \ # --lr_strategy=piecewise_decay \
# --lr=0.1 \ # --lr=0.1 \
...@@ -53,7 +51,6 @@ python train.py \ ...@@ -53,7 +51,6 @@ python train.py \
# --batch_size=256 \ # --batch_size=256 \
# --total_images=1281167 \ # --total_images=1281167 \
# --image_shape=3,224,224 \ # --image_shape=3,224,224 \
# --input_dtype=float32 \
# --class_dim=1000 \ # --class_dim=1000 \
# --lr_strategy=cosine_decay \ # --lr_strategy=cosine_decay \
# --lr=0.1 \ # --lr=0.1 \
...@@ -71,7 +68,6 @@ python train.py \ ...@@ -71,7 +68,6 @@ python train.py \
# --batch_size=256 \ # --batch_size=256 \
# --total_images=1281167 \ # --total_images=1281167 \
# --image_shape=3,299,299 \ # --image_shape=3,299,299 \
# --input_dtype=float32 \
# --class_dim=1000 \ # --class_dim=1000 \
# --lr_strategy=cosine_decay \ # --lr_strategy=cosine_decay \
# --lr=0.045 \ # --lr=0.045 \
...@@ -89,7 +85,6 @@ python train.py \ ...@@ -89,7 +85,6 @@ python train.py \
# --batch_size=256 \ # --batch_size=256 \
# --total_images=1281167 \ # --total_images=1281167 \
# --image_shape=3,224,224 \ # --image_shape=3,224,224 \
# --input_dtype=float32 \
# --class_dim=1000 \ # --class_dim=1000 \
# --lr_strategy=cosine_decay \ # --lr_strategy=cosine_decay \
# --lr=0.1 \ # --lr=0.1 \
...@@ -107,7 +102,6 @@ python train.py \ ...@@ -107,7 +102,6 @@ python train.py \
# --batch_size=256 \ # --batch_size=256 \
# --total_images=1281167 \ # --total_images=1281167 \
# --image_shape=3,224,224 \ # --image_shape=3,224,224 \
# --input_dtype=float32 \
# --class_dim=1000 \ # --class_dim=1000 \
# --lr_strategy=cosine_decay \ # --lr_strategy=cosine_decay \
# --lr=0.1 \ # --lr=0.1 \
...@@ -125,7 +119,6 @@ python train.py \ ...@@ -125,7 +119,6 @@ python train.py \
# --batch_size=256 \ # --batch_size=256 \
# --total_images=1281167 \ # --total_images=1281167 \
# --image_shape=3,224,224 \ # --image_shape=3,224,224 \
# --input_dtype=float32 \
# --class_dim=1000 \ # --class_dim=1000 \
# --lr_strategy=cosine_decay \ # --lr_strategy=cosine_decay \
# --lr=0.1 \ # --lr=0.1 \
...@@ -142,7 +135,6 @@ python train.py \ ...@@ -142,7 +135,6 @@ python train.py \
# --batch_size=256 \ # --batch_size=256 \
# --total_images=1281167 \ # --total_images=1281167 \
# --image_shape=3,224,224 \ # --image_shape=3,224,224 \
# --input_dtype=float32 \
# --class_dim=1000 \ # --class_dim=1000 \
# --lr_strategy=cosine_decay \ # --lr_strategy=cosine_decay \
# --lr=0.1 \ # --lr=0.1 \
......
...@@ -72,7 +72,7 @@ def check_gpu(use_gpu): ...@@ -72,7 +72,7 @@ def check_gpu(use_gpu):
"\t2. Set use_gpu as false in config file to run " \ "\t2. Set use_gpu as false in config file to run " \
"model on CPU" "model on CPU"
try: try:
if use_gpu and not fluid.is_compiled_with_cuda(): if use_gpu and not fluid.is_compiled_with_cuda():
logger.error(err) logger.error(err)
sys.exit(1) sys.exit(1)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册