|
|
|
|
@ -110,7 +110,7 @@ public:
|
|
|
|
|
function2_(FunctionBase::funcRegistrar_.createByType(name2)) {
|
|
|
|
|
function1_->init(config);
|
|
|
|
|
function2_->init(config);
|
|
|
|
|
initArgsCallBack_ = nullptr;
|
|
|
|
|
initArgsCallback_ = nullptr;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
~Compare2Function() {}
|
|
|
|
|
@ -171,8 +171,8 @@ public:
|
|
|
|
|
*seq2_));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void registerInitCallBack(std::function<void(BufferArg&, size_t)> callback) {
|
|
|
|
|
initArgsCallBack_ = callback;
|
|
|
|
|
void registerInitCallback(std::function<void(BufferArg&, size_t)> callback) {
|
|
|
|
|
initArgsCallback_ = callback;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// output need only contains shape, do not contains data.
|
|
|
|
|
@ -345,8 +345,8 @@ protected:
|
|
|
|
|
initArg(*func1Inputs_[i]);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (initArgsCallBack_ != nullptr) {
|
|
|
|
|
initArgsCallBack_(*func1Inputs_[i], i);
|
|
|
|
|
if (initArgsCallback_ != nullptr) {
|
|
|
|
|
initArgsCallback_(*func1Inputs_[i], i);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
copyArg_(*func1Inputs_[i], *func2Inputs_[i]);
|
|
|
|
|
@ -395,7 +395,7 @@ protected:
|
|
|
|
|
std::shared_ptr<SequenceIdArg> seq1_;
|
|
|
|
|
std::shared_ptr<SequenceIdArg> seq2_;
|
|
|
|
|
test::CopyArgument<DType1, DType2> copyArg_;
|
|
|
|
|
std::function<void(BufferArg&, size_t)> initArgsCallBack_;
|
|
|
|
|
std::function<void(BufferArg&, size_t)> initArgsCallback_;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
class CpuGpuFuncCompare
|
|
|
|
|
|