summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorInki Dae <inki.dae@samsung.com>2018-09-04 11:23:06 +0900
committerInki Dae <inki.dae@samsung.com>2018-09-04 11:23:06 +0900
commit901266ce749e7d1a74b10e58fd09845ebc35c5b0 (patch)
tree54e44ecef66bcdb79b7ef6d0ba2a0945bc9f5a38
parent44889f598c73a2d05c7e123fdee3b5854a17c4fb (diff)
downloadcaffeonacl-sandbox/daeinki/armcl-v18.08.tar.gz
caffeonacl-sandbox/daeinki/armcl-v18.08.tar.bz2
caffeonacl-sandbox/daeinki/armcl-v18.08.zip
Add armcl v18.08 supportsandbox/daeinki/armcl-v18.08
This patch fixes a build error with armcl v18.08 by correcting a parameter type of configure function of FullyConnectedLayer. Change-Id: I1755b1bee083f099ae7cf0095e4fadc60cb1a690 Signed-off-by: Inki Dae <inki.dae@samsung.com>
-rw-r--r--include/caffe/acl_operator.hpp3
-rw-r--r--src/caffe/layers/acl_inner_product_layer.cpp6
2 files changed, 7 insertions, 2 deletions
diff --git a/include/caffe/acl_operator.hpp b/include/caffe/acl_operator.hpp
index 90051054..5759f4dc 100644
--- a/include/caffe/acl_operator.hpp
+++ b/include/caffe/acl_operator.hpp
@@ -620,11 +620,12 @@ bool instantiate_op_lc(ACLOperator* acl_op,std::vector<std::unique_ptr<arm_compu
func.push_back(instantiate_op_func<arm_compute::CLLocallyConnectedLayer,arm_compute::ICLTensor,arm_compute::NELocallyConnectedLayer,arm_compute::ITensor, arm_compute::PadStrideInfo>(input, weights,biases,output,info, hint));
return true;
}
+
template <typename OperatorInfo>
bool instantiate_op_fc(ACLOperator* acl_op,std::vector<std::unique_ptr<arm_compute::IFunction>> & func,std::unique_ptr<ACLTensor> & input,std::unique_ptr<ACLTensor> & output,TargetHint hint, const OperatorInfo &info){
std::unique_ptr<ACLTensor> & weights=acl_op->weights();
std::unique_ptr<ACLTensor> & biases=acl_op->biases();
- func.push_back(instantiate_op_func<arm_compute::CLFullyConnectedLayer,arm_compute::ICLTensor,arm_compute::NEFullyConnectedLayer,arm_compute::ITensor, bool>(input, weights,biases,output,info, hint));
+ func.push_back(instantiate_op_func<arm_compute::CLFullyConnectedLayer,arm_compute::ICLTensor,arm_compute::NEFullyConnectedLayer,arm_compute::ITensor, arm_compute::FullyConnectedLayerInfo>(input, weights,biases,output,info, hint));
return true;
}
template <typename Dtype>
diff --git a/src/caffe/layers/acl_inner_product_layer.cpp b/src/caffe/layers/acl_inner_product_layer.cpp
index bb819fcc..c7cc0723 100644
--- a/src/caffe/layers/acl_inner_product_layer.cpp
+++ b/src/caffe/layers/acl_inner_product_layer.cpp
@@ -32,12 +32,16 @@ void ACLInnerProductLayer<Dtype>::SetupACLOperator(const vector<Blob<Dtype>*>& b
}else{
new_tensor(weights(),weights_shape,GetDataPtr(this,this->blobs_[0].get()));
}
+
+ arm_compute::FullyConnectedLayerInfo fc_info = arm_compute::FullyConnectedLayerInfo();
+ fc_info.transpose_weights = transpose;
+
if (this->bias_term_) {
new_tensor(biases(),biases_shape,GetDataPtr(this,this->blobs_[1].get()));
}
new_tensor(input(),input_shape,InputdataPtr(this,bottom));
new_tensor(output(),output_shape,OutputdataPtr(this,top));
- acl_configure(fc,this,transpose);
+ acl_configure(fc,this,fc_info);
}
template <typename Dtype>
void ACLInnerProductLayer<Dtype>::Reshape(const vector<Blob<Dtype>*>& bottom,