From 79714d74b988e659d0a88b304de9b9081060c29b Mon Sep 17 00:00:00 2001 From: sangoly Date: Thu, 29 Aug 2019 20:56:12 +0800 Subject: [PATCH] [Java API][Comment] upate java api & delete some comments (#1912) --- .../android/jni/src/com/baidu/paddle/lite/PowerMode.java | 6 +++--- lite/model_parser/model_parser.cc | 3 --- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/lite/api/android/jni/src/com/baidu/paddle/lite/PowerMode.java b/lite/api/android/jni/src/com/baidu/paddle/lite/PowerMode.java index 4c311984db..36bd568406 100644 --- a/lite/api/android/jni/src/com/baidu/paddle/lite/PowerMode.java +++ b/lite/api/android/jni/src/com/baidu/paddle/lite/PowerMode.java @@ -14,7 +14,7 @@ limitations under the License. */ package com.baidu.paddle.lite; /** - * PowerMode is the cpu runing mode for the light weight predictor. + * PowerMode is the cpu running power mode for the light weight predictor. */ public enum PowerMode { LITE_POWER_HIGH(0), @@ -24,8 +24,6 @@ public enum PowerMode { LITE_POWER_RAND_HIGH(4), LITE_POWER_RAND_LOW(5); - public final int value; - private PowerMode(int value) { this.value = value; } @@ -33,4 +31,6 @@ public enum PowerMode { public int value() { return this.value; } + + private final int value; } diff --git a/lite/model_parser/model_parser.cc b/lite/model_parser/model_parser.cc index 398f3b3d0a..1b7ddd043e 100644 --- a/lite/model_parser/model_parser.cc +++ b/lite/model_parser/model_parser.cc @@ -126,8 +126,6 @@ void LoadLoDTensor(std::istream &is, Variable *var) { TensorFromStream(is, tensor); } -// TODO(Superjomn) support SelectedRows. - void ReadBinaryFile(const std::string &filename, std::string *contents) { std::ifstream fin(filename, std::ios::in | std::ios::binary); CHECK(fin.is_open()) << "Cannot open file: " << filename; @@ -163,7 +161,6 @@ void LoadParam(const std::string &path, Variable *out) { LoadLoDTensor(fin, out); } -// bool IsPersistable(const cpp::VarDesc &var) { if (var.Persistable() && var.GetType() != VarDescAPI::Type::FEED_MINIBATCH && var.GetType() != VarDescAPI::Type::FETCH_LIST && -- GitLab