static void ConvertVectorsToMatrices(
    const OpInputList bucketized_features_list,
    std::vector<tensorflow::TTypes<int32>::ConstMatrix>& bucketized_features) {
  for (const Tensor& tensor : bucketized_features_list) {
    if (tensor.dims() == 1) {
      const auto v = tensor.vec<int32>();
      bucketized_features.emplace_back(
          TTypes<int32>::ConstMatrix(v.data(), v.size(), 1));
    } else {
      bucketized_features.emplace_back(tensor.matrix<int32>());
    }
  }
}
static void ConvertVectorsToMatrices(
    const OpInputList bucketized_features_list,
    std::vector<tensorflow::TTypes<int32>::ConstMatrix>& bucketized_features) {
  for (const Tensor& tensor : bucketized_features_list) {
    if (tensor.dims() == 1) {
      const auto v = tensor.vec<int32>();
      bucketized_features.emplace_back(
          TTypes<int32>::ConstMatrix(v.data(), v.size(), 1));
    } else {
      bucketized_features.emplace_back(tensor.matrix<int32>());
    }
  }
}