diff --git a/RecoMET/METPUSubtraction/plugins/DeepMETProducer.cc b/RecoMET/METPUSubtraction/plugins/DeepMETProducer.cc index 6981825cef2c9..635005f6a2a69 100644 --- a/RecoMET/METPUSubtraction/plugins/DeepMETProducer.cc +++ b/RecoMET/METPUSubtraction/plugins/DeepMETProducer.cc @@ -43,17 +43,8 @@ DeepMETProducer::DeepMETProducer(const edm::ParameterSet& cfg, const tensorflow: session_(cache->getSession()) { produces(); - // Workaround for missing constructor TensorShape::TensorShape(absl::Slice), - // the constructor expects Slice or initializer_list and is marked explicit - tensorflow::TensorShape shape; - shape.AddDim(1); - shape.AddDim(max_n_pf_); - shape.AddDim(8); - - tensorflow::TensorShape cat_shape; - cat_shape.AddDim(1); - cat_shape.AddDim(max_n_pf_); - cat_shape.AddDim(1); + const tensorflow::TensorShape shape({1, max_n_pf_, 8}); + const tensorflow::TensorShape cat_shape({1, max_n_pf_, 1}); input_ = tensorflow::Tensor(tensorflow::DT_FLOAT, shape); input_cat0_ = tensorflow::Tensor(tensorflow::DT_FLOAT, cat_shape);