forked from mindspore-Ecosystem/mindspore
!4260 fix crop and DeDepthwiseConv2D bugs
Merge pull request !4260 from yeyunpeng2020/master
This commit is contained in:
commit
f287471fc1
|
@ -226,6 +226,8 @@ lite::Primitive *ModelImpl::CopyPrimitive(const schema::Primitive *srcPrim) {
|
|||
return new lite::EmbeddingLookup(const_cast<schema::Primitive *>(srcPrim));
|
||||
case schema::PrimitiveType_Elu:
|
||||
return new lite::Elu(const_cast<schema::Primitive *>(srcPrim));
|
||||
case schema::PrimitiveType_DeDepthwiseConv2D:
|
||||
return new lite::DeconvDepthwiseConv2D(const_cast<schema::Primitive *>(srcPrim));
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -32,7 +32,8 @@ int Crop::InferShape(std::vector<tensor::Tensor *> inputs, std::vector<tensor::T
|
|||
return RET_PARAM_INVALID;
|
||||
}
|
||||
outputs[0]->set_shape(inputs[1]->shape());
|
||||
outputs[0]->SetFormat(inputs[1]->GetFormat());
|
||||
outputs[0]->SetFormat(inputs[0]->GetFormat());
|
||||
outputs[0]->set_data_type(inputs[0]->data_type());
|
||||
|
||||
return RET_OK;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue