Error about TMVA


The TMVA library is used for artificial neural network,the train file is:

ROOT Version: 6.28/04
Platform: Ubuntu 20.04
Compiler: gcc 9.4.0


the train file is:

train.cpp (3.5 KB)

and the file include the network parameters was produced, and used by the file for predicting.

and the predict file is:

predict.cpp (1.5 KB)

when running the predicting, the error occured:

     : Booking "DNN" of type "DNN" from dataset/weights/NeutronSpectrum_DNN.weights.xml.
             : MethodDNN is deprecated and it will be removed in future ROOT version. Please use MethodDL ( TMVA::kDL)

: Reading weight file: dataset/weights/NeutronSpectrum_DNN.weights.xml

DataSetInfo : [Default] : Added class "Regression" : Booked classifier "DNN" of type: "DNN" : Rebuilding Dataset Default Error in : matrices not compatible Prediction: spec0 = 15.692

what cause the error “matrices not compatible“?