From 7b7fd15324de5958a375bdaf5101e19085c315bd Mon Sep 17 00:00:00 2001 From: Frank Liu Date: Mon, 7 Jan 2019 16:22:14 -0800 Subject: [PATCH] Use curl to download sample data instead of wget. (#13761) --- .../infer/imageclassifier/get_resnet_18_data.sh | 8 ++++---- .../infer/imageclassifier/get_resnet_data.sh | 8 ++++---- .../scripts/infer/objectdetector/get_ssd_data.sh | 13 ++++++------- .../examples/scripts/rnn/run_test_charrnn.sh | 2 +- .../examples/scripts/rnn/run_train_charrnn.sh | 2 +- 5 files changed, 16 insertions(+), 17 deletions(-) diff --git a/scala-package/examples/scripts/infer/imageclassifier/get_resnet_18_data.sh b/scala-package/examples/scripts/infer/imageclassifier/get_resnet_18_data.sh index 1ce996e5c851..b12993210ed2 100755 --- a/scala-package/examples/scripts/infer/imageclassifier/get_resnet_18_data.sh +++ b/scala-package/examples/scripts/infer/imageclassifier/get_resnet_18_data.sh @@ -34,8 +34,8 @@ if [ ! -d "$image_path" ]; then fi if [ ! -f "$data_path" ]; then - wget https://s3.us-east-2.amazonaws.com/scala-infer-models/resnet-18/resnet-18-symbol.json -P $data_path - wget https://s3.us-east-2.amazonaws.com/scala-infer-models/resnet-18/resnet-18-0000.params -P $data_path - wget https://s3.us-east-2.amazonaws.com/scala-infer-models/resnet-18/synset.txt -P $data_path - wget https://s3.us-east-2.amazonaws.com/mxnet-scala/scala-example-ci/resnet152/kitten.jpg -P $image_path + curl https://s3.us-east-2.amazonaws.com/scala-infer-models/resnet-18/resnet-18-symbol.json -o $data_path/resnet-18-symbol.json + curl https://s3.us-east-2.amazonaws.com/scala-infer-models/resnet-18/resnet-18-0000.params -o $data_path/resnet-18-0000.params + curl https://s3.us-east-2.amazonaws.com/scala-infer-models/resnet-18/synset.txt -o $data_path/synset.txt + curl https://s3.us-east-2.amazonaws.com/mxnet-scala/scala-example-ci/resnet152/kitten.jpg -o $image_path/kitten.jpg fi diff --git a/scala-package/examples/scripts/infer/imageclassifier/get_resnet_data.sh b/scala-package/examples/scripts/infer/imageclassifier/get_resnet_data.sh index 6fd85e4f4400..dc37bdbd73ef 100755 --- a/scala-package/examples/scripts/infer/imageclassifier/get_resnet_data.sh +++ b/scala-package/examples/scripts/infer/imageclassifier/get_resnet_data.sh @@ -34,8 +34,8 @@ if [ ! -d "$image_path" ]; then fi if [ ! -f "$data_path" ]; then - wget https://s3.us-east-2.amazonaws.com/mxnet-scala/scala-example-ci/resnet152/resnet-152-0000.params -P $data_path - wget https://s3.us-east-2.amazonaws.com/mxnet-scala/scala-example-ci/resnet152/resnet-152-symbol.json -P $data_path - wget https://s3.us-east-2.amazonaws.com/mxnet-scala/scala-example-ci/resnet152/synset.txt -P $data_path - wget https://s3.us-east-2.amazonaws.com/mxnet-scala/scala-example-ci/resnet152/kitten.jpg -P $image_path + curl https://s3.us-east-2.amazonaws.com/mxnet-scala/scala-example-ci/resnet152/resnet-152-0000.params -o $data_path/resnet-152-0000.params + curl https://s3.us-east-2.amazonaws.com/mxnet-scala/scala-example-ci/resnet152/resnet-152-symbol.json -o $data_path/resnet-152-symbol.json + curl https://s3.us-east-2.amazonaws.com/mxnet-scala/scala-example-ci/resnet152/synset.txt -o $data_path/synset.txt + curl https://s3.us-east-2.amazonaws.com/mxnet-scala/scala-example-ci/resnet152/kitten.jpg -o $image_path/kitten.jpg fi diff --git a/scala-package/examples/scripts/infer/objectdetector/get_ssd_data.sh b/scala-package/examples/scripts/infer/objectdetector/get_ssd_data.sh index 8787d6382204..e901fc80792f 100755 --- a/scala-package/examples/scripts/infer/objectdetector/get_ssd_data.sh +++ b/scala-package/examples/scripts/infer/objectdetector/get_ssd_data.sh @@ -35,12 +35,11 @@ if [ ! -d "$image_path" ]; then fi if [ ! -f "$data_path" ]; then - wget https://s3.amazonaws.com/model-server/models/resnet50_ssd/resnet50_ssd_model-symbol.json -P $data_path - wget https://s3.amazonaws.com/model-server/models/resnet50_ssd/resnet50_ssd_model-0000.params -P $data_path - wget https://s3.amazonaws.com/model-server/models/resnet50_ssd/synset.txt -P $data_path - cd $image_path - wget https://cloud.githubusercontent.com/assets/3307514/20012566/cbb53c76-a27d-11e6-9aaa-91939c9a1cd5.jpg -O 000001.jpg - wget https://cloud.githubusercontent.com/assets/3307514/20012567/cbb60336-a27d-11e6-93ff-cbc3f09f5c9e.jpg -O dog.jpg - wget https://cloud.githubusercontent.com/assets/3307514/20012563/cbb41382-a27d-11e6-92a9-18dab4fd1ad3.jpg -O person.jpg + curl https://s3.amazonaws.com/model-server/models/resnet50_ssd/resnet50_ssd_model-symbol.json -o $data_path/resnet50_ssd_model-symbol.json + curl https://s3.amazonaws.com/model-server/models/resnet50_ssd/resnet50_ssd_model-0000.params -o $data_path/resnet50_ssd_model-0000.params + curl https://s3.amazonaws.com/model-server/models/resnet50_ssd/synset.txt -o $data_path/synset.txt + curl https://cloud.githubusercontent.com/assets/3307514/20012566/cbb53c76-a27d-11e6-9aaa-91939c9a1cd5.jpg -o $image_path/000001.jpg + curl https://cloud.githubusercontent.com/assets/3307514/20012567/cbb60336-a27d-11e6-93ff-cbc3f09f5c9e.jpg -o $image_path/dog.jpg + curl https://cloud.githubusercontent.com/assets/3307514/20012563/cbb41382-a27d-11e6-92a9-18dab4fd1ad3.jpg -o $image_path/person.jpg fi diff --git a/scala-package/examples/scripts/rnn/run_test_charrnn.sh b/scala-package/examples/scripts/rnn/run_test_charrnn.sh index bf02a1d604ca..a854764fa416 100644 --- a/scala-package/examples/scripts/rnn/run_test_charrnn.sh +++ b/scala-package/examples/scripts/rnn/run_test_charrnn.sh @@ -27,7 +27,7 @@ else fi # you can get the training data file using the following command -# wget http://data.mxnet.io/data/char_lstm.zip +# curl -O http://data.mxnet.io/data/char_lstm.zip # unzip -o char_lstm.zip # for example ./datas/obama.txt DATA_PATH=$1 diff --git a/scala-package/examples/scripts/rnn/run_train_charrnn.sh b/scala-package/examples/scripts/rnn/run_train_charrnn.sh index 4877f57855a0..f49eed64b109 100755 --- a/scala-package/examples/scripts/rnn/run_train_charrnn.sh +++ b/scala-package/examples/scripts/rnn/run_train_charrnn.sh @@ -28,7 +28,7 @@ fi # which gpu card to use, -1 means cpu GPU=$1 # you can get the training data file using the following command -# wget http://data.mxnet.io/data/char_lstm.zip +# curl -O http://data.mxnet.io/data/char_lstm.zip # unzip -o char_lstm.zip # for example ./datas/obama.txt DATA_PATH=$2