-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathmodel_prepare.sh
More file actions
executable file
·55 lines (44 loc) · 1.86 KB
/
model_prepare.sh
File metadata and controls
executable file
·55 lines (44 loc) · 1.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#!/bin/bash
TEST_CAFFE=/data/test_caffe
PREBUILTS_LIB=prebuilts
CAFFE_ON_ACL_LIBRARY=$PREBUILTS_LIB/CaffeOnACL
COMPUTE_LIBRARY=$PREBUILTS_LIB/ComputeLibrary
adb wait-for-device
adb root
adb remount
# prepare libraries
adb shell "mkdir -p $TEST_CAFFE"
#adb push $CAFFE_ON_ACL_LIBRARY/lib/libcaffe.so $TEST_CAFFE
adb push $COMPUTE_LIBRARY/lib/libOpenCL.so $TEST_CAFFE
# prepare test data for classification
TEST_DATA=$TEST_CAFFE/test_data
adb shell "mkdir -p $TEST_DATA"
adb push CaffeOnACL/data/ilsvrc12/imagenet_mean.binaryproto $TEST_DATA
adb push CaffeOnACL/data/ilsvrc12/synset_words.txt $TEST_DATA
adb push CaffeOnACL/examples/images/cat.jpg $TEST_DATA
# prepare AlexNet
ALEX_NET=$TEST_CAFFE/alexnet
adb shell "mkdir -p $ALEX_NET"
adb push CaffeOnACL/models/bvlc_alexnet/deploy.prototxt $ALEX_NET
adb push CaffeOnACL/models/bvlc_alexnet/bvlc_alexnet.caffemodel $ALEX_NET
# prepare GoogLeNet
GOOGLE_NET=$TEST_CAFFE/googlenet
adb shell "mkdir -p $GOOGLE_NET"
adb push CaffeOnACL/models/bvlc_googlenet/deploy.prototxt $GOOGLE_NET
adb push CaffeOnACL/models/bvlc_googlenet/bvlc_googlenet.caffemodel $GOOGLE_NET
# prepare SquezzeNet
SQUEZZE_NET=$TEST_CAFFE/squezzenet
adb shell "mkdir -p $SQUEZZE_NET"
adb push CaffeOnACL/models/SqueezeNet/SqueezeNet_v1.1/squeezenet.1.1.deploy.prototxt $SQUEZZE_NET
adb push CaffeOnACL/models/SqueezeNet/SqueezeNet_v1.1/squeezenet_v1.1.caffemodel $SQUEZZE_NET
# prepare MobileNet
MOBILE_NET=$TEST_CAFFE/mobilenet
adb shell "mkdir -p $MOBILE_NET"
adb push CaffeOnACL/models/MobileNet/mobilenet_deploy.prototxt $MOBILE_NET
adb push CaffeOnACL/models/MobileNet/mobilenet.caffemodel $MOBILE_NET
# prepare classification binary
#adb push $CAFFE_ON_ACL_LIBRARY/bin/classification_profiling $TEST_CAFFE
#adb push $CAFFE_ON_ACL_LIBRARY/bin/classification_profiling_gpu $TEST_CAFFE
# prepare spinning robot
adb install -r prebuilts/BasicGLSurfaceView.apk
adb shell sync