39 if (model.CheckIfTensorAlreadyExist(
fNX) ==
false){
40 throw std::runtime_error(
"TMVA SOFIE Shape Op Input Tensor " +
fNX +
" is not found in model");
43 size_t length =
fShape.size();
55 auto shape = model.GetTensorShape(
fNX);
56 std::shared_ptr<void> data(
malloc(length *
sizeof(int64_t)),
free);
57 auto shape_values = std::vector<int64_t>(shape.begin()+
fStart, shape.begin() +
fEnd );
58 std::memcpy(data.get(), (
void*) shape_values.data(), length *
sizeof(int64_t));
61 if (model.Verbose()) {
63 for (
size_t i = 0; i < shape_values.size(); i++)
64 std::cout << shape_values[i] <<
" ";
65 std::cout << std::endl;