Repository: incubator-singa
Updated Branches:
  refs/heads/master 288a2ab94 -> 595606cb2


SINGA-85 Fix compilation errors in examples.


Project: http://git-wip-us.apache.org/repos/asf/incubator-singa/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-singa/commit/595606cb
Tree: http://git-wip-us.apache.org/repos/asf/incubator-singa/tree/595606cb
Diff: http://git-wip-us.apache.org/repos/asf/incubator-singa/diff/595606cb

Branch: refs/heads/master
Commit: 595606cb2395da3d69f7e010df88821cdabf15c2
Parents: 288a2ab
Author: Yee Fan <[email protected]>
Authored: Mon Oct 12 12:11:10 2015 +0800
Committer: Yee Fan <[email protected]>
Committed: Mon Oct 12 12:11:10 2015 +0800

----------------------------------------------------------------------
 examples/cifar10/create_data.cc | 4 ++--
 examples/mnist/create_data.cc   | 8 ++++----
 examples/rnnlm/Makefile.example | 2 +-
 3 files changed, 7 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-singa/blob/595606cb/examples/cifar10/create_data.cc
----------------------------------------------------------------------
diff --git a/examples/cifar10/create_data.cc b/examples/cifar10/create_data.cc
index 303c589..5873c0e 100644
--- a/examples/cifar10/create_data.cc
+++ b/examples/cifar10/create_data.cc
@@ -59,12 +59,12 @@ void create_data(const string& input_folder, const string& 
output_folder) {
   char str_buffer[kCIFARImageNBytes];
   string rec_buf;
 
-  singa::SingleLabelImageRecord image;;
+  singa::RecordProto image;
   image.add_shape(3);
   image.add_shape(kCIFARSize);
   image.add_shape(kCIFARSize);
 
-  singa::SingleLabelImageRecord mean;
+  singa::RecordProto mean;
   mean.CopyFrom(image);
   for (int i = 0; i < kCIFARImageNBytes; i++)
     mean.add_data(0.f);

http://git-wip-us.apache.org/repos/asf/incubator-singa/blob/595606cb/examples/mnist/create_data.cc
----------------------------------------------------------------------
diff --git a/examples/mnist/create_data.cc b/examples/mnist/create_data.cc
index 14b279f..5e51e97 100644
--- a/examples/mnist/create_data.cc
+++ b/examples/mnist/create_data.cc
@@ -35,9 +35,9 @@
 #include <fstream>
 #include <string>
 
-#include "io/store.h"
-#include "utils/common.h"
-#include "proto/common.pb.h"
+#include "singa/io/store.h"
+#include "singa/utils/common.h"
+#include "singa/proto/common.pb.h"
 
 using std::string;
 
@@ -84,7 +84,7 @@ void create_data(const char* image_filename, const char* 
label_filename,
   char key[kMaxKeyLength];
   string value;
 
-  singa::SingleLabelImageRecord image;
+  singa::RecordProto image;
   image.add_shape(rows);
   image.add_shape(cols);
   LOG(INFO) << "A total of " << num_items << " items.";

http://git-wip-us.apache.org/repos/asf/incubator-singa/blob/595606cb/examples/rnnlm/Makefile.example
----------------------------------------------------------------------
diff --git a/examples/rnnlm/Makefile.example b/examples/rnnlm/Makefile.example
index 0a5a9ce..13c5e42 100644
--- a/examples/rnnlm/Makefile.example
+++ b/examples/rnnlm/Makefile.example
@@ -38,7 +38,7 @@ download:
 
 create:
        protoc --proto_path=../../src/proto --proto_path=. --cpp_out=. 
rnnlm.proto
-       $(CXX) create_data.cc rnnlm.pb.cc -std=c++11 -lsinga -lprotobuf 
-lzookeeper_mt -lglog -I../../include -I../../include/proto \
+       $(CXX) create_data.cc rnnlm.pb.cc -std=c++11 -lsinga -lprotobuf 
-lzookeeper_mt -lglog -I../../include -I../../include/singa/proto \
                -L../../.libs/ -L/usr/local/lib 
-Wl,-unresolved-symbols=ignore-in-shared-libs -Wl,-rpath=../../.libs/ \
                -o create_data.bin
        for d in $(dirshards); do mkdir -p $${d}; done

Reply via email to