《深度学习21天实战Caffe》 第八天
。。@。。-HP-Z420-Workstation:~$ cd caffe
。。@。。-HP-Z420-Workstation:~/caffe$ g++ -o app blob_demo.cpp -I/home/cm/caffe/include/ -D CPU_ONLY -I/home/cm/caffe/.build_release/src/ -L/home/cm/caffe/build/lib/ -lcaffe
/usr/bin/ld: /tmp/ccfxqSGw.o: undefined reference to symbol '_ZN6google4base21CheckOpMessageBuilder7ForVar2Ev'
//usr/lib/x86_64-linux-gnu/libglog.so.0: 无法添加符号: DSO missing from command line
collect2: error: ld returned 1 exit status
。。@。。-HP-Z420-Workstation:~/caffe$ g++ -o app blob_demo.cpp -lglog -I/home/cm/caffe/include/ -D CPU_ONLY -I/home/cm/caffe/.build_release/src/ -L/home/cm/caffe/build/lib/ -lcaffe
。。@。。-HP-Z420-Workstation:~/caffe$ ./app
./app: error while loading shared libraries: libcaffe.so.1.0.0: cannot open shared object file: No such file or directory
。。@。。-HP-Z420-Workstation:~/caffe$ export LD_LIBRARY_PATH=/home/cm/caffe/build/lib/:$LD_LIBRARY_PATH
。。@。。-HP-Z420-Workstation:~/caffe$ ./app
Size: (0)
Size: 1 2 3 4 (24)
a[0][0][0]=0
a[0][0][1]=1
a[0][0][2]=2
a[0][0][3]=3
a[0][1][0]=4
a[0][1][1]=5
a[0][1][2]=6
a[0][1][3]=7
a[0][2][0]=8
a[0][2][1]=9
a[0][2][2]=10
a[0][2][3]=11
a[0][0][0]=12
a[0][0][1]=13
a[0][0][2]=14
a[0][0][3]=15
a[0][1][0]=16
a[0][1][1]=17
a[0][1][2]=18
a[0][1][3]=19
a[0][2][0]=20
a[0][2][1]=21
a[0][2][2]=22
a[0][2][3]=23
ubutnu18.04+caffe+blob
最新推荐文章于 2023-03-16 22:45:16 发布