diff --git a/python/example/example.py b/python/example/example.py index b176098..dd43301 100644 --- a/python/example/example.py +++ b/python/example/example.py @@ -66,3 +66,8 @@ def getMatrixEntry(self, i, j): # Directly obtaining the symmetric factor matrix: W = T.getSymmetricFactor() print('Error in Getting Symmetric Factor:', np.mean(abs(W @ W.T - A))) + +print('Tree Details:') +T.printTreeDetails() +T.plotTree('plot.png') +print('Done!') diff --git a/python/pybind11 b/python/pybind11 index 9bb3313..f701654 160000 --- a/python/pybind11 +++ b/python/pybind11 @@ -1 +1 @@ -Subproject commit 9bb3313162c0b856125e481ceece9d8faa567716 +Subproject commit f70165463328c218d118204efc13aac93783d17b diff --git a/python/wrapper/pyhodlrlib.cpp b/python/wrapper/pyhodlrlib.cpp index 3df2072..d13373a 100644 --- a/python/wrapper/pyhodlrlib.cpp +++ b/python/wrapper/pyhodlrlib.cpp @@ -51,5 +51,7 @@ PYBIND11_MODULE(pyhodlrlib, m) .def("symmetricFactorProduct", &HODLR::symmetricFactorProduct) .def("symmetricFactorTransposeProduct", &HODLR::symmetricFactorTransposeProduct) .def("getSymmetricFactor", &HODLR::getSymmetricFactor) - .def("logDeterminant", &HODLR::logDeterminant); + .def("logDeterminant", &HODLR::logDeterminant) + .def("plotTree", &HODLR::plotTree) + .def("printTreeDetails", &HODLR::printTreeDetails); }